rustfmt
This commit is contained in:
parent
ff5f5021fb
commit
de08da0bf1
1 changed files with 5 additions and 2 deletions
|
@ -15,7 +15,7 @@ use gpio::{AnyPin, Level, Output};
|
|||
use {defmt_rtt as _, panic_probe as _};
|
||||
|
||||
enum LedState {
|
||||
Toggle,
|
||||
Toggle,
|
||||
}
|
||||
static CHANNEL: Channel<ThreadModeRawMutex, LedState, 64> = Channel::new();
|
||||
|
||||
|
@ -28,7 +28,10 @@ async fn main(spawner: Spawner) {
|
|||
let k = 1.003;
|
||||
|
||||
unwrap!(spawner.spawn(toggle_led(CHANNEL.sender(), Duration::from_nanos(dt))));
|
||||
unwrap!(spawner.spawn(toggle_led(CHANNEL.sender(), Duration::from_nanos((dt as f64 * k) as u64))));
|
||||
unwrap!(spawner.spawn(toggle_led(
|
||||
CHANNEL.sender(),
|
||||
Duration::from_nanos((dt as f64 * k) as u64)
|
||||
)));
|
||||
|
||||
loop {
|
||||
match CHANNEL.receive().await {
|
||||
|
|
Loading…
Reference in a new issue