Closed charlespax closed 7 years ago
Why not attach the PWR button to an EXTI interrupt. If SW_C is moved to EXTI1 could the PWR be EXTI 4? (or vice-versa) External interrupts should be able to wake the processor.
When the unit is put into standby PA0 would be configured as SYS_WKUP because that is the only pin that will wake the device from that state. During normal operation, however, I think it can be configured however you need. SP_PWR should stay on PA0 though I'm not sure if we will actually utilize the standby function.
I posted this issue mainly to ask how the ioc file should be configured, which is your domain. I imagine it should be configured to whatever that pin will be during normal operation, which would be EXTI0.
PA0 is configured as GPIO_EXTI0 in the v0.4 .ioc file
How should PA0 be configured? When putting the processor to sleep it should act to wake up the system. During normal operation it should be an input.