Connect a Device
In order to register an Appliance to Clea you need to write a software agent on your device that connects and sends data to Astarte platform. You can find more information about Astarte by checking out the product documentation on this page: Astarte docs
First of all, you need to register your device to Astarte Platform, check here for more info:
Astarte docs - Registering a Device
You can do it in two ways:
- Through the online dashboard of Astarte, accessible from the Admin Console.
- Directly from the device, through the SDKs that allow it (at the time of writing Java, C/ESP32) using the Pairing Token that can be found in the Admin Console and the Device ID generated internally, as
UUIDv5
, generated with the SDK’s functionality.
At the end of the registration phase, you will receive a Credential Secret that you will use with the Device ID to connect to Astarte and perform all the necessary operations. Astarte docs - Connecting a Device
Astarte SDKs
Use one of the Astarte SDKs to write the software that connects to the platform and sends the first data. Here you can find a detailed list of available Astarte SDKs:
Language / Platform | Status | Link | Note |
---|---|---|---|
Java / Android | Stable | https://github.com/astarte-platform/astarte-device-sdk-java | Available also on Maven |
C++ (Qt5) | Stable | https://github.com/astarte-platform/astarte-device-sdk-qt5 | |
C (ESP32) | Stable | https://github.com/astarte-platform/astarte-device-sdk-esp32 | |
Elixir | Stable | https://github.com/astarte-platform/astarte-device-sdk-elixir | Available also on hex.pm |
Python | Beta | https://github.com/astarte-platform/astarte-device-sdk-python | Available also on pip |
Rust | Beta | https://github.com/astarte-platform/astarte-device-sdk-rust | |
Go | Beta | https://github.com/astarte-platform/astarte-device-sdk-go |
Within the SDKs repositories you can find resources and minimal examples to take your first steps with the platform.
You can find more info and details of the Astarte SDKs and their features in the Astarte Device SDKs page in the Astarte documentation.
Clea Examples
You can find some examples of complete Clea applications, including edge agent parts written using Astarte SDKs in the Clea Examples repository.
Add an Appliance to Clea Portal
Once a device is correctly connected and sends data to Astarte, it is possible to use the Astarte Device ID to add an appliance on the Clea Portal from the Add Appliance page.
The appliance now registered is associated with a device within that is connected to the system.
Thanks to the Device ID, the Clea Portal and Clea Portal Apps can interact with the appliance data, either incoming or outgoing, communicating directly with the Astarte platform.