Changes

Line 137: Line 137:  
'''Note:''' all of this information and more can be viewed by entering this command: '''modbus read -h''' or '''modbus read --help'''.
 
'''Note:''' all of this information and more can be viewed by entering this command: '''modbus read -h''' or '''modbus read --help'''.
   −
For example, lets use this command to get the router's uptime value. If you look back at the table above, you will see that the uptime value is stored in two registers starting from the first register, therefore:
+
For example, lets use this command to get the router's uptime value in seconds. If you look back at the table above, you will see that the uptime value is stored in two registers starting from the first register, therefore:
    
  $ modbus read -w -p 12345 192.168.1.1 %MW001 2
 
  $ modbus read -w -p 12345 192.168.1.1 %MW001 2
Line 153: Line 153:     
[[File:Configuration examples modbus uptime example.png]]
 
[[File:Configuration examples modbus uptime example.png]]
 +
 +
As you can see from the example above, the router returns the values stored in two registers: the first one and the second one. The values returned are presented in '''decimal''' form.
 +
 +
==Interpreting the response==
 +
 +
The values are returned in decimal and, if you add '''-D''' to the command, hexadecimal forms. Sometimes the answer is self-explanatory as in the example above.

Navigation menu