fix button offset
This commit is contained in:
parent
aaff97aeb1
commit
aea6926a97
1 changed files with 5 additions and 5 deletions
|
|
@ -137,7 +137,7 @@ pub async fn main_loop() {
|
|||
println!("Main loop started");
|
||||
let mut last = (String::new(), String::new());
|
||||
loop {
|
||||
embassy_time::Timer::after_millis(100).await;
|
||||
embassy_time::Timer::after_millis(300).await;
|
||||
let mut state = STATE.lock().await;
|
||||
state.tick();
|
||||
let lines = state.render_lines();
|
||||
|
|
@ -198,7 +198,7 @@ async fn main(spawner: Spawner) -> ! {
|
|||
p.GPIO26.degrade(),
|
||||
GpioInputConfig::default().with_pull(Pull::Up),
|
||||
),
|
||||
1,
|
||||
0,
|
||||
)
|
||||
.expect("spawn btn1"),
|
||||
);
|
||||
|
|
@ -208,7 +208,7 @@ async fn main(spawner: Spawner) -> ! {
|
|||
p.GPIO25.degrade(),
|
||||
GpioInputConfig::default().with_pull(Pull::Up),
|
||||
),
|
||||
2,
|
||||
1,
|
||||
)
|
||||
.expect("spawn btn2"),
|
||||
);
|
||||
|
|
@ -218,7 +218,7 @@ async fn main(spawner: Spawner) -> ! {
|
|||
p.GPIO33.degrade(),
|
||||
GpioInputConfig::default().with_pull(Pull::Up),
|
||||
),
|
||||
3,
|
||||
2,
|
||||
)
|
||||
.expect("spawn btn3"),
|
||||
);
|
||||
|
|
@ -228,7 +228,7 @@ async fn main(spawner: Spawner) -> ! {
|
|||
p.GPIO32.degrade(),
|
||||
GpioInputConfig::default().with_pull(Pull::Up),
|
||||
),
|
||||
4,
|
||||
3,
|
||||
)
|
||||
.expect("spawn btn4"),
|
||||
);
|
||||
|
|
|
|||
Loading…
Reference in a new issue