embassy/embassy-stm32-wpan/src/mac/runner.rs

28 lines
483 B
Rust
Raw Normal View History

2023-07-16 02:15:01 +02:00
use embassy_futures::select::{select3, Either3};
2023-07-16 16:32:54 +02:00
use crate::mac::MTU;
2023-07-16 02:15:01 +02:00
use crate::sub::mac::Mac;
2023-07-18 02:26:58 +02:00
pub struct Runner {
2023-07-16 02:15:01 +02:00
mac: Mac,
2023-07-18 02:26:58 +02:00
// TODO: tx_ring
// TODO: rx_buf
2023-07-16 02:15:01 +02:00
}
2023-07-18 02:26:58 +02:00
impl Runner {
pub(crate) fn new(mac: Mac) -> Self {
Self { mac }
2023-07-16 02:15:01 +02:00
}
pub(crate) async fn init(&mut self, firmware: &[u8]) {
debug!("wifi init done");
}
pub async fn run(mut self) -> ! {
let mut buf = [0; 512];
loop {
2023-07-18 02:26:58 +02:00
// TODO
2023-07-16 02:15:01 +02:00
}
}
}