diff --git a/src/blecsan.cpp b/src/blecsan.cpp index 8dd4bb15..34036749 100644 --- a/src/blecsan.cpp +++ b/src/blecsan.cpp @@ -286,8 +286,7 @@ void bt_loop(void * pvParameters) while(1) { - vTaskDelay(10/portTICK_PERIOD_MS); - yield(); + vTaskDelay(10/portTICK_PERIOD_MS); // reset watchdog } end: diff --git a/src/main.cpp b/src/main.cpp index d50a7d1a..bdf6eca3 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -167,11 +167,9 @@ void lorawan_loop(void * pvParameters) { LMIC_reset(); // Reset the MAC state. Session and pending data transfers will be discarded. }; vTaskDelay(1000/portTICK_PERIOD_MS); - yield(); } */ - vTaskDelay(10/portTICK_PERIOD_MS); - yield(); + vTaskDelay(10/portTICK_PERIOD_MS); // reset watchdog } } @@ -233,6 +231,8 @@ void sniffer_loop(void * pvParameters) { channel = (channel % WIFI_CHANNEL_MAX) + 1; wifi_sniffer_set_channel(channel); ESP_LOGD(TAG, "Wifi set channel %d", channel); + + vTaskDelay(10/portTICK_PERIOD_MS); // reset watchdog } } // end of infinite wifi channel rotation loop @@ -627,6 +627,8 @@ void loop() { reset_salt(); // get new salt for salting hashes } + vTaskDelay(10/portTICK_PERIOD_MS); // reset watchdog + } /* end Aruino LOOP ------------------------------------------------------------ */