diff --git a/library.properties b/library.properties index 85c21b8..4b9fca5 100644 --- a/library.properties +++ b/library.properties @@ -1,5 +1,5 @@ name=Task by Makuna -version=1.1.1 +version=1.1.2 author=Michael C. Miller (makuna@live.com) maintainer=Michael C. Miller (makuna@live.com) sentence=A library that makes creating complex mulitple task projects easy. diff --git a/src/Task.h b/src/Task.h index c2cb4a8..95cd9b1 100644 --- a/src/Task.h +++ b/src/Task.h @@ -78,7 +78,7 @@ class Task protected: virtual bool OnStart() { return true; }; virtual void OnStop() {}; - virtual void OnUpdate(uint32_t deltaTime) = 0; + virtual void OnUpdate(uint32_t deltaTime) {}; uint32_t _remainingTime; uint32_t _timeInterval; diff --git a/src/TaskManager.cpp b/src/TaskManager.cpp index 1360813..e7ad155 100644 --- a/src/TaskManager.cpp +++ b/src/TaskManager.cpp @@ -34,7 +34,13 @@ TaskManager::TaskManager() : _pFirstTask( NULL ), _pLastTask( NULL ) { -#if defined(ARDUINO_ARCH_ESP8266) || defined(ARDUINO_ARCH_AVR) && !defined(__arm__) + +#if defined(ARDUINO_ARCH_AVR) && !defined(__arm__) + // make sure the watch dog is disabled during setup + // avoid this for Esp8266 due to it will only disable the software watchdog + // but leave the hardware one to fire, further this would disable all the + // built in hidden watchdog feed calls that would keep it from firing and + // thus causing an effect of enabling the watchdog rather than disabling wdt_reset(); wdt_disable(); #endif