Athena C10 line Bedienerhandbuch Seite 14

  • Herunterladen
  • Zu meinen Handbüchern hinzufügen
  • Drucken
  • Seite
    / 107
  • Inhaltsverzeichnis
  • LESEZEICHEN
  • Bewertet. / 5. Basierend auf Kundenbewertungen
Seitenansicht 13
14
3.9 Preset Multiple Registers (16)
This function is used for setting the value of a consecutive block of 16-bit
registers. Broadcast mode is allowed. Question.
In addition to the address of the slave and the function code (16), the
message contains the starting address, the number of words to be
written, the number of bytes that contain data and the data characters.
Address numbering starts from zero (word1 = 0) for MODBUS, from one
(word1 = 1) for JBUS.
NOTE: In the ATHENA CONTROLS implementation, this function is
present for compatibility but does not permit more than 8 word to be
assigned.
Example: Request to set 1 word to value 268 at address 35 on slave 17.
ADDR
FUNC
DATA
start
Addr HI
DATA
start
Addr LO
DATA
word #
HI
DATA
word #
LO
DATA
Byte
Count
DATA
word
35 HI
DATA
word
35 LO
CRC
HI
CRC
LO
11 10 00 22 00 01 02 01 0C 6C 87
Answer
In addition to the address of the slave and the function code (16), the
message contains the starting address and the number of words written.
Example: Answer to the request indicated above.
ADDR
FUNC
DATA
start
Addr HI
DATA
start
Addr LO
DATA
word #
HI
DATA
word #
LO
CRC
HI
CRC
LO
11 10 00 22 00 01 A3 53
4. Error Management
In MODBUS there are two types of errors, handled in different ways:
transmission errors and operating errors. Transmission errors are errors
that change the format of the message, the parity (if used) or the CRC16.
A device that detects errors of this type in the message treats it as invalid
and gives no answer. When the format of the message is correct but the
function requested cannot be executed for some reason, an operating
error has occurred. When it detects this kind of error, the slave device
answers by sending an error message. This message consists of the
address, the code of the function requested, an error code and the CRC.
To indicate that the answer is an error message, the function code is
returned with the most significant bit set to "1".
Example: Request for slave 10 to read bit 1185.
ADDR
FUNC
DATA
start
Addr HI
DATA
start
Addr LO
DATA
bit #
HI
DATA
bit #
LO
CRC
HI
CRC
LO
0A 01 04 A1 00 01 AC 63
Answer
The request is for the contents of bit 1185, which is not present on the
slave. The slave answers by sending error code "02" (ILLEGAL DATA
ADDRESS) and returns the function code 81h (129).
Seitenansicht 13
1 2 ... 9 10 11 12 13 14 15 16 17 18 19 ... 106 107

Kommentare zu diesen Handbüchern

Keine Kommentare