VR10BinToUWr
V = Variables
R = Reading functions
BINARY —→ UNSIGNED WORD
The VR10BinToUWr function Converts a binary variable type in an Unsigned Word type (word without sign).
IMPLEMENTATION
VR10BinToUWr (array, index, return, errcode)
Parameters:
IN/OUT | VARIABLE TYPE | EXAMPLE NAME | DIM | |
---|---|---|---|---|
IN | ARRGBL | array | B | Array containing the data to be converted (must be declared with at least “index + 1” items) |
IN | GLOBAL | index | L | Index of the array element at the beginning of the data |
OUT | GLOBAL | return | L | Data value converted |
OUT | GLOBAL | errcode | F | Variable that indicates a possible error on the function |
Errcode
After calling the function, 'errcode' can take on certain values, the meaning of these values is summarized below:
0: No error
Example
Transforms the value 55346 (binary) in an unsigned word value
index = 1 array[1] = -40 array[2] = 50 VR10BinToUWr (array, index, return, errcode) ;On the return data you will find : ; return = 55346