Software reset, from code

Play with it! Please tell us which board you're using.
For CircuitPython issues, ask in the Adafruit CircuitPython forum.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
daverlee
 
Posts: 19
Joined: Tue Jun 11, 2013 9:31 pm

Software reset, from code

Post by daverlee »

I assume since this is an ARM device, that there's some value I can write to SCB_AIRCR to get this to reset itself from my code, but SCB_AIRCR is unrecognized. Is there any way to reset a circuit playground express from my code?

User avatar
westfw
 
Posts: 2008
Joined: Fri Apr 27, 2007 1:01 pm

Re: Software reset, from code

Post by westfw »

SCB->AIRCR
Maybe (not near an actual compiler at the moment.)
https://github.com/arduino/ArduinoCore- ... lus.h#L301

User avatar
daverlee
 
Posts: 19
Joined: Tue Jun 11, 2013 9:31 pm

Re: Software reset, from code

Post by daverlee »

yup, that's it!

for anyone else who needs it:

SCB->AIRCR = ((0x05FA<<16)|SCB_AIRCR_SYSRESETREQ_Msk);

Locked
Please be positive and constructive with your questions and comments.

Return to “Circuit Playground Classic, Circuit Playground Express, Circuit Playground Bluefruit”