ssh-stamp-esp32 1.0.4

ESP32 implementation of the ssh-stamp-hal traits and bootable binary for ssh-stamp
Documentation
// SPDX-FileCopyrightText: 2026 Roman Valls Guimera <brainstorm@nopcode.org>
//
// SPDX-License-Identifier: GPL-3.0-or-later

//! Timer implementation for ESP32 family
//!
//! Provides microsecond and millisecond timing using ESP32 hardware timers.

use embassy_time::{Duration, Instant};
use ssh_stamp_hal::TimerHal;

/// ESP32 Timer implementation using Embassy time
pub struct EspTimer;

impl TimerHal for EspTimer {
    fn now_micros(&self) -> u64 {
        Instant::now().as_micros()
    }

    async fn delay(&self, millis: u64) {
        embassy_time::Timer::after(Duration::from_millis(millis)).await;
    }
}