How to add an MQTT gateway device in a Zoho IoT application

How to add an MQTT gateway device in a Zoho IoT application

Gateway

A gateway is a device that collects data from connected sensors and transmits it to the Zoho IoT application. It typically cannot gather parameter data on its own but functions as an intermediary, relaying sensor data to the application.

MQTT

Message Queuing Telemetry Transport (MQTT) is a lightweight protocol widely used in IoT applications. It consists of three components: the IoT device, an MQTT broker, and the IoT application. Device connectivity and data transmission occur through specific topics.

In Zoho IoT, the MQTT broker and IoT application are managed by the Zoho IoT application. Gateway devices must be registered as Device Instances in the application to establish communication.

NotesNote: The Zoho IoT application currently supports only MQTT 3.1.1

Why to Add a Device Instance in Zoho IoT?

A Device Instance is added in a Zoho IoT application to represent a device that needs to be connected to the application. The Device Instance holds the connection credentials required to establish communication between the gateway device and the application. It also has the MQTT topics used for sending and receiving telemetry data.

Requirements:

Ensure that you have access to the Zoho IoT application and the necessary privileges to add a Device Instance.

Adding a Device Instance for a Gateway device using the Product Gallery (Device)

To add a device instance for your gateway supporting MQTT protocol,
  1. Access the End Application.
  2. Click on Devices > Devices in the left pane.
  3. Click Add Device.
  4. Select Add Using Product Gallery and click Proceed.
  5. Click the search icon and search for your device. For this example, the TRB245 gateway device is considered.
    Alert
    If your device is not available in the product gallery. skip to the Adding a Device not available in the Product Gallery.
  6. Once you've found your device, click on it. This will open the Device Addition Wizard.
  7. Click Import and Proceed or Proceed (If you had already imported this device product).
  8. Provide a Device Model Name. For this illustration, the name Gateway Devices is provided.
  9. Next, provide the values for the device instance in the required fields.
 

Name
A unique identifier to identify your device.
For this illustration, the name MyTRB Gateway01 is provided.
Description
Additional Information about your device.

Type
The function of your device, if its a gateway or smart sensor or a peripheral.

Since the TRB245 is a gateway device, Gateway option will only be available.

Device Application
The application running on your physical device.

For this illustration we will select Manufacturer defined.
Authentication Type
The security level of the MQTT connection between the physical device and the Zoho IoT application. Root CA and Client Certificate for a connection will become available only if the appropriate option is selected.

It is recommended you use TLS for actual implementation and Non-TLS for testing. For this illustration, the TLS is option is selected.

Data Interval
The frequency of time in minutes the application should wait for the device to send information to the application before the connection is timed out and disconnected.

For this illustration, a Keep Alive Interval of 15 mins is assigned.

Edge Key
A key to identify the particular device in the payload consisting of information about multiple devices.

Since we are adding a device instance for a gateway device, the field is left blank for this illustration.
 
  1. Once you've provided all the required information, click Proceed. The Device Registration successful dialog box with connection details will become available. 
You can use the connection credentials in the physical device and establish a connection with the Zoho IoT application.

Adding a Device Instance for an MQTT Gateway not available in the Device Gallery

In the case your device was not listed in the Zoho IoT device gallery, you can add a device product for your device, and can use it to create a device instance to connect your physical device.

Device Product

A device product in Zoho IoT holds metadata like datapoint definitions and Modbus registry mappings. When a device instance is created, this metadata is included as datapoint templates to its associated device model, and datapoint in the device instance. Device Products are mandatory for adding device instances and aid in scaling the application.

To add a device instance by first adding a device product,
  1. Select Devices > Devices in the left navigation pane.
  2. Click Add Device.
  3. Select Add By Defining your Device Product and click Proceed. This will open the New Device Wizard.
  4. The first step is to create a device product. In this you will be providing the configuration allowed for a particular device product.
  5. Provide the required details in the following fields for your device product.
Name
A name for your device product.
Description
Additional information about your device product can be provided here.
Manufacturer Name
The manufacturer of your physical Device. Unlike other field, The Manufacturer field takes a Manufacturer Module Instance as the input, For that you have separately create manufacturer first as show here.

For now, it is advisable you simply leave this field empty.

Device Type


The function of your device must be selected here.

Gateway: If your physical device is a gateway device that collects data from various sensors and peripherals and send it to the application.

Smart Sensor: The device collects data and is capable of directly sending it to the application.

Peripheral: The physical device can only collect data and send it to a gateway device and not directly to the application.

Since we are adding a Gateway Device, Select the Gateway Option.

Compatible Device Application

This indicates the type of application running on your physical device.

Manufacturer defined: The application is provided by the device manufacturer themselves.

Custom Application: You have built your own application using various SDKs to run on the device.

For this illustration, we will select custom application and manufacturer defined as both is possible for a gateway device. But only one option will be selected while adding the device instance.


Device Connectivity
Select the protocol with which your gateway device will communicate with the Zoho IoT application. Here, if your device can support both MQTT and HTTPS, you can select both. Selecting both will give you the option to select which device protocol your device instance will use. Only one can be selected while adding the device instance.

For this example we will select only MQTT as the device considered for this illustration can only connect using MQTT.

 

  1. Once all the field details are provided, click Add.

Info
Once you click 'Add', a device product for your device will be added, and it will be available in the device gallery under the My Products Section. If you want to add another instance of the same device product, you can use the Add Using Product Gallery (Devices).

  1. After clicking Add, you will be moved to step 2 where you will need to add the datapoint definitions of your device product.
  2. You can Add a Datapoint Definitions now or at later time from the Developer mode. For this illustration, we are not adding any datapoint definitions as the gateway device generally does not generate any data of its own.
  3. Click Proceed.
  4. Now In step 3, you will be adding a device instance to represent your physical device in the application.
  5. Toggle to the Create New Model option and provide a name for your device model. For this illustration, the name Industrial Gateway is provided.
  6. Next, proceed to provide the information in the required field about your device instance.

Name
A unique identifier to identify your device.

For this illustration, the name MyGateway01 is provided.
Description
Additional Information about your device.
Type
The function of your device, if it's a gateway or smart sensor or a peripheral.

Since we defined the Device product as a gateway, only the Gateway option will be available and selected by default.
Device Application
The application running on your physical device.

For this illustration, we will select Custom Application, assuming that you have built your own device application. If your device runs a Manufacturer defined application, then select Manufacturer Defined.
Authentication Type

The security level of the MQTT connection between the physical device and the Zoho IoT application. Root CA and Client Certificate for a connection will become available only if the appropriate option is selected.

It is recommended you use TLS for actual implementation and Non-TLS for testing. For this illustration, the TLS is option is selected.
Data Interval
The frequency of time in minutes the application should wait for the device to send information to the application before the connection is timed out and disconnected.

For this illustration, a Keep Alive Interval of 15 mins is assigned.
Edge Key
A key to identify the particular device in the payload consisting of information about multiple devices.

Since it's a gateway device, the field is left blank.

 

  1. After providing the required information, click Add. A new device instance representing your physical device will be added to the application and it's connection details will now be displayed.
You can use this connection details document to establish communication between your physical device and the Zoho IoT application.

      Create. Review. Publish.

      Write, edit, collaborate on, and publish documents to different content management platforms.

      Get Started Now


        Access your files securely from anywhere

          Zoho CRM Training Programs

          Learn how to use the best tools for sales force automation and better customer engagement from Zoho's implementation specialists.

          Zoho CRM Training
            Redefine the way you work
            with Zoho Workplace

              Zoho DataPrep Personalized Demo

              If you'd like a personalized walk-through of our data preparation tool, please request a demo and we'll be happy to show you how to get the best out of Zoho DataPrep.

              Zoho CRM Training

                Create, share, and deliver

                beautiful slides from anywhere.

                Get Started Now


                  Zoho Sign now offers specialized one-on-one training for both administrators and developers.

                  BOOK A SESSION







                              Quick LinksWorkflow AutomationData Collection
                              Web FormsRetailOnline Data Collection Tool
                              Embeddable FormsBankingBegin Data Collection
                              Interactive FormsWorkplaceData Collection App
                              CRM FormsCustomer ServiceForms for Solopreneurs
                              Digital FormsMarketingForms for Small Business
                              HTML FormsEducationForms for Enterprise
                              Contact FormsE-commerceForms for any business
                              Lead Generation FormsHealthcareForms for Startups
                              Wordpress FormsCustomer onboardingForms for Small Business
                              No Code FormsConstructionRSVP tool for holidays
                              Free FormsTravelFeatures for Order Forms
                              Prefill FormsNon-Profit
                              Forms for Government
                              Intake FormsLegal
                              Mobile App
                              Form DesignerHR
                              Mobile Forms
                              Card FormsFoodOffline Forms
                              Assign FormsPhotographyMobile Forms Features
                              Translate FormsReal EstateKiosk in Mobile Forms
                              Electronic FormsInsurance
                              Drag & drop form builder

                              Notification Emails for FormsAlternativesSecurity & Compliance
                              Holiday FormsGoogle Forms alternative GDPR
                              Form to PDFJotform alternativeHIPAA Forms
                              Email FormsWufoo alternativeEncrypted Forms
                              Accessible FormsTypeform alternativeSecure Forms

                              WCAG

                                          Create. Review. Publish.

                                          Write, edit, collaborate on, and publish documents to different content management platforms.

                                          Get Started Now






                                                            You are currently viewing the help pages of Qntrl’s earlier version. Click here to view our latest version—Qntrl 3.0's help articles.




                                                                Manage your brands on social media

                                                                  Use cases

                                                                  Make the most of Zoho Desk with the use cases.

                                                                   
                                                                    

                                                                  eBooks

                                                                  Download free eBooks and access a range of topics to get deeper insight on successfully using Zoho Desk.

                                                                   
                                                                    

                                                                  Videos

                                                                  Watch comprehensive videos on features and other important topics that will help you master Zoho Desk.

                                                                   
                                                                    

                                                                  Webinar

                                                                  Sign up for our webinars and learn the Zoho Desk basics, from customization to automation and more

                                                                   
                                                                    
                                                                  • Desk Community Learning Series


                                                                  • Meetups


                                                                  • Ask the Experts


                                                                  • Kbase


                                                                  • Resources


                                                                  • Glossary


                                                                  • Desk Marketplace


                                                                  • MVP Corner



                                                                    Zoho Sheet Resources

                                                                     

                                                                        Zoho Forms Resources


                                                                          Secure your business
                                                                          communication with Zoho Mail


                                                                          Mail on the move with
                                                                          Zoho Mail mobile application

                                                                            Stay on top of your schedule
                                                                            at all times


                                                                            Carry your calendar with you
                                                                            Anytime, anywhere




                                                                                  Zoho Sign Resources

                                                                                    Sign, Paperless!

                                                                                    Sign and send business documents on the go!

                                                                                    Get Started Now




                                                                                            Zoho TeamInbox Resources





                                                                                                      Zoho DataPrep Demo

                                                                                                      Get a personalized demo or POC

                                                                                                      REGISTER NOW


                                                                                                        Design. Discuss. Deliver.

                                                                                                        Create visually engaging stories with Zoho Show.

                                                                                                        Get Started Now









                                                                                                                            • Related Articles

                                                                                                                            • Creating a Device for Raspberry Pi in Zoho IOT application

                                                                                                                              With the physical setup of connecting the DHT22 sensor complete, we can now create a device in the Zoho IOT application to represent this raspberry pi. This device created I the application will have the necessary credentials to establish a ...
                                                                                                                            • Phase 1: Getting Started

                                                                                                                              Welcome to Zoho IOT's Diesel Generator Tutorial! This tutorial will provide you with step-by-step procedure to create a real-world IoT-based monitoring solution using Zoho IOT. In the process, you'll explore various features and functions and learn ...
                                                                                                                            • Zoho IoT Agent

                                                                                                                              The Zoho IoT Agent is an application software created by Zoho IoT for compatible IoT Gateway devices and is engineered to facilitate easy integration with Zoho IoT applications. They enable seamless and quick configurations. You can configure the ...
                                                                                                                            • Add Device: API Endpoint

                                                                                                                              Prerequisite Before proceeding with this document, please ensure you have read the following prerequisite materials to fully understand the concepts discussed here: Understanding Devices Understanding Device Models Understanding Device Products ...
                                                                                                                            • Add Device: As Own Device Product

                                                                                                                              Prerequisite Before proceeding with this document, please ensure you have read the following prerequisite materials to fully understand the concepts discussed here: Understanding Devices Understanding Device Models Understanding Device Products ...
                                                                                                                              Wherever you are is as good as
                                                                                                                              your workplace

                                                                                                                                Resources

                                                                                                                                Videos

                                                                                                                                Watch comprehensive videos on features and other important topics that will help you master Zoho CRM.



                                                                                                                                eBooks

                                                                                                                                Download free eBooks and access a range of topics to get deeper insight on successfully using Zoho CRM.



                                                                                                                                Webinars

                                                                                                                                Sign up for our webinars and learn the Zoho CRM basics, from customization to sales force automation and more.



                                                                                                                                CRM Tips

                                                                                                                                Make the most of Zoho CRM with these useful tips.



                                                                                                                                  Zoho Show Resources