MQTT Node

      MQTT Node


        Article summary

        MQTT Node

        MQTT is a lightweight communication protocol ideal for embedded devices with limited connectivity. It is the preferred communication mechanism between your devices and the Rayven Platform.

        You can use the MQTT node to receive data from devices using the MQTT communication protocol. A single MQTT node can receive data for all the devices in your solution. It will output each device payload in the order received.

        The IP address of the Rayven MQTT broker is 52.169.16.32

        Adding an MQTT node to your workflow

        1. First, select your desired solution and navigate to the Rayven Workflow.
        2. Select ‘Inputs’ from the left-hand panel.
        3. Find the MQTT node and drag it onto the canvas.
        4. Double click on the MQTT node to open its configuration window.

        Configuring your MQTT node

        1. Give your node a name. Choose something simple that clearly explains its purpose. You must pick a name that has three or more characters.
        2. Select a broker type from the drop-down menu. The options are:
          • TCP, 
          • TLS, 
          • WebSockets, 
          • Secure WebSockets.
        3. Enter a username. For the node to receive data, this must match the username entered on the device or hardware.
        4. Each MQTT node generates a unique topic ID. This ID will be auto-filled and can't be changed. You must send data to Rayven in the following format:
          • [[topic_ID]]/[[device_ID]]
          • You must append the unique device ID to the topic ID. Ensure you include the slash after the topic ID.
        5. You will see an auto-filled unique URL. This URL points to the Rayven server and can't be changed. 
        6. Select the payload format from the drop-down menu. JSON is the recommended default, but String and XML formats are also supported. 
        7. You can enter a Client ID as an optional additional parameter.
        8. Choose whether to configure a password for extra security. For successful authentication, this password must match the one set on your device. It must be at least 8 characters long and include at least one lower case character, one upper case character, and one special character such as ! or *.
        9. It is possible to send unique device IDs by entering the payload field name that contains the device ID under 'Payload Device ID Field Name'.

        Adding timestamps

        You can configure the timestamps of your input node so that it records when it receives data from a device. The device will need to have a time zone configured, and you will need to define the following fields on your HTTP input node:

        1. Date Field Name
          • Enter the name of the date field as it appears in the device payload. 
        2. Date Format
          • Specify the format of the data received, for example, dd/MM/yyyy or hh:mm:ss. 
          • If using a 24-hour format, enter the hours in capital letters (e.g. HH/mm/ss). 
        3. Timezone
          • Select the time zone for the device from a drop-down list. 

        Activation

        Once you have finished configuring the node, click 'activate' and then 'save'. The node is now ready to receive data.

        See Also: Section 3.3: Adding and Managing Devices
        As of Release: 17.11.2021


        What's Next