RUT240 MQTT - uplink and downlink

Hello,
I’m new to Teltonika routers and need some hints to an application as follows.

The RUT240 needs to be used to provide cellular connectivity to an IoT device that collects data from sensors. The RUT and the IoT device are connected via ethernet (wired interface, most common protocols that supports ethernet can be used). Our external cloud MQTT will store incoming data from the IoT device and send commands triggered by buttons on a dashboard.
I need to understand what approach can be used to get data from the IoT device (it collects raw data from sensors) and send it to our MQTT broker, and if RUT240 can receive commands sent by our cloud MQTT (in any moment) and transfer this data to our IoT device by ethernet.
Sending data: IoT device → Ethernet → RUT240 → Cellular connectivity → Our cloud MQTT.
Receiving commands: Our cloud MQTT → Cellular connectivity → RUT240 → Ethernet → IoT device.

I have now updated RUT240 firmware to the last version and installed software packages for MQTT, Modbus server and client. When turned on, the RUT connects to our MQTT broker and subscribes to a configured topic, also refreshing MQTT session automatically.

Let me know if you need any further information. Thanks in advance!

Hello,

For this one, all you need to do is to configure the RUT240 as Modbus TCP Client (Master) to periodically collect the data from your IoT device (Modbus Server), and use the ‘Data to Server’ functionality of the router to periodically send the collected data to your MQTT broker. Kindly check this link → https://wiki.teltonika-networks.com/view/RUT240_Data_to_Server for more information and configuration.

For this one, you could configure your router as MQTT Modbus Gateway, where it will listen to a specific request topic coming from the MQTT Broker and then translatest it into a Modbus TCP request to be directed to the IoT device connected to the RUT240.
Here’s a link for guides and configuration → RUT240 Modbus - Teltonika Networks Wiki

Hope this helps.

Best regards,
Robert

This topic was automatically closed after 17 days. New replies are no longer allowed.