![ARDETEM PECA 5 Скачать руководство пользователя страница 24](http://html.mh-extra.com/html/ardetem/peca-5/peca-5_user-manual_2966113024.webp)
p23
2 bytes
CRC 16
Slave
number
1 byte
1 byte
Function
16
2 bytes
CRC 16
1st word
address
Nbr of
word to
be enfor.
Writing of N words : Function N°16 :
Request pattern
:
Value of the words
to be enforced
2 bytes 2 bytes
Nbr of
words to
be enfor.
2 bytes
Nbr of
bytes to
be enfor.
1 byte
n bytes
Slave
number
1 byte
1 byte
1 byte
Function
16
1st word
address
Response pattern :
254
03
CRC 16
0
52
9.4 Reading in double integer format
:
Example : Reading of the max. on display 1 (maximum of voltage U1-3)
Request
:
0
2
Address
Reading
of n wrds
Slave
number
Number of words
254
3
4
19
•
Response with a positive measure
:
136
0
CRC 16
0
measure
byte 1
byte 2
byte 3
byte 4
2 bytes
0 0 0 0 0 0 0 0
byte 3
0 0 0 0 0 0 0 0
byte 4
0 0 0 1 0 0 11
byte 1
1 0 0 0 1 0 0 0
byte 2
0
Sign
: 0 positive
1 negative
0
19
136
Value of the measure :
Measure = byte 3 x 2563 + byte 4 x 2562 + byte 1 x 256 + byte 2
= 0 x 2563 + 0 x 2562 + 19 x 256
+ 136
= 5000
Reading of address 17 => point = 3 unit = 0 => maximum = 500.0V
11111111
byte 3
11111111
byte 4
111 0 11 0 0
byte 1
0 1111 0 0 0
byte 2
0 0 0 0 0 0 0 0
byte 3
0 0 0 0 0 0 0 0
byte 4
0 0 0 1 0 0 11
byte 1
1 0 0 0 0 111
byte 2
0 0 0 0 0 0 0 0
byte 3
0 0 0 0 0 0 0 0
byte 4
0 0 0 1 0 0 11
byte 1
1 0 0 0 1 0 0 0
byte 2
0
0
19
136
Sign
: 1 negative : inversion of bits, and adding of 1.
Plus 1
Inversion
254
3
4
236
•
Response with a negative measure
:
(eg. : active power)
120
255
CRC 16
255
measure
byte 1
byte 2
byte 3
byte 4
2 bytes
Measure = -(byte 3 x 2563 + byte 4 x 2562 + byte 1 x 256 + byte 2)
= -(0 x 2563 + 0 x 2562 + 19 x 256 + 136)
= -5000
Reading of address 21 => dec. point = 4 unit = 1 => value = -5000kW