Modbus RTU Send Message

I'm hoping someone can help me with this problem I'm having with trying to work out what sort of response I should be getting from this message being transmitted:<pre>
0F 03 00 00 00 10 3F 4A</pre>
I was thinking something along the lines of<pre>
0F 03 20 ?? ?? 0A 8C</pre>
The question marks I can't seem to work out, but hopefully the rest is ok .

thanks in advance

Jack ... [email protected]
 
In your query:
* the first byte is the slave node ID, 0f hex or 15 decimal

* the 2nd byte is the function code 03, read holding registers

* the 3rd and fourth bytes are starting address 0000

* the fifth and sixth bytes are the quantity of registers 0010 hex or 16 decimal

* the 7th and 8th are CRC; I did not confirm the accuracy of the CRC bytes

In your reply:

* the first byte is the slave node ID, 0F hex or 15 decimal

* the 2nd byte is the function code 03, read holding registers

* the 3rd byte is the Byte count, 20 hex, which should be double the number of registers.
20 hex is double the number of registers, 10 hex

* You have two sets of double question marks. You should have 32 sets of double question marks for the 32 bytes of data from the 16 registers you requested data from.

You don't know what those ?? data values are - that's why you're using Modbus is to find out what they are. That CRC will depend on the what all the data and header bits are.
 
I made a mistake above because I learned to start counting with the number 1, not with the number 0.

Registers 0000 through 0010hex (16 decimal) total 17 (decimal) because register 0000 counts, too.

So the reply should have 34 sets of double question marks for 34 bytes of data from the 17 registers identified in the query.
 
Top