Conversion of data from Modbus Slave response to floating point number


Thread Starter

W Page

We have plant data that exchages data with another system. We have been doing this for years via Modbus RS 232. He is the master and I am the slave. He is replacing his master device. The problem is our data does not match-up. When he tries to poll 100 in one of my registers he gets 97. the same thing happens when he tries to write 100. I get 97. There are no comm errors. Transmission looks good. The only thing I can tnink of is he has an error converting to or from a floating point number.

Any ideas?

Friedrich Haase

Moin Mr. Page,
moin all,

Get a sniffer for RS 232 and see what the datagrams look like. Usually I use a program named ZOC for this.

From my homepage you can download a small program which shows and converts hex numbers to/from floating-point numbers. Compare to see which side is wrong.

Good luck
Friedrich Haase

Ing.-Büro Dr. Friedrich Haase
Consulting - Automatisierungstechnik
email [email protected]
I could not understand exactly what "100" and "97" is... Are they the value in the registers or the addresses of the registers? The problem may be due to the addressing problem. That is, polling is made for address 100 but the response is of 99. This is common problem in modbus communication due to different modbus standards of different devices.