File tree Expand file tree Collapse file tree 2 files changed +15
-2
lines changed Expand file tree Collapse file tree 2 files changed +15
-2
lines changed Original file line number Diff line number Diff line change @@ -300,6 +300,7 @@ where
300300{
301301}
302302
303+ impl private:: Sealed for AnyTimer { }
303304impl IntoAnyTimer for AnyTimer { }
304305
305306impl < T > EspWifiTimerSource for T
@@ -356,7 +357,7 @@ impl private::Sealed for Trng<'_> {}
356357///
357358/// ```rust, no_run
358359#[ doc = esp_hal:: before_snippet!( ) ]
359- /// use esp_hal::{rng::Rng, timg::TimerGroup};
360+ /// use esp_hal::{rng::Rng, timer:: timg::TimerGroup};
360361///
361362/// let timg0 = TimerGroup::new(peripherals.TIMG0);
362363/// let init = esp_wifi::init(
@@ -408,7 +409,7 @@ pub fn init<'d, T: EspWifiTimerSource>(
408409/// # Safety
409410///
410411/// The user must ensure that any use of the radio via the WIFI/BLE/ESP-NOW
411- /// drivers are complete, else undefined behavour may occur within those
412+ /// drivers are complete, else undefined behaviour may occur within those
412413/// drivers.
413414pub unsafe fn deinit_unchecked ( ) -> Result < ( ) , InitializationError > {
414415 // Disable coexistence
Original file line number Diff line number Diff line change @@ -173,3 +173,15 @@ mod tests {
173173 assert_eq ! ( result, 4.0 ) ;
174174 }
175175}
176+
177+ // Here is a random test that doesn't fit anywhere else - and since it's alone,
178+ // creating a new test suite is not necessary as we don't want to flash/run
179+ // anything.
180+ #[ allow( unused) ] // compile test
181+ fn esp_wifi_can_be_initialized_with_any_timer (
182+ timer : esp_hal:: timer:: AnyTimer ,
183+ rng : esp_hal:: rng:: Rng ,
184+ radio_clocks : esp_hal:: peripherals:: RADIO_CLK ,
185+ ) {
186+ esp_wifi:: init ( timer, rng, radio_clocks) ;
187+ }
You can’t perform that action at this time.
0 commit comments