This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Nocive MQTT Question
#1
Hello,

I have several Teltonika TRB141 installed on remote sites that monitors a water tank. Until now i use a central LM to get sensors values via POST/GET.

I have never worked before with MQTT and knowing that Teltonika & LM both support it i was wondering if there are any major advantages using it for my case.
If so are there any guides on how to implement it?

In the link below is a very basic MQTT guide for Teltonika 
https://wiki.teltonika-networks.com/view...g_via_MQTT

Thank you in advance

George
Reply
#2
The major advantage is that MQTT is event-based so you will get data more or less instantly. For sensor data this might not be needed though.

First you need to install MQTT broker app on LM and enable the broker. Then you need a client script which will subscribe to sensor data topics and will send values to mapped group addresses.
Client example: https://forum.logicmachine.net/showthrea...6#pid10926
Change broker IP to 127.0.0.1 to use internal MQTT broker.
Reply
#3
(29.06.2022, 12:47)admin Wrote: The major advantage is that MQTT is event-based so you will get data more or less instantly. For sensor data this might not be needed though.

First you need to install MQTT broker app on LM and enable the broker. Then you need a client script which will subscribe to sensor data topics and will send values to mapped group addresses.
Client example: https://forum.logicmachine.net/showthrea...6#pid10926
Change broker IP to 127.0.0.1 to use internal MQTT broker.

Will the LM Broker work via LM cloud? or do you need to make a port forward on the MQTTports in firewall?
Reply
#4
LM cloud has MQTT broker as Mosaic and everything else is using MQTT but why do you ask?
------------------------------
Ctrl+F5
Reply
#5
Could be that I do not understand the broker function, but if I want a remote system to recieve data from LM via MQTT, does not the broker need to be accessable from outside?
Reply
#6
MQTT is a clinet to broker communication and the client is to establish the connection to broker. If another client is somewhere in the 'internet' then the broker also should be on some server. Explain exactly what you trying to connect to LM.
Theoretically if you use broker on LM and open ports to broker it should work but this is not correct approach(from security point of view).
------------------------------
Ctrl+F5
Reply
#7
I just wanted a easy way to send data to my remote SCADA without the use of VPN and such.
If I understand you right, I should subscribe to a cloud based broker?
Reply
#8
Yes
------------------------------
Ctrl+F5
Reply
#9
Or you can use ZeroTier.
Reply
#10
(16.11.2022, 13:17)admin Wrote: Or you can use ZeroTier.

Sure, but I was abit interrested in learning MQTT as well Smile
Reply
#11
I was referring to using MQTT over ZeroTier.
Reply
#12
oh, thats also a thing. Thanks. Will look in to that also
Reply


Forum Jump: