diff options
| author | Dario Nieuwenhuis <[email protected]> | 2021-11-27 03:06:53 +0100 |
|---|---|---|
| committer | Dario Nieuwenhuis <[email protected]> | 2021-11-27 03:06:53 +0100 |
| commit | 006e567716362acfde90afcfd8a25be1fe0d6897 (patch) | |
| tree | 34615657d5507b9d043f86cb48048e22cb69c432 | |
| parent | e40555e245b9a0c351f2cf250231453a0ec78a3d (diff) | |
stm32/pwm: allow using the advanced timer instances too.
| -rw-r--r-- | .vscode/settings.json | 1 | ||||
| -rw-r--r-- | embassy-stm32/src/pwm/mod.rs | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/.vscode/settings.json b/.vscode/settings.json index 0e67ab824..87dd158ec 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json | |||
| @@ -6,6 +6,7 @@ | |||
| 6 | "rust-analyzer.checkOnSave.allTargets": false, | 6 | "rust-analyzer.checkOnSave.allTargets": false, |
| 7 | "rust-analyzer.checkOnSave.command": "clippy", | 7 | "rust-analyzer.checkOnSave.command": "clippy", |
| 8 | "rust-analyzer.cargo.noDefaultFeatures": true, | 8 | "rust-analyzer.cargo.noDefaultFeatures": true, |
| 9 | "rust-analyzer.experimental.procAttrMacros": false, | ||
| 9 | "rust-analyzer.checkOnSave.noDefaultFeatures": true, | 10 | "rust-analyzer.checkOnSave.noDefaultFeatures": true, |
| 10 | "rust-analyzer.cargo.target": "thumbv7em-none-eabi", | 11 | "rust-analyzer.cargo.target": "thumbv7em-none-eabi", |
| 11 | "rust-analyzer.cargo.features": [ | 12 | "rust-analyzer.cargo.features": [ |
diff --git a/embassy-stm32/src/pwm/mod.rs b/embassy-stm32/src/pwm/mod.rs index 7176603e2..8357b6cdc 100644 --- a/embassy-stm32/src/pwm/mod.rs +++ b/embassy-stm32/src/pwm/mod.rs | |||
| @@ -142,7 +142,7 @@ macro_rules! impl_timer { | |||
| 142 | ($inst:ident) => { | 142 | ($inst:ident) => { |
| 143 | impl crate::pwm::sealed::Instance for crate::peripherals::$inst { | 143 | impl crate::pwm::sealed::Instance for crate::peripherals::$inst { |
| 144 | fn regs() -> crate::pac::timer::TimGp16 { | 144 | fn regs() -> crate::pac::timer::TimGp16 { |
| 145 | crate::pac::$inst | 145 | crate::pac::timer::TimGp16(crate::pac::$inst.0) |
| 146 | } | 146 | } |
| 147 | } | 147 | } |
| 148 | 148 | ||
