aboutsummaryrefslogtreecommitdiff
path: root/src/lib.rs
diff options
context:
space:
mode:
authorGravatar Jorge Aparicio <jorge@japaric.io> 2018-01-11 20:56:45 +0100
committerGravatar Jorge Aparicio <jorge@japaric.io> 2018-01-11 20:56:45 +0100
commit1be43fc489993e63577515063ceb8a83b14423b8 (patch)
tree128911a00f60bb7c0dc9c6ceb8c87e80e3935a99 /src/lib.rs
parentdd12a6a14d2bb028c8da96cb510b67de31d28be4 (diff)
downloadrtic-1be43fc489993e63577515063ceb8a83b14423b8.tar.gz
rtic-1be43fc489993e63577515063ceb8a83b14423b8.tar.zst
rtic-1be43fc489993e63577515063ceb8a83b14423b8.zip
adapt to changes in the cortex-m crate
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib.rs b/src/lib.rs
index 986a7c9a..697dca65 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -87,11 +87,12 @@ extern crate cortex_m_rtfm_macros;
extern crate rtfm_core;
extern crate untagged_option;
-use core::u8;
+use core::{mem, u8};
-pub use rtfm_core::{Resource, Threshold};
pub use cortex_m::asm::{bkpt, wfi};
+pub use cortex_m::peripheral::NVIC;
pub use cortex_m_rtfm_macros::app;
+pub use rtfm_core::{Resource, Threshold};
#[doc(hidden)]
pub use untagged_option::UntaggedOption;
@@ -165,6 +166,6 @@ where
I: Nr,
{
// NOTE(safe) atomic write
- let nvic = unsafe { &*cortex_m::peripheral::NVIC::ptr() };
+ let mut nvic: NVIC = unsafe { mem::transmute(()) };
nvic.set_pending(interrupt);
}