diff options
| author | Dario Nieuwenhuis <[email protected]> | 2024-05-21 21:48:21 +0000 |
|---|---|---|
| committer | GitHub <[email protected]> | 2024-05-21 21:48:21 +0000 |
| commit | 9a4c4fe2c770b6881e0b93ff6d618b1fdf377a66 (patch) | |
| tree | 170749acb73c7ababe3f5aa8a53005490c040dc7 /examples | |
| parent | ba7ef3c91984b1b7bbbc65a3b86162be6304ba98 (diff) | |
| parent | e55f31bdc6882b6a6ac78a59aabf42ff9433f48d (diff) | |
Merge pull request #2781 from ismet55555/pwm-change
Remove Generics from `embassy-rp` `Pwm` struct
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/rp/src/bin/interrupt.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/examples/rp/src/bin/interrupt.rs b/examples/rp/src/bin/interrupt.rs index d334d35d7..5b9d7027e 100644 --- a/examples/rp/src/bin/interrupt.rs +++ b/examples/rp/src/bin/interrupt.rs | |||
| @@ -15,7 +15,6 @@ use embassy_executor::Spawner; | |||
| 15 | use embassy_rp::adc::{self, Adc, Blocking}; | 15 | use embassy_rp::adc::{self, Adc, Blocking}; |
| 16 | use embassy_rp::gpio::Pull; | 16 | use embassy_rp::gpio::Pull; |
| 17 | use embassy_rp::interrupt; | 17 | use embassy_rp::interrupt; |
| 18 | use embassy_rp::peripherals::PWM_SLICE4; | ||
| 19 | use embassy_rp::pwm::{Config, Pwm}; | 18 | use embassy_rp::pwm::{Config, Pwm}; |
| 20 | use embassy_sync::blocking_mutex::raw::CriticalSectionRawMutex; | 19 | use embassy_sync::blocking_mutex::raw::CriticalSectionRawMutex; |
| 21 | use embassy_sync::blocking_mutex::Mutex; | 20 | use embassy_sync::blocking_mutex::Mutex; |
| @@ -26,7 +25,7 @@ use static_cell::StaticCell; | |||
| 26 | use {defmt_rtt as _, panic_probe as _}; | 25 | use {defmt_rtt as _, panic_probe as _}; |
| 27 | 26 | ||
| 28 | static COUNTER: AtomicU32 = AtomicU32::new(0); | 27 | static COUNTER: AtomicU32 = AtomicU32::new(0); |
| 29 | static PWM: Mutex<CriticalSectionRawMutex, RefCell<Option<Pwm<PWM_SLICE4>>>> = Mutex::new(RefCell::new(None)); | 28 | static PWM: Mutex<CriticalSectionRawMutex, RefCell<Option<Pwm>>> = Mutex::new(RefCell::new(None)); |
| 30 | static ADC: Mutex<CriticalSectionRawMutex, RefCell<Option<(Adc<Blocking>, adc::Channel)>>> = | 29 | static ADC: Mutex<CriticalSectionRawMutex, RefCell<Option<(Adc<Blocking>, adc::Channel)>>> = |
| 31 | Mutex::new(RefCell::new(None)); | 30 | Mutex::new(RefCell::new(None)); |
| 32 | static ADC_VALUES: Channel<CriticalSectionRawMutex, u16, 2048> = Channel::new(); | 31 | static ADC_VALUES: Channel<CriticalSectionRawMutex, u16, 2048> = Channel::new(); |
