From 1fe04236315133dbda22811e6de8d49383e8f1e1 Mon Sep 17 00:00:00 2001 From: Jesse Braham Date: Tue, 3 Sep 2024 07:13:26 -0700 Subject: [PATCH] Eliminate esp-hal's `async` feature --- esp-hal/Cargo.toml | 29 ++++++------------- esp-hal/src/dma/gdma.rs | 11 ------- esp-hal/src/dma/mod.rs | 7 ----- esp-hal/src/dma/pdma.rs | 6 ---- esp-hal/src/gpio/mod.rs | 3 -- esp-hal/src/i2c.rs | 2 -- esp-hal/src/i2s.rs | 1 - esp-hal/src/lcd_cam/lcd/i8080.rs | 4 +-- esp-hal/src/lcd_cam/mod.rs | 4 --- esp-hal/src/lib.rs | 3 +- esp-hal/src/otg_fs.rs | 1 - esp-hal/src/parl_io.rs | 11 ------- esp-hal/src/rmt.rs | 9 ------ esp-hal/src/rsa/mod.rs | 2 -- esp-hal/src/spi/master.rs | 5 +--- esp-hal/src/timer/systimer.rs | 1 - esp-hal/src/touch.rs | 9 +++--- esp-hal/src/twai/mod.rs | 8 +---- esp-hal/src/uart.rs | 5 ---- esp-hal/src/usb_serial_jtag.rs | 1 - esp-wifi/Cargo.toml | 1 - examples/Cargo.toml | 4 +-- examples/src/bin/embassy_i2c.rs | 2 +- .../embassy_i2c_bmp180_calibration_data.rs | 2 +- examples/src/bin/embassy_i2s_read.rs | 2 +- examples/src/bin/embassy_i2s_sound.rs | 2 +- examples/src/bin/embassy_parl_io_rx.rs | 2 +- examples/src/bin/embassy_parl_io_tx.rs | 2 +- examples/src/bin/embassy_rmt_rx.rs | 2 +- examples/src/bin/embassy_rmt_tx.rs | 2 +- examples/src/bin/embassy_serial.rs | 2 +- examples/src/bin/embassy_spi.rs | 2 +- examples/src/bin/embassy_touch.rs | 2 +- examples/src/bin/embassy_twai.rs | 2 +- examples/src/bin/embassy_usb_serial.rs | 2 +- examples/src/bin/embassy_usb_serial_jtag.rs | 2 +- examples/src/bin/embassy_wait.rs | 2 +- examples/src/bin/wifi_embassy_access_point.rs | 2 +- .../bin/wifi_embassy_access_point_with_sta.rs | 2 +- examples/src/bin/wifi_embassy_bench.rs | 2 +- examples/src/bin/wifi_embassy_ble.rs | 2 +- examples/src/bin/wifi_embassy_dhcp.rs | 2 +- examples/src/bin/wifi_embassy_esp_now.rs | 2 +- .../src/bin/wifi_embassy_esp_now_duplex.rs | 2 +- hil-test/Cargo.toml | 5 ++-- 45 files changed, 42 insertions(+), 134 deletions(-) diff --git a/esp-hal/Cargo.toml b/esp-hal/Cargo.toml index 75c67d47f94..2090fa79a13 100644 --- a/esp-hal/Cargo.toml +++ b/esp-hal/Cargo.toml @@ -24,17 +24,17 @@ defmt = { version = "0.3.8", optional = true } delegate = "0.12.0" digest = { version = "0.10.7", default-features = false, optional = true } document-features = "0.2.10" -embassy-futures = { version = "0.1.1", optional = true } -embassy-sync = { version = "0.6.0", optional = true } +embassy-futures = "0.1.1" +embassy-sync = "0.6.0" embassy-usb-driver = { version = "0.1.0", optional = true } embassy-usb-synopsys-otg = { version = "0.1.0", optional = true } embedded-can = "0.4.1" embedded-hal-02 = { version = "0.2.7", features = ["unproven"], package = "embedded-hal" } embedded-hal = "1.0.0" -embedded-hal-async = { version = "1.0.0", optional = true } +embedded-hal-async = "1.0.0" embedded-hal-nb = "1.0.0" embedded-io = "0.6.1" -embedded-io-async = { version = "0.6.1", optional = true } +embedded-io-async = "0.6.1" enumset = "1.1.5" esp-synopsys-usb-otg = { version = "0.4.2", optional = true, features = ["fs", "esp32sx"] } fugit = "0.3.7" @@ -83,7 +83,7 @@ xtensa = ["dep:xtensa-lx", "critical-section/restore-state-u32"] bluetooth = [] -usb-otg = ["esp-synopsys-usb-otg", "usb-device"] +usb-otg = ["dep:embassy-usb-driver", "dep:embassy-usb-synopsys-otg", "dep:esp-synopsys-usb-otg", "dep:usb-device"] __esp_hal_embassy = [] @@ -124,25 +124,14 @@ esp32s3 = ["dep:esp32s3", "xtensa", "procmacros/has-ulp-core", "xtensa-lx/spin", flip-link = ["esp-riscv-rt/fix-sp"] #! ### Trait Implementation Feature Flags -## Enable support for asynchronous operation, with interfaces provided by -## `embedded-hal-async` and `embedded-io-async`. -## Also enables `embassy-usb` support for ESP32-S2 and ESP32-S3. -async = [ - "embedded-hal-async", - "embedded-io-async", - "embassy-sync", - "embassy-futures", - "embassy-usb-driver", - "embassy-usb-synopsys-otg" -] ## Implement `defmt::Format` on certain types. defmt = [ "dep:defmt", - "embassy-futures?/defmt", - "embassy-sync?/defmt", + "embassy-futures/defmt", + "embassy-sync/defmt", "embedded-hal/defmt-03", "embedded-io/defmt-03", - "embedded-io-async?/defmt-03", + "embedded-io-async/defmt-03", "esp32?/defmt", "esp32c2?/defmt", "esp32c3?/defmt", @@ -173,7 +162,7 @@ opsram-8m = [] opsram-16m = [] # This feature is intended for testing; you probably don't want to enable it: -ci = ["async", "defmt", "bluetooth", "place-spi-driver-in-ram"] +ci = ["defmt", "bluetooth", "place-spi-driver-in-ram"] [lints.clippy] mixed_attributes_style = "allow" diff --git a/esp-hal/src/dma/gdma.rs b/esp-hal/src/dma/gdma.rs index 1c7ed6f6064..bc13f42f419 100644 --- a/esp-hal/src/dma/gdma.rs +++ b/esp-hal/src/dma/gdma.rs @@ -420,23 +420,18 @@ impl RegisterAccess for Channel { #[doc(hidden)] pub struct ChannelTxImpl {} -#[cfg(feature = "async")] use embassy_sync::waitqueue::AtomicWaker; -#[cfg(feature = "async")] #[allow(clippy::declare_interior_mutable_const)] const INIT: AtomicWaker = AtomicWaker::new(); -#[cfg(feature = "async")] static TX_WAKERS: [AtomicWaker; CHANNEL_COUNT] = [INIT; CHANNEL_COUNT]; -#[cfg(feature = "async")] static RX_WAKERS: [AtomicWaker; CHANNEL_COUNT] = [INIT; CHANNEL_COUNT]; impl crate::private::Sealed for ChannelTxImpl {} impl TxChannel> for ChannelTxImpl { - #[cfg(feature = "async")] fn waker() -> &'static AtomicWaker { &TX_WAKERS[N as usize] } @@ -449,7 +444,6 @@ pub struct ChannelRxImpl {} impl crate::private::Sealed for ChannelRxImpl {} impl RxChannel> for ChannelRxImpl { - #[cfg(feature = "async")] fn waker() -> &'static AtomicWaker { &RX_WAKERS[N as usize] } @@ -551,7 +545,6 @@ macro_rules! impl_channel { /// /// Descriptors should be sized as `(CHUNK_SIZE + 4091) / 4092`. I.e., to /// transfer buffers of size `1..=4092`, you need 1 descriptor. - #[cfg(feature = "async")] pub fn configure_for_async<'a>( self, burst_mode: bool, @@ -578,23 +571,19 @@ macro_rules! impl_channel { cfg_if::cfg_if! { if #[cfg(esp32c2)] { - #[cfg(feature = "async")] const CHANNEL_COUNT: usize = 1; impl_channel!(0, super::asynch::interrupt::interrupt_handler_ch0, DMA_CH0); } else if #[cfg(esp32c3)] { - #[cfg(feature = "async")] const CHANNEL_COUNT: usize = 3; impl_channel!(0, super::asynch::interrupt::interrupt_handler_ch0, DMA_CH0); impl_channel!(1, super::asynch::interrupt::interrupt_handler_ch1, DMA_CH1); impl_channel!(2, super::asynch::interrupt::interrupt_handler_ch2, DMA_CH2); } else if #[cfg(any(esp32c6, esp32h2))] { - #[cfg(feature = "async")] const CHANNEL_COUNT: usize = 3; impl_channel!(0, super::asynch::interrupt::interrupt_handler_ch0, DMA_IN_CH0, DMA_OUT_CH0); impl_channel!(1, super::asynch::interrupt::interrupt_handler_ch1, DMA_IN_CH1, DMA_OUT_CH1); impl_channel!(2, super::asynch::interrupt::interrupt_handler_ch2, DMA_IN_CH2, DMA_OUT_CH2); } else if #[cfg(esp32s3)] { - #[cfg(feature = "async")] const CHANNEL_COUNT: usize = 5; impl_channel!(0, super::asynch::interrupt::interrupt_handler_ch0, DMA_IN_CH0, DMA_OUT_CH0); impl_channel!(1, super::asynch::interrupt::interrupt_handler_ch1, DMA_IN_CH1, DMA_OUT_CH1); diff --git a/esp-hal/src/dma/mod.rs b/esp-hal/src/dma/mod.rs index 059bd98b1a1..7cfe3df7bf8 100644 --- a/esp-hal/src/dma/mod.rs +++ b/esp-hal/src/dma/mod.rs @@ -1249,7 +1249,6 @@ pub trait RxPrivate: crate::private::Sealed { fn clear_interrupts(&self); - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker; } @@ -1296,7 +1295,6 @@ where R::is_in_done() } - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker; } @@ -1494,7 +1492,6 @@ where CH::Channel::clear_in_interrupts(); } - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker { CH::Rx::waker() } @@ -1552,7 +1549,6 @@ pub trait TxPrivate: crate::private::Sealed { fn clear_interrupts(&self); - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker; fn descriptors_handled(&self) -> bool; @@ -1633,7 +1629,6 @@ where R::last_out_dscr_address() } - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker; } @@ -1759,7 +1754,6 @@ where CH::Channel::has_out_descriptor_error() } - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker { CH::Tx::waker() } @@ -2762,7 +2756,6 @@ where } } -#[cfg(feature = "async")] pub(crate) mod asynch { use core::task::Poll; diff --git a/esp-hal/src/dma/pdma.rs b/esp-hal/src/dma/pdma.rs index e4f702bbabd..051ab529d7f 100644 --- a/esp-hal/src/dma/pdma.rs +++ b/esp-hal/src/dma/pdma.rs @@ -356,7 +356,6 @@ macro_rules! ImplSpiChannel { impl $crate::private::Sealed for [] {} impl<'a> TxChannel<[]> for [] { - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker { static WAKER: embassy_sync::waitqueue::AtomicWaker = embassy_sync::waitqueue::AtomicWaker::new(); &WAKER @@ -370,7 +369,6 @@ macro_rules! ImplSpiChannel { impl $crate::private::Sealed for [] {} impl<'a> RxChannel<[]> for [] { - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker { static WAKER: embassy_sync::waitqueue::AtomicWaker = embassy_sync::waitqueue::AtomicWaker::new(); &WAKER @@ -408,7 +406,6 @@ macro_rules! ImplSpiChannel { /// /// Descriptors should be sized as `(CHUNK_SIZE + 4091) / 4092`. I.e., to /// transfer buffers of size `1..=4092`, you need 1 descriptor. - #[cfg(feature = "async")] pub fn configure_for_async<'a>( self, burst_mode: bool, @@ -752,7 +749,6 @@ macro_rules! ImplI2sChannel { impl $crate::private::Sealed for [] {} impl<'a> TxChannel<[]> for [] { - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker { static WAKER: embassy_sync::waitqueue::AtomicWaker = embassy_sync::waitqueue::AtomicWaker::new(); &WAKER @@ -765,7 +761,6 @@ macro_rules! ImplI2sChannel { impl $crate::private::Sealed for [] {} impl<'a> RxChannel<[]> for [] { - #[cfg(feature = "async")] fn waker() -> &'static embassy_sync::waitqueue::AtomicWaker { static WAKER: embassy_sync::waitqueue::AtomicWaker = embassy_sync::waitqueue::AtomicWaker::new(); &WAKER @@ -802,7 +797,6 @@ macro_rules! ImplI2sChannel { /// /// Descriptors should be sized as `(CHUNK_SIZE + 4091) / 4092`. I.e., to /// transfer buffers of size `1..=4092`, you need 1 descriptor. - #[cfg(feature = "async")] pub fn configure_for_async<'a>( self, burst_mode: bool, diff --git a/esp-hal/src/gpio/mod.rs b/esp-hal/src/gpio/mod.rs index d6a2b49945e..fef1fe145f6 100644 --- a/esp-hal/src/gpio/mod.rs +++ b/esp-hal/src/gpio/mod.rs @@ -1328,7 +1328,6 @@ extern "C" fn gpio_interrupt_handler() { user_handler.call(); } - #[cfg(feature = "async")] asynch::handle_gpio_interrupt(); } @@ -2786,7 +2785,6 @@ pub(crate) mod internal { } } -#[cfg(feature = "async")] mod asynch { use core::task::{Context, Poll}; @@ -3497,7 +3495,6 @@ mod embedded_hal_impls { } } -#[cfg(feature = "async")] mod embedded_hal_async_impls { use embedded_hal_async::digital::Wait; diff --git a/esp-hal/src/i2c.rs b/esp-hal/src/i2c.rs index 94fc99c6e0c..774f855c560 100644 --- a/esp-hal/src/i2c.rs +++ b/esp-hal/src/i2c.rs @@ -410,7 +410,6 @@ where } } -#[cfg(feature = "async")] impl<'d, T> I2C<'d, T, crate::Async> where T: Instance, @@ -457,7 +456,6 @@ where } } -#[cfg(feature = "async")] mod asynch { #[cfg(not(esp32))] use core::{ diff --git a/esp-hal/src/i2s.rs b/esp-hal/src/i2s.rs index ac390c9fde0..70598c88600 100644 --- a/esp-hal/src/i2s.rs +++ b/esp-hal/src/i2s.rs @@ -2181,7 +2181,6 @@ mod private { } /// Async functionality -#[cfg(feature = "async")] pub mod asynch { use super::{Error, I2sRx, I2sTx, RegisterAccess}; use crate::{ diff --git a/esp-hal/src/lcd_cam/lcd/i8080.rs b/esp-hal/src/lcd_cam/lcd/i8080.rs index 27af36a8578..f3770d93853 100644 --- a/esp-hal/src/lcd_cam/lcd/i8080.rs +++ b/esp-hal/src/lcd_cam/lcd/i8080.rs @@ -62,8 +62,6 @@ use core::{fmt::Formatter, marker::PhantomData, mem::size_of}; use fugit::HertzU32; -#[cfg(feature = "async")] -use crate::lcd_cam::asynch::LcdDoneFuture; use crate::{ clock::Clocks, dma::{ @@ -81,6 +79,7 @@ use crate::{ }, gpio::{OutputPin, OutputSignal}, lcd_cam::{ + asynch::LcdDoneFuture, lcd::{i8080::private::TxPins, ClockMode, DelayMode, Phase, Polarity}, private::calculate_clkm, BitOrder, @@ -378,7 +377,6 @@ where } } -#[cfg(feature = "async")] impl<'d, CH: DmaChannel, P: TxPins> I8080<'d, CH, P, crate::Async> where P::Word: Into, diff --git a/esp-hal/src/lcd_cam/mod.rs b/esp-hal/src/lcd_cam/mod.rs index 5bc898c8e9e..f14f021b3e0 100644 --- a/esp-hal/src/lcd_cam/mod.rs +++ b/esp-hal/src/lcd_cam/mod.rs @@ -63,7 +63,6 @@ impl<'d> InterruptConfigurable for LcdCam<'d, crate::Blocking> { } } -#[cfg(feature = "async")] impl<'d> LcdCam<'d, crate::Async> { /// Creates a new `LcdCam` instance for asynchronous operation. pub fn new_async(lcd_cam: impl Peripheral

+ 'd) -> Self { @@ -118,7 +117,6 @@ pub enum ByteOrder { } #[doc(hidden)] -#[cfg(feature = "async")] pub mod asynch { use core::task::Poll; @@ -173,13 +171,11 @@ pub mod asynch { } mod private { - #[cfg(feature = "async")] pub(crate) struct Instance; // NOTE: the LCD_CAM interrupt registers are shared between LCD and Camera and // this is only implemented for the LCD side, when the Camera is implemented a // CriticalSection will be needed to protect these shared registers. - #[cfg(feature = "async")] impl Instance { pub(crate) fn listen_lcd_done() { let lcd_cam = unsafe { crate::peripherals::LCD_CAM::steal() }; diff --git a/esp-hal/src/lib.rs b/esp-hal/src/lib.rs index 1d73ba8dc13..44886ba9766 100644 --- a/esp-hal/src/lib.rs +++ b/esp-hal/src/lib.rs @@ -130,8 +130,7 @@ //! ## Feature Flags #![doc = document_features::document_features!(feature_label = r#"{feature}"#)] #![doc(html_logo_url = "https://avatars.githubusercontent.com/u/46717278")] -#![allow(asm_sub_register)] -#![cfg_attr(feature = "async", allow(stable_features, async_fn_in_trait))] +#![allow(asm_sub_register, async_fn_in_trait, stable_features)] #![cfg_attr(xtensa, feature(asm_experimental_arch))] #![deny(missing_docs, rust_2018_idioms)] #![no_std] diff --git a/esp-hal/src/otg_fs.rs b/esp-hal/src/otg_fs.rs index 802de2a37f7..22a4c9b0fe5 100644 --- a/esp-hal/src/otg_fs.rs +++ b/esp-hal/src/otg_fs.rs @@ -132,7 +132,6 @@ unsafe impl<'d> UsbPeripheral for Usb<'d> { } } /// Async functionality -#[cfg(feature = "async")] pub mod asynch { use embassy_usb_driver::{ EndpointAddress, diff --git a/esp-hal/src/parl_io.rs b/esp-hal/src/parl_io.rs index b1d89623e07..9cd74eb562a 100644 --- a/esp-hal/src/parl_io.rs +++ b/esp-hal/src/parl_io.rs @@ -1660,7 +1660,6 @@ where } #[doc(hidden)] -#[cfg(feature = "async")] pub mod asynch { use core::task::Poll; @@ -2045,7 +2044,6 @@ mod private { reg_block.rx_cfg0().read().rx_eof_gen_sel().bit_is_set() } - #[cfg(feature = "async")] pub fn listen_tx_done() { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; @@ -2053,7 +2051,6 @@ mod private { reg_block.int_ena().modify(|_, w| w.tx_eof().set_bit()); } - #[cfg(feature = "async")] pub fn unlisten_tx_done() { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; @@ -2061,7 +2058,6 @@ mod private { reg_block.int_ena().modify(|_, w| w.tx_eof().clear_bit()); } - #[cfg(feature = "async")] pub fn is_listening_tx_done() -> bool { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; @@ -2069,7 +2065,6 @@ mod private { reg_block.int_ena().read().tx_eof().bit() } - #[cfg(feature = "async")] pub fn is_tx_done_set() -> bool { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; @@ -2077,7 +2072,6 @@ mod private { reg_block.int_raw().read().tx_eof().bit() } - #[cfg(feature = "async")] pub fn clear_is_tx_done() { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; @@ -2312,7 +2306,6 @@ mod private { .bit_is_set() } - #[cfg(feature = "async")] pub fn listen_tx_done() { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; @@ -2320,7 +2313,6 @@ mod private { reg_block.int_ena().modify(|_, w| w.tx_eof().set_bit()); } - #[cfg(feature = "async")] pub fn unlisten_tx_done() { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; @@ -2328,7 +2320,6 @@ mod private { reg_block.int_ena().modify(|_, w| w.tx_eof().clear_bit()); } - #[cfg(feature = "async")] pub fn is_listening_tx_done() -> bool { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; @@ -2336,7 +2327,6 @@ mod private { reg_block.int_ena().read().tx_eof().bit() } - #[cfg(feature = "async")] pub fn is_tx_done_set() -> bool { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; @@ -2344,7 +2334,6 @@ mod private { reg_block.int_raw().read().tx_eof().bit() } - #[cfg(feature = "async")] pub fn clear_is_tx_done() { let reg_block: crate::peripherals::PARL_IO = unsafe { crate::peripherals::PARL_IO::steal() }; diff --git a/esp-hal/src/rmt.rs b/esp-hal/src/rmt.rs index a2efc8eb87a..a858b3d02c5 100644 --- a/esp-hal/src/rmt.rs +++ b/esp-hal/src/rmt.rs @@ -208,7 +208,6 @@ pub struct RxChannelConfig { pub use impl_for_chip::{ChannelCreator, Rmt}; -#[cfg(feature = "async")] use self::asynch::{RxChannelAsync, TxChannelAsync}; impl<'d, M> Rmt<'d, M> @@ -288,7 +287,6 @@ impl<'d> InterruptConfigurable for Rmt<'d, crate::Blocking> { } } -#[cfg(feature = "async")] impl<'d> Rmt<'d, crate::Async> { /// Create a new RMT instance pub fn new_async( @@ -334,7 +332,6 @@ where } /// Creates a TX channel in async mode -#[cfg(feature = "async")] pub trait TxChannelCreatorAsync<'d, T, P> where P: OutputPin, @@ -412,7 +409,6 @@ where } /// Creates a RX channel in async mode -#[cfg(feature = "async")] pub trait RxChannelCreatorAsync<'d, T, P> where P: InputPin, @@ -601,7 +597,6 @@ macro_rules! impl_tx_channel_creator { impl $crate::rmt::TxChannel for $crate::rmt::Channel<$crate::Blocking, $channel> {} - #[cfg(feature = "async")] impl<'d, P> $crate::rmt::TxChannelCreatorAsync<'d, $crate::rmt::Channel<$crate::Async, $channel>, P> for ChannelCreator<$crate::Async, $channel> where @@ -609,7 +604,6 @@ macro_rules! impl_tx_channel_creator { { } - #[cfg(feature = "async")] impl $crate::rmt::asynch::TxChannelAsync for $crate::rmt::Channel<$crate::Async, $channel> {} }; } @@ -625,7 +619,6 @@ macro_rules! impl_rx_channel_creator { impl $crate::rmt::RxChannel for $crate::rmt::Channel<$crate::Blocking, $channel> {} - #[cfg(feature = "async")] impl<'d, P> $crate::rmt::RxChannelCreatorAsync<'d, $crate::rmt::Channel<$crate::Async, $channel>, P> for ChannelCreator<$crate::Async, $channel> where @@ -633,7 +626,6 @@ macro_rules! impl_rx_channel_creator { { } - #[cfg(feature = "async")] impl $crate::rmt::asynch::RxChannelAsync for $crate::rmt::Channel<$crate::Async, $channel> {} }; } @@ -1132,7 +1124,6 @@ pub trait RxChannel: private::RxChannelInternal { } /// Async functionality -#[cfg(feature = "async")] pub mod asynch { use core::{ pin::Pin, diff --git a/esp-hal/src/rsa/mod.rs b/esp-hal/src/rsa/mod.rs index 8bf11d0eafa..fdae81078d2 100644 --- a/esp-hal/src/rsa/mod.rs +++ b/esp-hal/src/rsa/mod.rs @@ -64,7 +64,6 @@ impl<'d> InterruptConfigurable for Rsa<'d, crate::Blocking> { } } -#[cfg(feature = "async")] impl<'d> Rsa<'d, crate::Async> { /// Create a new instance in [crate::Blocking] mode. pub fn new_async(rsa: impl Peripheral

+ 'd) -> Self { @@ -365,7 +364,6 @@ where } /// Async functionality -#[cfg(feature = "async")] pub(crate) mod asynch { use core::task::Poll; diff --git a/esp-hal/src/spi/master.rs b/esp-hal/src/spi/master.rs index 95b0bd32a48..c6a986928a9 100644 --- a/esp-hal/src/spi/master.rs +++ b/esp-hal/src/spi/master.rs @@ -944,12 +944,11 @@ mod dma { }; use super::*; - #[cfg(feature = "async")] - use crate::dma::asynch::{DmaRxFuture, DmaTxFuture}; #[cfg(spi3)] use crate::dma::Spi3Peripheral; use crate::{ dma::{ + asynch::{DmaRxFuture, DmaTxFuture}, Channel, DmaChannel, DmaRxBuf, @@ -1233,7 +1232,6 @@ mod dma { } } - #[cfg(feature = "async")] impl<'d, T, C, D, Buf> SpiDmaTransfer<'d, T, C, D, crate::Async, Buf> where T: Instance, @@ -1926,7 +1924,6 @@ mod dma { } /// Async functionality - #[cfg(feature = "async")] mod asynch { use core::{cmp::min, mem::take}; diff --git a/esp-hal/src/timer/systimer.rs b/esp-hal/src/timer/systimer.rs index 086d2c215ed..9f06162c626 100644 --- a/esp-hal/src/timer/systimer.rs +++ b/esp-hal/src/timer/systimer.rs @@ -1013,7 +1013,6 @@ static CONF_LOCK: LockState = LockState::new(); static INT_ENA_LOCK: LockState = LockState::new(); // Async functionality of the system timer. -#[cfg(feature = "async")] mod asynch { use core::{ pin::Pin, diff --git a/esp-hal/src/touch.rs b/esp-hal/src/touch.rs index a6e59684e15..e81034c5e04 100644 --- a/esp-hal/src/touch.rs +++ b/esp-hal/src/touch.rs @@ -34,11 +34,12 @@ use crate::{ peripheral::{Peripheral, PeripheralRef}, peripherals::{RTC_CNTL, SENS, TOUCH}, private::{Internal, Sealed}, + rtc_cntl::Rtc, + Async, Blocking, + InterruptConfigurable, Mode, }; -#[cfg(feature = "async")] -use crate::{rtc_cntl::Rtc, Async, InterruptConfigurable}; /// A marker trait describing the mode the touch pad is set to. pub trait TouchMode: Sealed {} @@ -271,7 +272,6 @@ impl<'d> Touch<'d, Continous, Blocking> { } } } -#[cfg(feature = "async")] impl<'d> Touch<'d, Continous, Async> { /// Initializes the touch peripheral in continous async mode and returns /// this marker struct. @@ -294,6 +294,7 @@ impl<'d> Touch<'d, Continous, Async> { /// /// ```rust, no_run #[doc = crate::before_snippet!()] + /// # use esp_hal::rtc_cntl::Rtc; /// # use esp_hal::touch::{Touch, TouchConfig}; /// let mut rtc = Rtc::new(peripherals.LPWR); /// let touch = Touch::async_mode(peripherals.TOUCH, &mut rtc, None); @@ -493,7 +494,6 @@ fn internal_disable_interrupt(touch_nr: u8) { } } -#[cfg(feature = "async")] fn internal_disable_interrupts() { let sens = unsafe { &*SENS::ptr() }; sens.sar_touch_enable() @@ -523,7 +523,6 @@ fn internal_is_interrupt_set(touch_nr: u8) -> bool { internal_pins_touched() & (1 << touch_nr) != 0 } -#[cfg(feature = "async")] mod asynch { use core::{ sync::atomic::{AtomicU16, Ordering}, diff --git a/esp-hal/src/twai/mod.rs b/esp-hal/src/twai/mod.rs index 5ccfaa6869f..721a47fd225 100644 --- a/esp-hal/src/twai/mod.rs +++ b/esp-hal/src/twai/mod.rs @@ -943,7 +943,6 @@ where } } -#[cfg(feature = "async")] impl<'d, T> TwaiConfiguration<'d, T, crate::Async> where T: Instance, @@ -1283,7 +1282,7 @@ pub trait Instance: crate::private::Sealed { const OUTPUT_SIGNAL: OutputSignal; /// The interrupt associated with this TWAI instance. const INTERRUPT: crate::peripherals::Interrupt; - #[cfg(feature = "async")] + /// Provides an asynchronous interrupt handler for TWAI instance. fn async_handler() -> InterruptHandler; @@ -1303,7 +1302,6 @@ pub trait Instance: crate::private::Sealed { /// An extension of the `Instance` trait that provides additional operations /// for managing and interacting with the TWAI peripheral. pub trait OperationInstance: Instance { - #[cfg(feature = "async")] /// Returns a reference to the asynchronous state for this TWAI instance. fn async_state() -> &'static asynch::TwaiAsyncState { &asynch::TWAI_STATE[Self::NUMBER] @@ -1480,7 +1478,6 @@ impl Instance for crate::peripherals::TWAI0 { const INTERRUPT: crate::peripherals::Interrupt = crate::peripherals::Interrupt::TWAI0; - #[cfg(feature = "async")] fn async_handler() -> InterruptHandler { asynch::twai0 } @@ -1528,7 +1525,6 @@ impl Instance for crate::peripherals::TWAI0 { const INTERRUPT: crate::peripherals::Interrupt = crate::peripherals::Interrupt::TWAI0; - #[cfg(feature = "async")] fn async_handler() -> InterruptHandler { asynch::twai0 } @@ -1576,7 +1572,6 @@ impl Instance for crate::peripherals::TWAI1 { const INTERRUPT: crate::peripherals::Interrupt = crate::peripherals::Interrupt::TWAI1; - #[cfg(feature = "async")] fn async_handler() -> InterruptHandler { asynch::twai1 } @@ -1614,7 +1609,6 @@ impl Instance for crate::peripherals::TWAI1 { #[cfg(esp32c6)] impl OperationInstance for crate::peripherals::TWAI1 {} -#[cfg(feature = "async")] mod asynch { use core::{future::poll_fn, task::Poll}; diff --git a/esp-hal/src/uart.rs b/esp-hal/src/uart.rs index d741ca5f3e0..f1cb5425138 100644 --- a/esp-hal/src/uart.rs +++ b/esp-hal/src/uart.rs @@ -228,7 +228,6 @@ pub enum Error { InvalidArgument, /// The RX FIFO overflowed. - #[cfg(feature = "async")] RxFifoOvf, /// A glitch was detected on the RX line. @@ -236,14 +235,12 @@ pub enum Error { /// This error occurs when an unexpected or erroneous signal (glitch) is /// detected on the UART RX line, which could lead to incorrect data /// reception. - #[cfg(feature = "async")] RxGlitchDetected, /// A framing error was detected on the RX line. /// /// This error occurs when the received data does not conform to the /// expected UART frame format. - #[cfg(feature = "async")] RxFrameError, /// A parity error was detected on the RX line. @@ -251,7 +248,6 @@ pub enum Error { /// This error occurs when the parity bit in the received data does not /// match the expected parity configuration. /// with the `async` feature. - #[cfg(feature = "async")] RxParityError, } @@ -1928,7 +1924,6 @@ where } } -#[cfg(feature = "async")] mod asynch { use core::task::Poll; diff --git a/esp-hal/src/usb_serial_jtag.rs b/esp-hal/src/usb_serial_jtag.rs index ab752b0655c..b09b50c03c1 100644 --- a/esp-hal/src/usb_serial_jtag.rs +++ b/esp-hal/src/usb_serial_jtag.rs @@ -652,7 +652,6 @@ where } } -#[cfg(feature = "async")] mod asynch { use core::{marker::PhantomData, task::Poll}; diff --git a/esp-wifi/Cargo.toml b/esp-wifi/Cargo.toml index 3f1bb34d5ab..41f9968d07a 100644 --- a/esp-wifi/Cargo.toml +++ b/esp-wifi/Cargo.toml @@ -103,7 +103,6 @@ async = [ "dep:embassy-futures", "dep:embedded-io-async", "dep:esp-hal-embassy", - "esp-hal/async", ] embassy-net = ["dep:embassy-net-driver", "async"] diff --git a/examples/Cargo.toml b/examples/Cargo.toml index 975381be207..b2009458a54 100644 --- a/examples/Cargo.toml +++ b/examples/Cargo.toml @@ -19,7 +19,7 @@ embassy-net = { version = "0.4.0", features = [ "tcp", "udp", "dhcpv4", "medium- embassy-sync = "0.6.0" embassy-time = "0.3.1" embassy-time-driver = { version = "0.1.0", optional = true } -embassy-usb = { version = "0.2.0", default-features = false, optional = true } +embassy-usb = { version = "0.2.0", default-features = false } embedded-can = "0.4.1" embedded-graphics = "0.8.1" embedded-hal = "1.0.0" @@ -69,8 +69,6 @@ esp32s3 = ["esp-hal/esp32s3", "esp-backtrace/esp32s3", "esp-hal-embassy?/esp32s3 esp-wifi = ["dep:esp-wifi"] -async = ["esp-hal/async", "embassy-usb"] - embassy = ["dep:esp-hal-embassy"] embassy-generic-timers = ["embassy-time/generic-queue-8"] diff --git a/examples/src/bin/embassy_i2c.rs b/examples/src/bin/embassy_i2c.rs index 995c99942ad..b95a17b5b57 100644 --- a/examples/src/bin/embassy_i2c.rs +++ b/examples/src/bin/embassy_i2c.rs @@ -11,7 +11,7 @@ //! - SCL => GPIO5 //% CHIPS: esp32 esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_i2c_bmp180_calibration_data.rs b/examples/src/bin/embassy_i2c_bmp180_calibration_data.rs index 2ba39581c2d..10c4279d873 100644 --- a/examples/src/bin/embassy_i2c_bmp180_calibration_data.rs +++ b/examples/src/bin/embassy_i2c_bmp180_calibration_data.rs @@ -12,7 +12,7 @@ //! //% CHIPS: esp32 esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_i2s_read.rs b/examples/src/bin/embassy_i2s_read.rs index 24324c64661..db5e9623dc3 100644 --- a/examples/src/bin/embassy_i2s_read.rs +++ b/examples/src/bin/embassy_i2s_read.rs @@ -12,7 +12,7 @@ //! - DIN => GPIO5 //% CHIPS: esp32 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_i2s_sound.rs b/examples/src/bin/embassy_i2s_sound.rs index 1a5a0a76b02..2781f787090 100644 --- a/examples/src/bin/embassy_i2s_sound.rs +++ b/examples/src/bin/embassy_i2s_sound.rs @@ -26,7 +26,7 @@ //! | XSMT | +3V3 | //% CHIPS: esp32 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_parl_io_rx.rs b/examples/src/bin/embassy_parl_io_rx.rs index dae767bbd47..13bf5c4a69a 100644 --- a/examples/src/bin/embassy_parl_io_rx.rs +++ b/examples/src/bin/embassy_parl_io_rx.rs @@ -5,7 +5,7 @@ //! - Data pins => GPIO1, GPIO2, GPIO3, and GPIO4. //% CHIPS: esp32c6 esp32h2 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_parl_io_tx.rs b/examples/src/bin/embassy_parl_io_tx.rs index 7a90821e50f..5fed54f90c3 100644 --- a/examples/src/bin/embassy_parl_io_tx.rs +++ b/examples/src/bin/embassy_parl_io_tx.rs @@ -9,7 +9,7 @@ //! You can use a logic analyzer to see how the pins are used. //% CHIPS: esp32c6 esp32h2 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_rmt_rx.rs b/examples/src/bin/embassy_rmt_rx.rs index 794aeceedd9..86d299a9e35 100644 --- a/examples/src/bin/embassy_rmt_rx.rs +++ b/examples/src/bin/embassy_rmt_rx.rs @@ -4,7 +4,7 @@ //! - Connect GPIO4 and GPIO5 //% CHIPS: esp32 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_rmt_tx.rs b/examples/src/bin/embassy_rmt_tx.rs index c8cc3c83427..f446527b0ea 100644 --- a/examples/src/bin/embassy_rmt_tx.rs +++ b/examples/src/bin/embassy_rmt_tx.rs @@ -6,7 +6,7 @@ //! - generated pulses => GPIO4 //% CHIPS: esp32 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_serial.rs b/examples/src/bin/embassy_serial.rs index 541ea6c8e89..e2da6b3d377 100644 --- a/examples/src/bin/embassy_serial.rs +++ b/examples/src/bin/embassy_serial.rs @@ -4,7 +4,7 @@ //! writing to and reading from UART. //% CHIPS: esp32 esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_spi.rs b/examples/src/bin/embassy_spi.rs index a8f6ab68720..90500980d8f 100644 --- a/examples/src/bin/embassy_spi.rs +++ b/examples/src/bin/embassy_spi.rs @@ -13,7 +13,7 @@ //! CS => GPIO5 //% CHIPS: esp32 esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_touch.rs b/examples/src/bin/embassy_touch.rs index e0f199442f9..d311aca68bc 100644 --- a/examples/src/bin/embassy_touch.rs +++ b/examples/src/bin/embassy_touch.rs @@ -7,7 +7,7 @@ //! pad on a PCB). //% CHIPS: esp32 -//% FEATURES: async embassy esp-hal-embassy/integrated-timers +//% FEATURES: embassy esp-hal-embassy/integrated-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_twai.rs b/examples/src/bin/embassy_twai.rs index 10ddc4e8df9..8655c936981 100644 --- a/examples/src/bin/embassy_twai.rs +++ b/examples/src/bin/embassy_twai.rs @@ -15,7 +15,7 @@ //! - RX => GPIO2 //% CHIPS: esp32c3 esp32c6 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_usb_serial.rs b/examples/src/bin/embassy_usb_serial.rs index f9acd516163..0c9ecd950bd 100644 --- a/examples/src/bin/embassy_usb_serial.rs +++ b/examples/src/bin/embassy_usb_serial.rs @@ -7,7 +7,7 @@ //! - DM => GPIO19 //% CHIPS: esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_usb_serial_jtag.rs b/examples/src/bin/embassy_usb_serial_jtag.rs index d72089fdfb5..7ca40e7a0dc 100644 --- a/examples/src/bin/embassy_usb_serial_jtag.rs +++ b/examples/src/bin/embassy_usb_serial_jtag.rs @@ -3,7 +3,7 @@ //! Most dev-kits use a USB-UART-bridge - in that case you won't see any output. //% CHIPS: esp32c3 esp32c6 esp32h2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/embassy_wait.rs b/examples/src/bin/embassy_wait.rs index 9b9d5854db7..e2ee6d4552f 100644 --- a/examples/src/bin/embassy_wait.rs +++ b/examples/src/bin/embassy_wait.rs @@ -3,7 +3,7 @@ //! This is an example of asynchronously `Wait`ing for a pin state (boot button) to change. //% CHIPS: esp32 esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3 -//% FEATURES: async embassy embassy-generic-timers +//% FEATURES: embassy embassy-generic-timers #![no_std] #![no_main] diff --git a/examples/src/bin/wifi_embassy_access_point.rs b/examples/src/bin/wifi_embassy_access_point.rs index 22e65a8e5bc..e91754b591e 100644 --- a/examples/src/bin/wifi_embassy_access_point.rs +++ b/examples/src/bin/wifi_embassy_access_point.rs @@ -8,7 +8,7 @@ //! //! Because of the huge task-arena size configured this won't work on ESP32-S2 -//% FEATURES: async embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils +//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils //% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6 #![no_std] diff --git a/examples/src/bin/wifi_embassy_access_point_with_sta.rs b/examples/src/bin/wifi_embassy_access_point_with_sta.rs index 42d2d2e43e9..3907ace1299 100644 --- a/examples/src/bin/wifi_embassy_access_point_with_sta.rs +++ b/examples/src/bin/wifi_embassy_access_point_with_sta.rs @@ -11,7 +11,7 @@ //! //! Because of the huge task-arena size configured this won't work on ESP32-S2 -//% FEATURES: async embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils +//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils //% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6 #![no_std] diff --git a/examples/src/bin/wifi_embassy_bench.rs b/examples/src/bin/wifi_embassy_bench.rs index 5a53e8fd4f9..eb27084a943 100644 --- a/examples/src/bin/wifi_embassy_bench.rs +++ b/examples/src/bin/wifi_embassy_bench.rs @@ -10,7 +10,7 @@ //! Because of the huge task-arena size configured this won't work on ESP32-S2 and ESP32-C2 //! -//% FEATURES: async embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils +//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils //% CHIPS: esp32 esp32s3 esp32c3 esp32c6 #![no_std] diff --git a/examples/src/bin/wifi_embassy_ble.rs b/examples/src/bin/wifi_embassy_ble.rs index 282d6e6a17b..184e0f66641 100644 --- a/examples/src/bin/wifi_embassy_ble.rs +++ b/examples/src/bin/wifi_embassy_ble.rs @@ -4,7 +4,7 @@ //! - offers one service with three characteristics (one is read/write, one is write only, one is read/write/notify) //! - pressing the boot-button on a dev-board will send a notification if it is subscribed -//% FEATURES: async embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/ble +//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/ble //% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6 esp32h2 #![no_std] diff --git a/examples/src/bin/wifi_embassy_dhcp.rs b/examples/src/bin/wifi_embassy_dhcp.rs index 96d17d926fb..cb3108b3e61 100644 --- a/examples/src/bin/wifi_embassy_dhcp.rs +++ b/examples/src/bin/wifi_embassy_dhcp.rs @@ -7,7 +7,7 @@ //! //! Because of the huge task-arena size configured this won't work on ESP32-S2 -//% FEATURES: async embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils +//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils //% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6 #![no_std] diff --git a/examples/src/bin/wifi_embassy_esp_now.rs b/examples/src/bin/wifi_embassy_esp_now.rs index d14d95e0d95..39def6fd7ed 100644 --- a/examples/src/bin/wifi_embassy_esp_now.rs +++ b/examples/src/bin/wifi_embassy_esp_now.rs @@ -4,7 +4,7 @@ //! //! Because of the huge task-arena size configured this won't work on ESP32-S2 -//% FEATURES: async embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now +//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now //% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6 #![no_std] diff --git a/examples/src/bin/wifi_embassy_esp_now_duplex.rs b/examples/src/bin/wifi_embassy_esp_now_duplex.rs index 773389ac155..946caac837a 100644 --- a/examples/src/bin/wifi_embassy_esp_now_duplex.rs +++ b/examples/src/bin/wifi_embassy_esp_now_duplex.rs @@ -4,7 +4,7 @@ //! //! Because of the huge task-arena size configured this won't work on ESP32-S2 -//% FEATURES: async embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now +//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/async esp-wifi/embassy-net esp-wifi/wifi-default esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now //% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6 #![no_std] diff --git a/hil-test/Cargo.toml b/hil-test/Cargo.toml index e12d9db3117..b843e35cfb0 100644 --- a/hil-test/Cargo.toml +++ b/hil-test/Cargo.toml @@ -177,7 +177,7 @@ embassy-sync = "0.6.0" embassy-time = { version = "0.3.1" } embedded-hal = "1.0.0" embedded-hal-02 = { version = "0.2.7", package = "embedded-hal", features = ["unproven"] } -embedded-hal-async = { version = "1.0.0", optional = true } +embedded-hal-async = "1.0.0" embedded-hal-nb = { version = "1.0.0", optional = true } esp-backtrace = { path = "../esp-backtrace", default-features = false, features = ["exception-handler", "panic-handler", "defmt", "semihosting"] } esp-hal = { path = "../esp-hal", features = ["defmt", "digest"], optional = true } @@ -205,7 +205,7 @@ esp-build = { version = "0.1.0", path = "../esp-build" } esp-metadata = { version = "0.3.0", path = "../esp-metadata" } [features] -default = ["async", "embassy"] +default = ["embassy"] defmt = ["dep:defmt-rtt"] @@ -233,7 +233,6 @@ esp32s3 = [ "esp-hal-embassy/esp32s3", ] # Async & Embassy: -async = ["dep:embedded-hal-async", "esp-hal?/async"] embassy = [ "embedded-test/embassy", "embedded-test/external-executor",