Can you move an ARM Core M4 into SLEEP mode through the Serial Wire (DAP)?

182 views Asked by At

I have been working on a project where I move an ARM Core M4 into SLEEP mode through executing a WFI instruction in C firmware. I want to also be able to move the ARM Core M4 into SLEEP mode through the Serial Wire pins.

Are there registers in the M4 that you can write to to move it into SLEEP mode without executing a WFI or WFE instruction?

Or otherwise is there anyway to move to SLEEP mode using the SWD?

1

There are 1 answers

0
doron On

The SystemControlRegister SCR can be programmed such that interrupts sleep on exit. If your application is totally interrupt driven, this may be an option. See: https://developer.arm.com/documentation/dui0552/a/the-cortex-m3-processor/power-management/entering-sleep-mode