Page 1 of 1

problems understanding / using modbus component

Posted: Mon Sep 16, 2019 10:05 am
by CSM2711
Hi,
I'm trying to get a modbus communication right now, unfortunately I have an understanding problem here.
I hope someone can help with this.
I use the valve from the appendix. Now I want to change the setpoint (register 0x0004,0x00005).
Here I would have to send the following string:

SlaveID: 1 Function code 6 Address0x0006 Data XXX

But if I use the function present singleRegister (functioncode6) starts the addressing at 40001 so this can not work or I understand something wrong here?

communication protocol
https://www.voegtlin.com/data/329-3042_ ... igicom.pdf

Re: problems understanding / using modbus component

Posted: Mon Sep 16, 2019 10:10 am
by Benj
Hello,

Modbus addresses are strange and are fairly misleading.

Address 40001 really equates to Register 0.

So sending the command singleRegister with the address 4 and 5 will generate the 0x0004 and 0x0005 you need.