Knowledge Base / Protocols / Modbus

How do I enter a Modbus address of 40001 or higher in the DevAddress command field of my MVI56-MCM?

Search KB

Categories

Since the Dev Address field is a signed 16-bit integer, the maximum positive value accepted by RSLogix is 32767

However the Dev Address field is a Modbus offset value. When using a Modbus function code 3, 6, or 16, an address base of 40001 is assumed. The Dev Address field is an offset from this base.

Examples:

  • If an address of 40001 needs to be accessed, then a Dev Address of 0 is used (40001 - 40001 base = offset address of 0)
  • If an address of 41031 needs to be accessed, then a Dev Address of 1030 is used (41031 - 40001 base = offset address of 1030)

If the required OFFSET actually exceeds 32767, add 65536 to calculate the signed value of this address, and that value will be accepted as a signed 16 bit INT.