Skip to content

Commit

Permalink
Release wifi module before sleeping
Browse files Browse the repository at this point in the history
  • Loading branch information
MewBiscuit committed Dec 22, 2023
1 parent bb5f09f commit 0818cef
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion main/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,7 @@ extern "C" void app_main(void) {
post_numerical_data("noise", &noise, TOPIC, tb_client);
post_numerical_data("weight", &weight, TOPIC, tb_client);

vTaskDelay(5000 / portTICK_PERIOD_MS); // Wait 5 seconds to avoid sleeping before sending data and to give chance to open the box
vTaskDelay(5000 / portTICK_PERIOD_MS); // Wait 5 seconds to avoid sleeping before sending data
wifi_release();
esp_deep_sleep_start();
}

0 comments on commit 0818cef

Please sign in to comment.