A SERVICE OF

logo

Danaher Motion 07/06 Overview
M-S2-021-11 Initial Release 5
2.3.1. B
ASIC
D
ATA
T
YPES
Unsigned Integer
Data in the basic data type UNSIGNEDn define exclusively positive integers.
The value range is from 0 ... 2
n-1
. The bit sequence b = b0 ... b
n-1
defines the value
UNSIGNEDn(b) = b
n-1
2
n-1
+ ... + b
1
2
1
+ b
0
2
0
Example The value 266 = 10A
h
is transmitted in the data type UNSIGNED16, in the form of two octets (1
st
octet = 0A
h
, 2
nd
octet = 01
h
).
Transmission syntax for the data type UNSIGNEDn:
Octet Number 1 2 3 4 5 6 7 8
UNSIGNED8 b7..b0
UNSIGNED16 b7..b0 b15..b8
UNSIGNED24 b7..b0 b15..b8 b23..b16
UNSIGNED32 b7..b0 b15..b8 b23..b16 b31..b24
UNSIGNED40 b7..b0 b15..b8 b23..b16 b31..b24 b39..b32
UNSIGNED48 b7..b0 b15..b8 b23..b16 b31..b24 b39..b32 b47..b40
UNSIGNED56 b7..b0 b15..b8 b23..b16 b31..b24 b39..b32 b47..b40 b55..b48
UNSIGNED64 b7..b0 b15..b8 b23..b16 b31..b24 b39..b32 b47..b40 b55..b48 b63..b56
Signed Integer
Data in the basic data type INTEGERn define both positive and negative integers.
The value range is from -2
n-1
-1 ... 2
n-1
-1. The bit sequence b = b
0
..b
n-1
defines the value
INTEGERn(b) = b
n-2
2
n-2
+ ... + b
1
2
1
+ b
0
2
0
with b
n-1
= 0
Negative numbers are represented as 2’s complement, which means:
INTEGERn(b) = - INTEGERn(b) - 1 with b
n-1
= 1
Example The value -266 = FEF6
h
is transmitted in the data type INTEGER16, in the form of two octets (1
st
octet = F6h, 2
nd
octet = FE
h
).
Transmission syntax for the data type INTEGERn:
Octet Number 1 2 3 4 5 6 7 8
UNSIGNED8 b7..b0
UNSIGNED16 b7..b0 b15..b8
UNSIGNED24 b7..b0 b15..b8 b23..b16
UNSIGNED32 b7..b0 b15..b8 b23..b16 b31..b24
UNSIGNED40 b7..b0 b15..b8 b23..b16 b31..b24 b39..b32
UNSIGNED48 b7..b0 b15..b8 b23..b16 b31..b24 b39..b32 b47..b40
UNSIGNED56 b7..b0 b15..b8 b23..b16 b31..b24 b39..b32 b47..b40 b55..b48
UNSIGNED64 b7..b0 b15..b8 b23..b16 b31..b24 b39..b32 b47..b40 b55..b48 b63..b56
2.3.2. M
IXED
D
ATA
T
YPES
Mixed data types combine basic data types (INTEGERn, UNSIGNEDn, REAL). Two types of mixed data
are distinguished:
STRUCT This data type is composed of elements with different data types.
ARRAY This data type is composed of elements of the same data type.