diff --git a/src/hal/avr/watchdog.cpp b/src/hal/avr/watchdog.cpp index 86f1b52..7717b58 100644 --- a/src/hal/avr/watchdog.cpp +++ b/src/hal/avr/watchdog.cpp @@ -1,4 +1,5 @@ #include "../watchdog.h" +#include namespace hal { namespace watchdog { @@ -7,8 +8,12 @@ void Enable(uint16_t period) { // @@TODO } +void Disable() { + wdt_disable(); +} + void Reset() { - asm("wdr"); + wdt_reset(); } } // namespace watchdog diff --git a/src/hal/watchdog.h b/src/hal/watchdog.h index c585281..592f6f3 100644 --- a/src/hal/watchdog.h +++ b/src/hal/watchdog.h @@ -8,6 +8,7 @@ namespace watchdog { /// watchdog interface void Enable(uint16_t period); +void Disable(); void Reset(); } // namespace watchdog