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.
0 votes
397 views 1 comments
by anonymous
Hi

I am using a RUT 956 with the latest firmware RUT9M R_00.07.4.1. I have configured the unit to read a modbus RTU slave RS 485 (using Modbus Serial Master) and that works fine when querying the slave from the units dashboard. I have set up the Data to Server (Advance Server Settings) to send the data via MQTT every 60 secs and configured the correct URL and topic (although the system does not ask for a password??). There does not appear to be any data incoming data to the MQTT broker. Also, the there is no reference in the log files for any outgoing problems and I cannot find any way of viewing what, if any, data is going out from the unit. I have pinged external IP addresses to check a WAN connection. Any pointers please.

Update:- I have the unit sending data to the broker now. One minor problem is i need two pieces of separate data both are integers one is "Status" the other is "TSS" it reads and sends the TSS data but not the Status and I do not know how to extract that data from the modbus and send it via MQTT. My code below

{"timestamp": %t,  "Status": ??, "TSS": %a}

1 Answer

+1 vote
by anonymous

Hi,

One of the common issues when configuring 'Data to server' is that the JSON format field is often left out. The grey text in the JSON format field is not there and is only used as an example. Please, ensure that you actually put the format into that field manually (you can rewrite the existing grey text manually).

Also, the last slider on the configuration page, 'Use credentials', can be turned on. This will allow you to enter a username and a password.

If that was not the issue in your case, I would like you to attach a troubleshoot file to your question by editing it. Troubleshoot file can be downloaded from System -> Administration -> Troubleshoot. The attached files are only visible to Teltonika moderators.

Kind Regards,

Andzej

Best answer
by anonymous
Hi Andzej

Thank you very much for the response, I had inputted the JSON code into the dialogue, sadly I am not a programmer (by a long way) and I am unsure if the code needs variable placeholders as per the examples below, the first is what is being used in the dialogue box at the moment, the second is what I have tried before. I have attached the trouble shoot file to my original query, I also have a system log as a txt file but could only attach one file. I feel I am doing something really simple wrong.

{

"params" : {

"Status" : , "TSS" :  

}

}

#(previously tried)  {"TS": "%t", "Status": "%d", "TSS": %a}