Skip to content

Commit

Permalink
chore(esp): revert #480
Browse files Browse the repository at this point in the history
  • Loading branch information
elenaf9 committed Oct 24, 2024
1 parent a9beb2f commit f3a9507
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 18 deletions.
2 changes: 1 addition & 1 deletion src/riot-rs-embassy/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ wifi = []
wifi-cyw43 = ["riot-rs-rp/wifi-cyw43", "net", "wifi"]
wifi-esp = ["riot-rs-esp/wifi-esp", "net", "wifi"]

threading = ["dep:riot-rs-threads", "riot-rs-esp/threading"]
threading = ["dep:riot-rs-threads"]
override-network-config = []
override-usb-config = []

Expand Down
3 changes: 0 additions & 3 deletions src/riot-rs-esp/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,6 @@ spi = ["dep:fugit", "riot-rs-embassy-common/spi"]
## Enables defmt support.
defmt = ["dep:defmt", "esp-wifi?/defmt", "fugit?/defmt"]

## Enables threading support.
threading = []

## Enables Wi-Fi support.
wifi = []

Expand Down
14 changes: 0 additions & 14 deletions src/riot-rs-esp/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,20 +68,6 @@ pub use esp_hal_embassy::Executor;
pub fn init() -> OptionalPeripherals {
let mut peripherals = OptionalPeripherals::from(esp_hal::init(esp_hal::Config::default()));

#[cfg(feature = "threading")]
{
use esp_hal::{interrupt, peripherals::Interrupt};
// Since https://github.com/esp-rs/esp-hal/pull/2091,
// `esp_hal::init()` resets all interrupts.
// That also disables our scheduler interrupt, which was previously enabled
// in `riot_rs_threads::arch::xtensa`.
// So, re-enable it here.

// Panics if `FROM_CPU_INTR0` is among `esp_hal::interrupt::RESERVED_INTERRUPTS`,
// which isn't the case.
interrupt::enable(Interrupt::FROM_CPU_INTR0, interrupt::Priority::min()).unwrap();
}

#[cfg(feature = "wifi-esp")]
{
use esp_hal::timer::timg::TimerGroup;
Expand Down

0 comments on commit f3a9507

Please sign in to comment.