FOR TIPS, gUIDES & TUTORIALS

subscribe to our Youtube

GO TO YOUTUBE

14455 questions

17168 answers

28195 comments

0 members

We are migrating to our new platform at https://community.teltonika.lt. Moving forward, you can continue discussions on this new platform. This current platform will be temporarily maintained for reference purposes.
0 votes
184 views 1 comments
by anonymous
Hi!

I have a RUT956 setup and working properly, it is reading a Modbus slave unit over TCP, using Data to Server to the local MQTT broker.

However, fiddling with the Modbus Master settings, i discovered, reading a register e.g. "117" with supposed function call "Read holding registers (3)", I have to set the selection to "Read input registers (4)" to get the value. Then, when sending the data with Data to Server, I use the "Full MODBUS register address - %z" format for the JSON - right - and then, I'm picking up 300117 as the address.

I'm a bit confused! Is there a offset-thing +1 in the Modbus Master settings for modbus remote commands?

Cheers! /Björn

1 Answer

0 votes
by anonymous

Hello,

Your issue seems to be slave device related.

I have tested MODBUS Master with a slave simulator on several firmware versions, including the latest RUT9M_R_00.07.03, but did not replicate your scenario, without specifically placing value in register 300117.

Best regards,

Best answer
by anonymous

Hi, thanks!

No, it's not slave device related (a standard Siemens Climatix air handling unit).

I now found the issue, it's me-related - how Modbus standard differs on "function code" and "register addresses".
I had to educate myself Googling and reading a lot of material.

Register Read Command Address %z
Coils 01 0x0000--0x9999
Discrete Input 02 1x0000--1x9999
Input Register 04 3x0000--3x9999
Holding Register 03 4x0000--4x9999

I mixed up "function (3)" with address 3x and "function (4)" with address 4x.

So it works correct, if you know what you are doing :-)

Cheers!
/Björn