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.
+2 votes
247 views 1 comments
by anonymous
in the Teltonika manual i read how to get additional custom modbus registers with this script

---------------------------------------------------------------

#!/bin/ash

 while true

 do

 date > /tmp/regfile #where to store the data

 gsmctl -X >> /tmp/regfile

 gsmctl -E >> /tmp/regfile

 sleep 5

 ready

----------------------------------------------------

https://wiki.teltonika-networks.com/view/RUT955_modbus_custom_register_block

but they didn't choose a fixed register number, they automatically make it start at 1025 for 14 rigisterns.

Can I set a register number with this script? and what command should be used?

Thanks

1 Answer

0 votes
by anonymous
Hello,

You can set register number by navigating to the services > Modbus > Modbus TCP Slave > Enable custom register block > in the option field "register count" type the register number > click "SAVE & APPLY".

Regards,
by anonymous

thanks

I have defined a custom Modbus register that starts with 1025 for a length of 100 registers.

If I want to store two other values in the custom register block, the date should be automatically stored in register 1025, but the second and third values should be stored in which register number? or can I specify in the script that the second value should be stored in register 1050 and the third in register 1060?