Device management
Edge devices are physical IoT entities, like sensors, actuators, and switches, that collect and process data locally on the Edge instance. They work the same way as devices on the ThingsBoard server: they report telemetry, respond to RPC commands, and belong to device profiles.
For a general introduction to devices in ThingsBoard, see Devices.
There are two ways to get a device onto an Edge instance:
- Create on Edge: Use this when the device is new and will operate primarily on Edge. ThingsBoard pushes it to the server automatically.
- Assign from server: Use this when the device already exists on the server and you want to make it available on a specific Edge.
Create a device on Edge
Section titled “Create a device on Edge”Devices created on the Edge are pushed to the server automatically once the connection is available. Later changes are synchronized to the server in the same way.
To create a device manually:
-
Go to Devices & assets > Devices, click Add device, and select Add new device.
-
Enter the device Name and select a Device profile, then click Add.
-
Optional: verify connectivity. In the Device created. Let’s check connectivity! dialog, select the protocol (HTTP, MQTT, or CoAP) and your operating system, then run the displayed command in your terminal. The dialog shows the telemetry it receives.
-
Log in to your ThingsBoard server and go to Devices & assets > Devices to confirm the new device was pushed to the server automatically.
If the Edge instance was offline when you created the device, the push happens automatically as soon as the connection to the server is restored.
Assign a device from the server
Section titled “Assign a device from the server”Use this flow when the device already exists on the server and you want to make it available on an Edge. Devices reach an Edge through device groups, so first add the device to a device group.
- On the ThingsBoard server, go to Edge management > Edges and click the Edge.
- On the Details tab, click Manage device groups.
- Click Assign to edge (+), select the group that holds the device, and click Assign.
- On the Edge, go to Devices & assets > Devices to check that the device is there. The Groups column shows the assigned group.
You can also open an assigned group in the same list on the server and add a new device to it. The device reaches the Edge in the same way.
Unassign a device from Edge
Section titled “Unassign a device from Edge”Unassigning a device group removes all its devices from the Edge but keeps them on the server, together with all their data.
- On the ThingsBoard server, open the Edge and click Manage device groups on its Details tab.
- In the row of the group, click Unassign entity group from edge and confirm.
To remove only one device from the Edge, remove it from the group on the server.
Was this helpful?