Skip to content

Commit

Permalink
Clean up examples
Browse files Browse the repository at this point in the history
  • Loading branch information
bugadani committed Sep 10, 2024
1 parent 4f7bf12 commit 9ebae86
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions examples/src/bin/blinky_erased_pins.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
use esp_backtrace as _;
use esp_hal::{
delay::Delay,
gpio::{AnyPin, Input, Io, Level, Output, Pin, Pull},
gpio::{Input, Io, Level, Output, Pin, Pull},
prelude::*,
};

Expand Down Expand Up @@ -47,7 +47,7 @@ fn main() -> ! {
}
}

fn toggle_pins(leds: &mut [Output<AnyPin>], button: &Input<AnyPin>) {
fn toggle_pins(leds: &mut [Output], button: &Input) {
for pin in leds.iter_mut() {
pin.toggle();
}
Expand Down
4 changes: 2 additions & 2 deletions examples/src/bin/embassy_multicore.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ use esp_backtrace as _;
use esp_hal::{
cpu_control::{CpuControl, Stack},
get_core,
gpio::{AnyPin, Io, Level, Output, Pin},
gpio::{Io, Level, Output, Pin},
timer::{timg::TimerGroup, ErasedTimer},
};
use esp_hal_embassy::Executor;
Expand All @@ -34,7 +34,7 @@ static mut APP_CORE_STACK: Stack<8192> = Stack::new();
/// duration of time.
#[embassy_executor::task]
async fn control_led(
mut led: Output<'static, AnyPin>,
mut led: Output<'static>,
control: &'static Signal<CriticalSectionRawMutex, bool>,
) {
println!("Starting control_led() on core {}", get_core() as usize);
Expand Down
4 changes: 2 additions & 2 deletions examples/src/bin/embassy_multicore_interrupt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ use esp_backtrace as _;
use esp_hal::{
cpu_control::{CpuControl, Stack},
get_core,
gpio::{AnyPin, Io, Level, Output, Pin},
gpio::{ Io, Level, Output, Pin},
interrupt::{software::SoftwareInterruptControl, Priority},
prelude::*,
timer::{timg::TimerGroup, ErasedTimer},
Expand All @@ -35,7 +35,7 @@ static mut APP_CORE_STACK: Stack<8192> = Stack::new();
/// duration of time.
#[embassy_executor::task]
async fn control_led(
mut led: Output<'static, AnyPin>,
mut led: Output<'static>,
control: &'static Signal<CriticalSectionRawMutex, bool>,
) {
println!("Starting control_led() on core {}", get_core() as usize);
Expand Down

0 comments on commit 9ebae86

Please sign in to comment.