Skip to content

Open-source IoT Gateway - integrates devices connected to legacy and third-party systems with ThingsBoard IoT Platform using Modbus, CAN bus, BACnet, BLE, OPC-UA, MQTT, ODBC and REST protocols

License

Notifications You must be signed in to change notification settings

thingsboard/thingsboard-gateway

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

ThingsBoard IoT Gateway

The ThingsBoard IoT Gateway is an open-source, Python-based application that enables seamless integration of legacy and third-party devices with the ThingsBoard IoT platform. It serves as a protocol adapter that collects data from external sources and publishes it to ThingsBoard via a unified format.

πŸ“– What is ThingsBoard IoT Gateway?

πŸ’‘ New to ThingsBoard? Learn what ThingsBoard is


πŸš€ Getting Started

Curious how the ThingsBoard IoT Gateway works in action?

➑️ Follow our Getting Started Guide to:

  • πŸš€ Run the gateway in minutes using pre-configured demo servers
  • πŸ”„ Simulate device data collection and processing workflows
  • πŸ§ͺ Explore telemetry, attributes, and RPCs without real devices
  • πŸ–₯️ Test integration with ThingsBoard Community or Professional Edition

πŸ’‘ Ideal for evaluation, proof-of-concept, and learning how the gateway processes and routes data.


What is ThingsBoard IoT Gateway?

πŸ”Œ Gateway Features

ThingsBoard IoT Gateway supports a wide range of industrial and IoT protocols out of the box. Each connector enables collecting data from external systems, transforming it into a unified format, and forwarding it to ThingsBoard.

πŸ“Ÿ Industrial & SCADA Protocols

  • Modbus – Integrate with Modbus TCP/RTU devices like PLCs and energy meters.
  • OPC-UA – Connect to industrial automation systems using the OPC-UA protocol.
  • CAN – Communicate with devices over the Controller Area Network (e.g., automotive, industrial equipment).
  • ODBC – Retrieve telemetry from SQL-compliant databases.

🌐 IoT & Networking Protocols

  • MQTT – Subscribe to external MQTT brokers and ingest messages.
  • REST API – Push data to REST endpoints created by gateway.
  • Request Connector – Periodically pull data from HTTP(S) APIs and ingest response payloads.
  • FTP – Read files from FTP/SFTP servers for batch data ingestion.
  • Socket – Request data via raw TCP/UDP socket connections.
  • SNMP – Poll SNMP devices to collect MIB data from routers, switches, sensors.
  • XMPP – Receive telemetry from XMPP-based chat/device networks.

πŸ“‘ Smart Energy & Charging

  • OCPP – Integrate EV charging stations using Open Charge Point Protocol.

🏠 Smart Building & Home Automation

  • BACnet – Gather building automation data (HVAC, lighting, fire systems).
  • KNX – Interface with KNX-based building automation systems.
  • BLE – Scan and connect to BLE-enabled devices (e.g., beacons, wearables).

🧩 Extensibility

  • Custom Connectors – Build your own protocol handlers using Python to support any proprietary system or emerging protocol.

✨ All connectors support flexible configuration, data transformation, and integration with the ThingsBoard platform's device model.

🧰 Core Gateway Capabilities

In addition to multi-protocol support, the ThingsBoard IoT Gateway includes robust features for reliability, remote management, and automation:

πŸ”’ Reliability & Resilience

  • Data persistence – Buffers telemetry locally to prevent data loss during network or system outages.
  • Automatic reconnection – Automatically restores connection to the ThingsBoard cluster after temporary failures.

πŸ”„ Unified Data Processing

  • Data mapping engine – Transforms raw input from devices into ThingsBoard’s unified data format using customizable converters.

πŸ› οΈ Remote Management & Control

πŸ”„ Device Lifecycle Handling

πŸ—οΈ Architecture Overview

The IoT Gateway is implemented in Python, allowing powerful extension and customization. It follows a modular architecture resembling microservices.

  • Custom connectors let you interface with new devices or services.
  • Custom converters allow transformation of incoming messages to a ThingsBoard-compatible format.
  • The Gateway provides simple integration APIs, and encapsulates common Thingsboard related tasks: device provisioning, local data persistence and delivery, message converters and other.

Ideal for edge use cases where flexibility and protocol diversity are key.


πŸ’¬ Support & Community

Need help or want to share ideas?

🐞 Found a bug? Please open an issue.


⭐ Contributing

We welcome contributions! Feel free to fork the repo, open PRs, or help triage issues.


βš–οΈ License

This project is licensed under the Apache 2.0 License.


🌟 Don't forget to star the repository to show your ❀️ and support!

About

Open-source IoT Gateway - integrates devices connected to legacy and third-party systems with ThingsBoard IoT Platform using Modbus, CAN bus, BACnet, BLE, OPC-UA, MQTT, ODBC and REST protocols

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages