Manual VIPA CPU 21x Chapter 9 Deployment CPU 21xSER-1
HB103E - Rev. 05/45 9-21
The following Modbus function codes are supported by the Modbus slave:
Code Command Description
01h Read n Bits Read n Bits of output area 0x
02h Read n Bits Read n Bits of input area 1x
03h Read n Words Read n Words of output area 4x
04h Read n Words Read n Words input area 3x
05h Write 1 Bit Write 1 Bit to output area 0x
06h Write 1 Word Write 1 Word to output area 4x
10h Write n Words Write n Words to area 4x
Note!
The telegrams are automatically integrated into the according checksum
circle of ASCII res. RTU.
Always valid for the Byte sequence in a word is:
1 Word
High
Byte
Low
Byte
If the slave announces an error, the function code is send back with a "OR"
and 80h. Without an error, the function code is sent back.
Slave answer: Function code OR 80h → Error
Function code → OK
This function enables the reading from a slave bit by bit.
Command telegram
RTU/ASCII
frame
Slave
address
Function
code
Address
1
st
Bit
Number of
Bits
RTU/ASCII
frame
1Byte 1Byte 1Word 1Word 1Word
Respond telegram
RTU/ASCII
frame
Slave
address
Function
code
Number of
read Bytes
Data
1
st
Byte
Data
2
nd
Byte
...
RTU/ASCII
frame
1Byte 1Byte 1Byte 1Byte 1Byte 1Word
max. 252Byte
Overview
Respond of the
slave
Read n Bits
01h, 02h