Check MCUCSR for WDRF flag only and add TODO

This commit is contained in:
2024-09-20 23:44:42 +02:00
parent 10298a99c1
commit 208aadf3a3
2 changed files with 3 additions and 3 deletions

View File

@@ -74,8 +74,8 @@ bool WDT_HasTriggered(void)
// 7 6 5 4 3 2 1 0
// JTD ISC2 JTRF WDRF BORF EXTRF PORF
// Is power-on reset flag not set?
isreset = ((MCUCSR & BIT(0)) == 0);
// Is watchdog reset flag set?
isreset = ((MCUCSR & BIT(3)) == 1);
// XXX: Reset flag detection should be a separate
// module to handle the different types.