diff options
Diffstat (limited to 'examples/pool.rs')
| -rw-r--r-- | examples/pool.rs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/examples/pool.rs b/examples/pool.rs index 0b594b1..8c44cb1 100644 --- a/examples/pool.rs +++ b/examples/pool.rs @@ -5,14 +5,13 @@ #![no_main] #![no_std] -extern crate panic_semihosting; - use cortex_m_semihosting::{debug, hprintln}; use heapless::{ pool, pool::singleton::{Box, Pool}, }; use lm3s6965::Interrupt; +use panic_semihosting as _; use rtfm::app; // Declare a pool of 128-byte memory blocks @@ -30,8 +29,8 @@ const APP: () = { rtfm::pend(Interrupt::I2C0); } - #[interrupt(priority = 2, spawn = [foo, bar])] - fn I2C0(c: I2C0::Context) { + #[task(binds = I2C0, priority = 2, spawn = [foo, bar])] + fn i2c0(c: i2c0::Context) { // claim a memory block, leave it uninitialized and .. let x = P::alloc().unwrap().freeze(); |
