mirror of
https://github.com/rtic-rs/rtic.git
synced 2024-11-27 14:04:56 +01:00
RTIC: Examples cargo fmt
This commit is contained in:
parent
ec60c1369e
commit
bf7456fdb6
4 changed files with 2 additions and 8 deletions
|
@ -29,12 +29,9 @@ mod app {
|
||||||
(Shared {}, Local {})
|
(Shared {}, Local {})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#[task]
|
#[task]
|
||||||
async fn sender1(_c: sender1::Context, mut sender: Sender<'static, u32, CAPACITY>) {
|
async fn sender1(_c: sender1::Context, mut sender: Sender<'static, u32, CAPACITY>) {
|
||||||
|
|
||||||
hprintln!("Sender 1 sending: 1 {:?}", sender.send(1).await);
|
hprintln!("Sender 1 sending: 1 {:?}", sender.send(1).await);
|
||||||
debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator
|
debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,8 +33,6 @@ mod app {
|
||||||
async fn receiver(_c: receiver::Context, mut receiver: Receiver<'static, u32, CAPACITY>) {
|
async fn receiver(_c: receiver::Context, mut receiver: Receiver<'static, u32, CAPACITY>) {
|
||||||
hprintln!("Receiver got: {:?}", receiver.recv().await);
|
hprintln!("Receiver got: {:?}", receiver.recv().await);
|
||||||
|
|
||||||
debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator
|
debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -44,5 +44,4 @@ mod app {
|
||||||
hprintln!("Sender 1 try sending: 2 {:?}", sender.try_send(2));
|
hprintln!("Sender 1 try sending: 2 {:?}", sender.try_send(2));
|
||||||
debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator
|
debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
// examples/async-delay.rs
|
// examples/async-delay.rs
|
||||||
//
|
//
|
||||||
#![no_main]
|
#![no_main]
|
||||||
#![no_std]
|
#![no_std]
|
||||||
#![feature(type_alias_impl_trait)]
|
#![feature(type_alias_impl_trait)]
|
||||||
|
|
Loading…
Reference in a new issue