From a58a8d134441e7a9b76fe075ac7bfbcae53efee0 Mon Sep 17 00:00:00 2001 From: CommanderRedYT Date: Wed, 11 May 2022 20:29:09 +0200 Subject: [PATCH] Modified blinker message --- main/bobbyblinker.cpp | 2 +- main/espnowfunctions.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/main/bobbyblinker.cpp b/main/bobbyblinker.cpp index 7766be0..c9bc71e 100644 --- a/main/bobbyblinker.cpp +++ b/main/bobbyblinker.cpp @@ -18,7 +18,7 @@ namespace { void sendState(const std::string& state) { - if (const auto error = espnow::send_espnow_message(fmt::format("{}:0:{}", state, configs.anhaenger_id.value)); error != ESP_OK) + if (const auto error = espnow::send_espnow_message(fmt::format("{}:{}:{}", state, espchrono::utc_clock::now().time_since_epoch().count(), configs.anhaenger_id.value)); error != ESP_OK) { ESP_LOGE(TAG, "Error sending blinker message: %s", esp_err_to_name(error)); } diff --git a/main/espnowfunctions.cpp b/main/espnowfunctions.cpp index a73ceab..93e7ed8 100644 --- a/main/espnowfunctions.cpp +++ b/main/espnowfunctions.cpp @@ -307,7 +307,7 @@ esp_err_t send_espnow_message(std::string_view message) else { const auto timeAfter = espchrono::millis_clock::now(); - ESP_LOGD(TAG, "Successfully executed esp_now_send(): Took %lldms", std::chrono::floor(timeAfter-timeBefore).count()); + ESP_LOGI(TAG, "Successfully executed esp_now_send(): Took %lldms", std::chrono::floor(timeAfter-timeBefore).count()); } } return ESP_OK;