diff options
| author | Jack Hogan <[email protected]> | 2024-04-15 14:15:53 -0400 |
|---|---|---|
| committer | GitHub <[email protected]> | 2024-04-15 14:15:53 -0400 |
| commit | aeb4daa22fb767b239781a3f9abd85e70c767917 (patch) | |
| tree | 4fa9ab1b443e08ad26bc01ef0fd0b11eb492f016 /examples/stm32f3 | |
| parent | 6ffecb1250bbbdf7f1336479d8f7b7aa1fd00285 (diff) | |
| parent | 3f4e326ec5ec081742e9f30cb7b0bc936e74009c (diff) | |
Merge branch 'embassy-rs:main' into main
Diffstat (limited to 'examples/stm32f3')
| -rw-r--r-- | examples/stm32f3/src/bin/multiprio.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/examples/stm32f3/src/bin/multiprio.rs b/examples/stm32f3/src/bin/multiprio.rs index 328447210..87830b416 100644 --- a/examples/stm32f3/src/bin/multiprio.rs +++ b/examples/stm32f3/src/bin/multiprio.rs | |||
| @@ -127,6 +127,11 @@ fn main() -> ! { | |||
| 127 | 127 | ||
| 128 | let _p = embassy_stm32::init(Default::default()); | 128 | let _p = embassy_stm32::init(Default::default()); |
| 129 | 129 | ||
| 130 | // STM32s don’t have any interrupts exclusively for software use, but they can all be triggered by software as well as | ||
| 131 | // by the peripheral, so we can just use any free interrupt vectors which aren’t used by the rest of your application. | ||
| 132 | // In this case we’re using UART4 and UART5, but there’s nothing special about them. Any otherwise unused interrupt | ||
| 133 | // vector would work exactly the same. | ||
| 134 | |||
| 130 | // High-priority executor: UART4, priority level 6 | 135 | // High-priority executor: UART4, priority level 6 |
| 131 | interrupt::UART4.set_priority(Priority::P6); | 136 | interrupt::UART4.set_priority(Priority::P6); |
| 132 | let spawner = EXECUTOR_HIGH.start(interrupt::UART4); | 137 | let spawner = EXECUTOR_HIGH.start(interrupt::UART4); |
