beautypg.com

NORD Drivesystems BU0550 User Manual

Page 68

background image

PLC logic for NORD SK 54xE frequency inverters

68

BU 0550 GB-0813

3.5.6.3

FB_DINTToPBox

This function module converts a DINT value into an ASCII string and copies it into the ParameterBox. The
output can be in decimal, binary or hexadecimal format. Selection is carried out via MODE. Via ROW and
COLUMN the starting position of the string is set in the P-Box display. The parameter LENGTH
communicates the length of the string in characters. In decimal MODE the parameter POINT inserts a
decimal point into the number to be displayed. POINT specifies how many characters are to the right of the
decimal point. The function POINT is switched off with the setting 0.

If the number contains more characters than the length allows and no decimal point is set, the overflow is
indicated by the character "#". If there is a decimal point in the number, all numbers behind the decimal point
by be omitted if required. In hexadecimal and binary MODE the lowest value bits are displayed if the set
length is too short.

As long as ENABLE is set to 1, all changes at the inputs are adopted immediately.

If DONE switches to 1, the string has been transferred correctly.

In case of error, ERROR is set to 1. In this case, DONE is 0. The corresponding error code in the ERRORID
applies.

DONE, ERROR and ERRORID are reset with a negative flank on ENABLE.

Examples:

Setting

Number to be displayed

P-Box display

Length = 5

12345

12345

Point = 0

Length = 5

-12345

#####

Point = 0

Length = 10

123456789

123456,789

Point = 3

Length = 8

123456789

123456,7

Point = 3

Table 93 FB_DINTToPBox

VAR_INPUT

VAR_OUTPUT

Input

Explanation

Type

Output

Explanation

Type

ENABLE

Transfer of string

BOOL

DONE

String transferred

BOOL

MODE

Display format

0 = Decimal

1 = Binary

2 = Hexadecimal

Value range = 0 to 2

BYTE

ERROR

Error in FB

BOOL

ROW

Row of the display

Value range = 0 to 3

BYTE

ERRORID

Error code

INT

COLUMN

Column of the display

Value range = 0 to 19

BYTE

POINT

Position of the decimal point

Value range = 0 to 10

0 = Function is disabled

BYTE

LENGTH

Output length

Value range = 1 to 11

BYTE

VALUE

Number to be output

DINT

ERRORID

Explanation

0

No error

1500h

String overwrites the memory area of the P-Box array

1501h

Value range exceeded at LINE input

1502h

Value range exceeded at ROW input

1504h

Value range exceeded at POINT input

1505h

Value range exceeded at LENGTH input

1506h

Value range exceeded at MODE input