| 48 | } |
| 49 | |
| 50 | void Watchdog::begin(fl::u32 timeout_ms) FL_NOEXCEPT { |
| 51 | if (timeout_ms == 0) timeout_ms = 1000; |
| 52 | if (timeout_ms > FL_WATCHDOG_MAX_TIMEOUT_MS) timeout_ms = FL_WATCHDOG_MAX_TIMEOUT_MS; |
| 53 | ::Watchdog.enable(static_cast<int>(timeout_ms)); |
| 54 | platforms::samdWatchdogState().armed = true; |
| 55 | } |
| 56 | |
| 57 | void Watchdog::feed() FL_NOEXCEPT { |
| 58 | ::Watchdog.reset(); |
no test coverage detected