mirror of
https://github.com/rtic-rs/rtic.git
synced 2024-11-24 04:32:52 +01:00
Reexport embedded-time as rtic::time
This commit is contained in:
parent
1c8de78f6f
commit
35b4ec0d04
4 changed files with 5 additions and 5 deletions
|
@ -250,7 +250,7 @@ pub fn codegen(
|
||||||
pub mod #m {
|
pub mod #m {
|
||||||
#(#cfgs)*
|
#(#cfgs)*
|
||||||
pub fn spawn_after(
|
pub fn spawn_after(
|
||||||
duration: rtic::Duration,
|
duration: rtic::time::duration::Duration,
|
||||||
#(,#args)*
|
#(,#args)*
|
||||||
) -> Result<(), #ty> {
|
) -> Result<(), #ty> {
|
||||||
let instant = <#app_path::#m as rtic::Monotonic>::now();
|
let instant = <#app_path::#m as rtic::Monotonic>::now();
|
||||||
|
@ -260,7 +260,7 @@ pub fn codegen(
|
||||||
|
|
||||||
#(#cfgs)*
|
#(#cfgs)*
|
||||||
pub fn spawn_at(
|
pub fn spawn_at(
|
||||||
instant: rtic::Instant<#app_path::#m>
|
instant: rtic::time::Instant<#app_path::#m>
|
||||||
#(,#args)*
|
#(,#args)*
|
||||||
) -> Result<(), #ty> {
|
) -> Result<(), #ty> {
|
||||||
unsafe {
|
unsafe {
|
||||||
|
|
|
@ -69,7 +69,7 @@ pub fn codegen(
|
||||||
#uninit
|
#uninit
|
||||||
/// Buffer that holds the instants associated to the inputs of a task
|
/// Buffer that holds the instants associated to the inputs of a task
|
||||||
static mut #instants:
|
static mut #instants:
|
||||||
[core::mem::MaybeUninit<rtic::Instant<#app_path::#m>>; #cap_lit] =
|
[core::mem::MaybeUninit<rtic::time::Instant<#app_path::#m>>; #cap_lit] =
|
||||||
[#(#elems,)*];
|
[#(#elems,)*];
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,7 +38,7 @@
|
||||||
use cortex_m::{interrupt::Nr, peripheral::NVIC};
|
use cortex_m::{interrupt::Nr, peripheral::NVIC};
|
||||||
pub use cortex_m_rtic_macros::app;
|
pub use cortex_m_rtic_macros::app;
|
||||||
pub use rtic_core::{
|
pub use rtic_core::{
|
||||||
monotonic::{self, Clock, Duration, Instant, Monotonic},
|
monotonic::{self, embedded_time as time, Monotonic},
|
||||||
prelude as mutex_prelude, Exclusive, Mutex,
|
prelude as mutex_prelude, Exclusive, Mutex,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
use crate::{Instant, Monotonic};
|
use crate::{time::Instant, Monotonic};
|
||||||
use core::cmp::Ordering;
|
use core::cmp::Ordering;
|
||||||
use heapless::{binary_heap::Min, ArrayLength, BinaryHeap};
|
use heapless::{binary_heap::Min, ArrayLength, BinaryHeap};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue