Skip to content

Commit

Permalink
update for changes in latest esp-hal git (esp-rs#449)
Browse files Browse the repository at this point in the history
  • Loading branch information
liebman authored and bjoernQ committed May 24, 2024
1 parent 2891309 commit 99fc3fd
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 3 deletions.
1 change: 1 addition & 0 deletions esp-wifi/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ esp-hal = { workspace = true }
smoltcp = { workspace = true, optional = true }
critical-section.workspace = true
log = { workspace = true, optional = true }
embedded-hal = { workspace = true }
embedded-svc = { workspace = true, optional = true }
enumset = { workspace = true, optional = true }
linked_list_allocator = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion esp-wifi/src/common_adapter/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ use crate::compat::timer_compat::*;
use crate::hal;

use esp_wifi_sys::include::timespec;
use hal::rng::Rng;
use hal::system::RadioClockControl;
use hal::Rng;

use hal::macros::ram;

Expand Down
2 changes: 1 addition & 1 deletion esp-wifi/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ impl EspWifiInitFor {
pub fn initialize(
init_for: EspWifiInitFor,
timer: EspWifiTimer,
rng: hal::Rng,
rng: hal::rng::Rng,
radio_clocks: hal::system::RadioClockControl,
clocks: &Clocks,
) -> Result<EspWifiInitialization, InitializationError> {
Expand Down
4 changes: 3 additions & 1 deletion esp-wifi/src/preempt/preempt_xtensa.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
use core::ptr::addr_of;

use super::*;

use crate::hal::trapframe::TrapFrame;
Expand Down Expand Up @@ -75,7 +77,7 @@ pub fn task_create(task: extern "C" fn()) {
let task_stack_size = TASK_STACK_SIZE[i];

// stack must be aligned by 16
let task_stack_ptr = (&TASK_STACK as *const _ as usize
let task_stack_ptr = (addr_of!(TASK_STACK) as *const _ as usize
+ (task_stack_size as usize * i as usize)
+ task_stack_size as usize
- 4) as u32;
Expand Down
2 changes: 2 additions & 0 deletions esp-wifi/src/timer/xtensa.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use core::cell::RefCell;

use embedded_hal::timer::CountDown;

use portable_atomic::{AtomicU32, Ordering};

use critical_section::Mutex;
Expand Down

0 comments on commit 99fc3fd

Please sign in to comment.