edgehog_device_telemetry_config_t telemetry_config
= { .type = EDGEHOG_TELEMETRY_SYSTEM_STATUS, .period_seconds = 3600 };
edgehog_device_config_t edgehog_conf = { .astarte_device = astarte_device,
.partition_label = "nvs",
.telemetry_config = &telemetry_config,
.telemetry_config_len = 1 };
edgehog_device = edgehog_device_new(&edgehog_conf);
if (!edgehog_device) {
ESP_LOGE(TAG, "Failed to create Edgehog device");
return;
}
...
if (astarte_device_start(astarte_device) != ASTARTE_OK) {
ESP_LOGE(TAG, "Failed to start astarte device");
return;
}