From 2d9572bde3272f74a88ac9220385b9f10307ba3d Mon Sep 17 00:00:00 2001 From: Alexander Bobkov Date: Fri, 10 Oct 2025 01:06:06 -0400 Subject: [PATCH] . --- ESP32-IDF_Temperture-Node-v2/main/mqttronix.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ESP32-IDF_Temperture-Node-v2/main/mqttronix.c b/ESP32-IDF_Temperture-Node-v2/main/mqttronix.c index b6186a39d..01394e6b4 100644 --- a/ESP32-IDF_Temperture-Node-v2/main/mqttronix.c +++ b/ESP32-IDF_Temperture-Node-v2/main/mqttronix.c @@ -24,6 +24,8 @@ static float pressure_value = 0.0f; static float humidity_value = 0.0f; static char temp_str[6]; +static char humidity_str[6]; +static char pressure_str[6]; static esp_mqtt_client_handle_t mqtt_client = NULL; @@ -137,7 +139,7 @@ void mqttronix_update_temp (float temp) { temp_value = temp; snprintf(temp_str, sizeof(temp_str), "%.02f", temp_value); } -void mqttronix_update_humidity (float temp) { +void mqttronix_update_humidity (float humidity) { humidity_value = humidity; - snprintf(temp_str, sizeof(temp_str), "%.02f", temp_value); + snprintf(humidity_str, sizeof(humidity_str), "%.02f", humidity_value); } \ No newline at end of file