Add watchdog enable option

This commit is contained in:
Unknown
2019-08-24 21:50:59 -04:00
parent 63bebaa8de
commit 36f4dc0ada
2 changed files with 3 additions and 0 deletions
+1
View File
@@ -206,6 +206,7 @@ void Axis::watchdog_feed() {
// @brief Check the watchdog timer for expiration. Also sets the watchdog error bit if expired.
bool Axis::watchdog_check() {
// reset value = 0 means watchdog disabled.
if(!config_.enable_watchdog) return true;
if (get_watchdog_reset() == 0) return true;
// explicit check here to ensure that we don't underflow back to UINT32_MAX