diff options
| author | Daniel Carosone <Daniel.Carosone@gmail.com> | 2020-10-07 09:22:38 +1100 |
|---|---|---|
| committer | Daniel Carosone <Daniel.Carosone@gmail.com> | 2020-10-07 09:22:38 +1100 |
| commit | f386cb63cb6d3cd6642debfb4dc1bde97b325550 (patch) | |
| tree | 30b21968997f809dbbba59117db93254607fa22d /examples/preempt.rs | |
| parent | 3d6a0ea64fb2661ee1150a84425f50c18c2de9ad (diff) | |
| parent | b1e1abae29591e50ebf345a2bd249a73e564cea9 (diff) | |
Merge branch 'master'
of https://github.com/rtic-rs/cortex-m-rtic
Diffstat (limited to 'examples/preempt.rs')
| -rw-r--r-- | examples/preempt.rs | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/examples/preempt.rs b/examples/preempt.rs index 3cb1102..f6fc4b0 100644 --- a/examples/preempt.rs +++ b/examples/preempt.rs @@ -9,10 +9,12 @@ use panic_semihosting as _; use rtic::app; #[app(device = lm3s6965)] -const APP: () = { +mod app { #[init] - fn init(_: init::Context) { + fn init(_: init::Context) -> init::LateResources { rtic::pend(Interrupt::GPIOA); + + init::LateResources {} } #[task(binds = GPIOA, priority = 1)] @@ -34,4 +36,4 @@ const APP: () = { rtic::pend(Interrupt::GPIOB); hprintln!(" GPIOC - end").unwrap(); } -}; +} |
