diff --git a/src/main.rs b/src/main.rs index 29efb04..4a2caea 100644 --- a/src/main.rs +++ b/src/main.rs @@ -9,6 +9,7 @@ use esp_hal::{ clock::CpuClock, + gpio::{Output, OutputConfig}, main, time::{Duration, Instant}, }; @@ -54,8 +55,15 @@ fn main() -> ! { esp_alloc::heap_allocator!(#[esp_hal::ram(reclaimed)] size: 98768); + let mut led = Output::new( + peripherals.GPIO21, + esp_hal::gpio::Level::High, + OutputConfig::default(), + ); + loop { log::info!("Hello world!"); + led.toggle(); let delay_start = Instant::now(); while delay_start.elapsed() < Duration::from_millis(500) {} }