From f40f030f5748e62ee7624efcabf98b96d98863c4 Mon Sep 17 00:00:00 2001 From: Luc <8822552+luc-github@users.noreply.github.com> Date: Mon, 21 Feb 2022 14:56:06 +0800 Subject: [PATCH] Update esp3dlib.cpp --- src/esp3dlib.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/esp3dlib.cpp b/src/esp3dlib.cpp index dee4be4..55b5fb9 100644 --- a/src/esp3dlib.cpp +++ b/src/esp3dlib.cpp @@ -41,7 +41,7 @@ void ESP3DLibTaskfn( void * parameter ) //Main loop for(;;) { myesp3d.handle(); - Hal::wait (0); // Yield to other tasks + vTaskDelay(1 / portTICK_RATE_MS); } vTaskDelete( Hal::xHandle ); } @@ -65,9 +65,9 @@ void Esp3DLib::init() &(Hal::xHandle), /* Task handle to keep track of created task */ ESP3DLIB_RUNNING_CORE /* Core to run the task */ ); - #ifdef DISABLE_WDT_ESP3DLIB_TASK +#ifdef DISABLE_WDT_ESP3DLIB_TASK esp_task_wdt_delete(Hal::xHandle); - #endif //DISABLE_WDT_ESP3DLIB_TASK +#endif //DISABLE_WDT_ESP3DLIB_TASK } //Parse command bool Esp3DLib::parse(char * cmd)