Issue Reading Modbus Registers with Float conversion

Have a look here, I believe that this might be what you are looking at.
Essentially a float is two words, and in certain instances if you are either word swapped or off by one register (generally caused by 0 based addressing) then you can get instances where you are looking at very similar data.

Try move your register address up by one or down by one and see if it affects it.
If that doesn't work, try setting the "Reverse Word Order" setting in the Modbus driver. Then try moving the address up or down one from the one in the manual and see if it fixes it, one of those will work I believe.

This is a byproduct of float not actually being part of the modbus standard, so there are a bunch of different ways people have used modbus to represent a float.

1 Like