diff options
Diffstat (limited to 'src/Platform.cpp')
-rw-r--r-- | src/Platform.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Platform.cpp b/src/Platform.cpp index 79252b91..7199ff04 100644 --- a/src/Platform.cpp +++ b/src/Platform.cpp @@ -114,6 +114,10 @@ void setup() // When doing a software reset, we disable the NRST input (User reset) to prevent the negative-going pulse that gets generated on it // being held in the capacitor and changing the reset reason form Software to User. So enable it again here. We hope that the reset signal // will have gone away by now. +#ifndef RSTC_MR_KEY_PASSWD +// Definition of RSTC_MR_KEY_PASSWD is missing in the SAM3X ASF files +# define RSTC_MR_KEY_PASSWD (0xA5u << 24) +#endif RSTC->RSTC_MR = RSTC_MR_KEY_PASSWD | RSTC_MR_URSTEN; // ignore any signal on the NRST pin for now so that the reset reason will show as Software // Go on and do the main initialisation |