IoT Internet of Things
Core Positioning
The IoT module is a device management platform similar to Alibaba Cloud IoT Platform. It can connect massive devices, define device capabilities through thing models, process device data using a rule engine, and achieve device data collection, remote control, and scenario linkage.
In one sentence: If your hardware devices need cloud-based management, this provides the complete chain from device registration to data flow.
Problems Solved
| Pain Point | How IoT Solves It |
|---|---|
| Diverse device access protocols | Supports MQTT/HTTP/CoAP/TCP/UDP/WebSocket/Modbus etc. |
| Non-uniform device data formats | Thing model standardizes device capability definitions |
| Don’t know how to process device data | Rule engine → data routing/scenario linkage/alerts |
| Difficult device firmware upgrades | OTA remote upgrades |
| Need to integrate with third-party IoT platforms | Built-in EMQX integration, customizable protocols |
User Roles
graph LR
subgraph Roles
IOT_ADMIN["IoT Admin
Define products
Manage devices
Configure thing models
Set up rule engine"] IOT_DEV["Device Developer
Device-side development
Protocol integration
OTA upgrades"] IOT_OP["Operations Staff
Monitor device status
Handle alerts
Data analysis"] end
Define products
Manage devices
Configure thing models
Set up rule engine"] IOT_DEV["Device Developer
Device-side development
Protocol integration
OTA upgrades"] IOT_OP["Operations Staff
Monitor device status
Handle alerts
Data analysis"] end
Platform Architecture
graph TB
subgraph DeviceLayer["Device Layer"]
D1["Sensors"]
D2["Gateways"]
D3["Controllers"]
D4["Smart Devices"]
end
subgraph AccessLayer["Access Layer (Multi-Protocol)"]
P1["MQTT"]
P2["HTTP"]
P3["CoAP"]
P4["TCP/UDP"]
P5["WebSocket"]
P6["Modbus"]
end
subgraph PlatformLayer["IoT Platform"]
PRODUCT["Product Management
Define device types"] DEVICE["Device Management
Registration/Authentication/Status"] MODEL["Thing Model
Properties/Services/Events"] OTA["OTA Upgrade
Firmware remote updates"] end subgraph ProcessingLayer["Data Processing Layer"] RULE["Rule Engine
Data rules/Scenario linkage/Alerts"] TD["TDengine
Time-series data storage"] end DeviceLayer --> AccessLayer AccessLayer --> PlatformLayer PlatformLayer --> ProcessingLayer
Define device types"] DEVICE["Device Management
Registration/Authentication/Status"] MODEL["Thing Model
Properties/Services/Events"] OTA["OTA Upgrade
Firmware remote updates"] end subgraph ProcessingLayer["Data Processing Layer"] RULE["Rule Engine
Data rules/Scenario linkage/Alerts"] TD["TDengine
Time-series data storage"] end DeviceLayer --> AccessLayer AccessLayer --> PlatformLayer PlatformLayer --> ProcessingLayer
Thing Model Design
The thing model is the core concept of IoT, describing in a standardized way “what attributes a device has, what it can do, and what it reports”:
graph TB
subgraph ThingModel["Thing Model = Digital Description of Device"]
ATTR["Property
Static characteristics of device
Example: Temperature, Humidity, Switch State"] SERVICE["Service
Actions the device can execute
Example: Unlock, Restart, Calibrate"] EVENT["Event
Information actively reported by device
Example: Alerts, Faults, Completion Notifications"] end
Static characteristics of device
Example: Temperature, Humidity, Switch State"] SERVICE["Service
Actions the device can execute
Example: Unlock, Restart, Calibrate"] EVENT["Event
Information actively reported by device
Example: Alerts, Faults, Completion Notifications"] end
Rule Engine
flowchart LR
DATA["Device Data"] --> ENGINE["Rule Engine"]
ENGINE -->|Data Rules| ROUTE1["Data Routing
Store to TDengine
Forward to HTTP/Kafka"] ENGINE -->|Scenario Linkage| ROUTE2["Scenario Linkage
Temp > 30°C → Auto-turn on fan"] ENGINE -->|Alert Config| ROUTE3["Alerts
Device offline > 5 min → Send notification"]
Store to TDengine
Forward to HTTP/Kafka"] ENGINE -->|Scenario Linkage| ROUTE2["Scenario Linkage
Temp > 30°C → Auto-turn on fan"] ENGINE -->|Alert Config| ROUTE3["Alerts
Device offline > 5 min → Send notification"]
Device Lifecycle
flowchart LR
CREATE["Create Product
Define thing model"] --> REG["Register Device
Get authentication info"] REG --> ONLINE["Device Online
Establish connection"] ONLINE --> WORK["Normal Operation
Report data/Receive commands"] WORK --> OTA2["OTA Upgrade"] OTA2 --> WORK WORK --> OFFLINE["Device Offline"] OFFLINE --> ONLINE
Define thing model"] --> REG["Register Device
Get authentication info"] REG --> ONLINE["Device Online
Establish connection"] ONLINE --> WORK["Normal Operation
Report data/Receive commands"] WORK --> OTA2["OTA Upgrade"] OTA2 --> WORK WORK --> OFFLINE["Device Offline"] OFFLINE --> ONLINE
Supported Protocols
| Protocol | Use Case | Features |
|---|---|---|
| MQTT | Mainstream IoT protocol | Lightweight, pub-sub, QoS |
| HTTP | Simple devices, web apps | High versatility |
| CoAP | Low-power devices | HTTP-like, UDP |
| TCP | Custom protocols | Flexible, efficient |
| UDP | High-frequency data reporting | Low latency |
| WebSocket | Real-time bidirectional communication | Browser-friendly |
| Modbus | Industrial devices | Industrial control standard |
| EMQX | High-performance MQTT Broker | Million-level connections |
| Custom Protocol | Special devices | Extension development |
Technical Dependencies
- TDengine: Time-series database for storing massive time-series data reported by devices (requires separate setup)
- EMQX: High-performance MQTT Broker (optional, for large-scale device access)