Télécharger Imprimer la page

Ecolab Versatronic Profibus Instructions De Configuration page 68

Publicité

Les langues disponibles

Les langues disponibles

Data format of the devices
5
Data format of the devices
NOTICE!
When devices are used on a PROFIBUS-DP system, it is necessary to use the
correct data format!
Two different data formats are available for selection:
– Little Endian
– Big Endian
– Communication with a Siemens PLC usually uses the Big Endian format.
5.1
Integer values
Integer values are transmitted in the following format:
first the
then the
5.2
Floating-point values/real values
Floating-point values/real values are stored in the device in the IEEE-754 standard format
(32-bit).
Single-precision floating-point format (32-bit) to Standard IEEE 754
SEEEEEEE
Byte 1
S - Sign bit (Bit 31)
E - Exponent in the twos complement (Bit 23 to Bit 30)
M - 23 -bit normalized mantissa (Bit 0 to Bit 22)
Example: Calculation of the real number from the sign, exponent, and mantissa.
Byte1 = 40h, Byte2 = F0, Byte 3 = 0, Byte 4 = 0
40F00000h = 0100 0000 1111 0000 0000 0000 0000 0000b
S = 0
E = 100 0000 1
M = 111 0000 0000 0000 0000 0000
Value = -1
S
· 2
Value = -1
0
· 2
2
Value = 1 · 2
Value = 1 · 4 · 1,875
Value = 7,5
The order in which the individual bytes are transmitted depends on the data
format set in the configuration.
After/before transmission from/to the device, the bytes for the floating-point
value must be interchanged accordingly.
417102396 Rev. 2-08.2023
EMMMMMMM
Byte 2
Exponent-127
· (1 + M
·2
b22
129-127
· (1 + 1·2
-1
+ 1·2
· (1 + 0,5 + 0,25 + 0,125 + 0)
Big Endian
- High byte,
- Low byte.
MMMMMMMM
Byte 3
-1
+ M
·2
-2
+ M
·2
-3
b21
b20
-2
+ 1·2
-3
+ 0·2
-4
)
32
Little Endian
- Low byte,
- High byte.
MMMMMMMM
Byte 4
+ M
·2
-4
+ ...)
b19

Publicité

loading