stm32/rtc: remove rtc-debug and asbtract exti wakeup

This commit is contained in:
xoviat
2023-08-28 15:30:29 -05:00
parent 2c80784fe6
commit b315c28d4e
4 changed files with 10 additions and 31 deletions

View File

@ -89,9 +89,6 @@ impl Executor {
self.time_driver.resume_time();
trace!("low power: resume time");
#[cfg(feature = "rtc-debug")]
cortex_m::asm::bkpt();
}
pub(self) fn stop_with_rtc(&mut self, rtc: &'static Rtc) {
@ -102,8 +99,7 @@ impl Executor {
crate::interrupt::typelevel::RTC_WKUP::unpend();
unsafe { crate::interrupt::typelevel::RTC_WKUP::enable() };
EXTI.rtsr(0).modify(|w| w.set_line(22, true));
EXTI.imr(0).modify(|w| w.set_line(22, true));
rtc.enable_wakeup_line();
}
fn configure_pwr(&mut self) {
@ -121,7 +117,6 @@ impl Executor {
}
trace!("low power: enter stop...");
#[cfg(not(feature = "rtc-debug"))]
self.scb.set_sleepdeep();
}
@ -144,9 +139,6 @@ impl Executor {
///
/// This function never returns.
pub fn run(&'static mut self, init: impl FnOnce(Spawner)) -> ! {
#[cfg(feature = "rtc-debug")]
trace!("low power: rtc debug enabled");
init(unsafe { EXECUTOR.as_mut().unwrap() }.inner.spawner());
loop {