From eb59d7877a967ef24e95169a1989ad8abdfca404 Mon Sep 17 00:00:00 2001 From: Morgan Allen Date: Fri, 21 Sep 2018 21:35:34 -0700 Subject: [PATCH] log reset. log AP index/count info in connect. --- main/esp32-wifi-manager.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/main/esp32-wifi-manager.c b/main/esp32-wifi-manager.c index e907efb..0fa18d3 100644 --- a/main/esp32-wifi-manager.c +++ b/main/esp32-wifi-manager.c @@ -99,6 +99,8 @@ void wifi_manager_connect() { } }; + ESP_LOGI(TAG, "connecting to AP %d of %d", ap_store.last, ap_store.count); + memcpy((char *)&wifi_config.sta.ssid, ap_store.aps[ap_store.last].ssid, strlen(ap_store.aps[ap_store.last].ssid) + 1); memcpy((char *)&wifi_config.sta.password, ap_store.aps[ap_store.last].password, strlen(ap_store.aps[ap_store.last].password) + 1); @@ -152,6 +154,8 @@ void wifi_manager_save_config() { }; void wifi_manager_reset_store() { + ESP_LOGW(TAG, "resetting store"); + memset(&ap_store, 0, sizeof(ap_store)); ap_store.magic = WIFI_MANAGER_MAGIC;