Check MCUCSR for WDRF flag only and add TODO
This commit is contained in:
@@ -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.
|
||||
|
||||
Reference in New Issue
Block a user