I'm having trouble entering stop2 -- instead of going to stop2 my code seems to enter sleep; this is based upon measuring power levels -- I have the RTC fed by an external crystal and a 1 second interval alarm. I can clearly see the transitions from sleep to run and back. I'm just doing the standard thing
If instead I enter standby, the power levels drop to where I expect them (e.g. < 1uA), so I don't thing this power is leaking outside the stm32. So something is either preventing entry to stop2 or just consuming power internal to the stm32. This board is really simple -- just an adxl362 and a crystal. In a different context (external RTC instead of crystal) I've had no problem entering STOP2. I have read about the PWR_CR1_LPR bit, but I don't think that's the problem. Any thoughts on ways to diagnose this ?