timer as future

This commit is contained in:
Per Lindgren 2020-10-26 11:01:47 +01:00
parent d7ca3efd03
commit 0751161648

View file

@ -143,9 +143,10 @@ mod app {
// } // }
// This the actual RTIC task, binds to systic. // This the actual RTIC task, binds to systic.
#[task(binds = SysTick, resources = [], priority = 2)] #[task(binds = SysTick, resources = [syst], priority = 2)]
fn systic(mut cx: systic::Context) { fn systic(mut cx: systic::Context) {
hprintln!("systic interrupt").ok(); hprintln!("systic interrupt").ok();
cx.resources.syst.lock(|syst| syst.disable_interrupt());
crate::app::foo::spawn(); // this should be from a Queue later crate::app::foo::spawn(); // this should be from a Queue later
} }
} }