๐จโ๐ปModbus Addressing
Difference in Modbus 5 digit and 6 digit addressings
The 5 and 6 digit addressing refers to the range of references in the device. First of all, the leading digit "0" for an internal coil or discrete output, "1" for a discrete input, 3" for an analog input, and "4" for a holding register or analog output, is NOT PART OF THE ADDRESS. It is a data type, not a number.
For "5 digit" addressing, 40000 to 49999, the actual range is 10,000 i.e. 0 to 9999). This was the "limit" in the earlier PLCs by Modicon.
When the PLCs were changed (memory became smaller and cheaper), the range became 400000 to 4xxxxx. The upper limit was a function of the processor memory. Now the PLC offered far more than 10,000 addressable references so the addressing had to be adjusted.
In the Modbus message "frame" there are four (4) hex values available for the reference address. 0000 hex to FFFF hex, which is 0 to 65535.
When you read 412345, you use Modbus function code 4 (Read Holding Registers) and address 12345. Since all data addresses are reference to zero, holding register 12345 is addressed as 12344 and will be in the message "frame" as 3038 hex.
Last updated