From df5de4b2b51e1388276877121728aaa1af9fbfa2 Mon Sep 17 00:00:00 2001 From: avi Date: Thu, 14 Dec 2023 10:53:09 -0800 Subject: [PATCH] display firmware config and build date in serial debug output --- src/deployable_example.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/deployable_example.cpp b/src/deployable_example.cpp index d4b156c..a7cf564 100644 --- a/src/deployable_example.cpp +++ b/src/deployable_example.cpp @@ -371,7 +371,8 @@ void setup() { Serial.begin(115200); Serial.println("Groundlight ESP32CAM waking up..."); - + + if (esp_sleep_get_wakeup_cause() == ESP_SLEEP_WAKEUP_TIMER) { Serial.println("Wakeup from deep sleep. forcing restart to properly reset wifi module"); ESP.restart(); @@ -389,8 +390,9 @@ void setup() { esp_chip_info_t chip_info; esp_chip_info(&chip_info); debug_printf("ESP32 Chip Revision %d\n", chip_info.revision); - debug_printf("WiFi MAC Address: %s\n", WiFi.macAddress().c_str()); - + debug_printf("WiFi MAC Address: %s\n", WiFi.macAddress().c_str()); + + debug_printf("Firmware : %s built on %s at %s\n", NAME, __DATE__, __TIME__); xTaskCreate( listener, // Function that should be called @@ -1113,6 +1115,9 @@ bool shouldDoNotification(String queryRes) { preferences.end(); return res; } + else { + return false; + } } bool sendNotifications(char *label, camera_fb_t *fb) { preferences.begin("config");