diff --git a/test/wm-test-project/main/main.c b/test/wm-test-project/main/main.c index f5f2cb8..58e7117 100644 --- a/test/wm-test-project/main/main.c +++ b/test/wm-test-project/main/main.c @@ -71,11 +71,13 @@ void loop(void *p) { while(true) { vTaskDelay(5000 / portTICK_PERIOD_MS); - ESP_LOGI(TAG, "resetting store"); + EventBits_t ev_bits = xEventGroupGetBits(wm_event_group); - wifi_manager_reset_store(); + if(ev_bits & WIFI_CONNECTED) { + vTaskDelay(5000 / portTICK_PERIOD_MS); - while(true) {}; + ESP_LOGI(TAG, "Got connection!"); + } } }