diff options
| author | Dario Nieuwenhuis <[email protected]> | 2025-07-09 01:49:31 +0200 |
|---|---|---|
| committer | diondokter <[email protected]> | 2025-08-29 13:23:21 +0200 |
| commit | 8aec341f28a00012e1771d5c35d2647e11830755 (patch) | |
| tree | 28ec3bad05e5dcb6ec949493688111839bb6865b /examples/rp/src/bin/pwm.rs | |
| parent | 34ff67cdbf25e278ff99bd4a05b6b8c6a30fa5d1 (diff) | |
executor: return error when creating the spawntoken, not when spawning.
Diffstat (limited to 'examples/rp/src/bin/pwm.rs')
| -rw-r--r-- | examples/rp/src/bin/pwm.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/rp/src/bin/pwm.rs b/examples/rp/src/bin/pwm.rs index 04374323d..9dd07ab6e 100644 --- a/examples/rp/src/bin/pwm.rs +++ b/examples/rp/src/bin/pwm.rs | |||
| @@ -18,8 +18,8 @@ use {defmt_rtt as _, panic_probe as _}; | |||
| 18 | #[embassy_executor::main] | 18 | #[embassy_executor::main] |
| 19 | async fn main(spawner: Spawner) { | 19 | async fn main(spawner: Spawner) { |
| 20 | let p = embassy_rp::init(Default::default()); | 20 | let p = embassy_rp::init(Default::default()); |
| 21 | spawner.spawn(pwm_set_config(p.PWM_SLICE4, p.PIN_25)).unwrap(); | 21 | spawner.spawn(pwm_set_config(p.PWM_SLICE4, p.PIN_25).unwrap()); |
| 22 | spawner.spawn(pwm_set_dutycycle(p.PWM_SLICE2, p.PIN_4)).unwrap(); | 22 | spawner.spawn(pwm_set_dutycycle(p.PWM_SLICE2, p.PIN_4).unwrap()); |
| 23 | } | 23 | } |
| 24 | 24 | ||
| 25 | /// Demonstrate PWM by modifying & applying the config | 25 | /// Demonstrate PWM by modifying & applying the config |
