aboutsummaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorxoviat <[email protected]>2023-04-16 18:32:55 -0500
committerxoviat <[email protected]>2023-04-16 18:32:55 -0500
commit9e1ddeac8604f5df85df56159b97004de890aeb3 (patch)
treef1874f7470af5fe5c51d138331d8839b5a27ece0 /examples
parent776e001b5befc50ff409b5cd8252bbb61fbb5acc (diff)
stm32: fix defective example
Diffstat (limited to 'examples')
-rw-r--r--examples/stm32g4/src/bin/pwm.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/stm32g4/src/bin/pwm.rs b/examples/stm32g4/src/bin/pwm.rs
index 017e89e41..8f7842ed7 100644
--- a/examples/stm32g4/src/bin/pwm.rs
+++ b/examples/stm32g4/src/bin/pwm.rs
@@ -15,8 +15,8 @@ async fn main(_spawner: Spawner) {
15 let p = embassy_stm32::init(Default::default()); 15 let p = embassy_stm32::init(Default::default());
16 info!("Hello World!"); 16 info!("Hello World!");
17 17
18 let ch1 = PwmPin::new_ch1(p.PA5); 18 let ch1 = PwmPin::new_ch1(p.PC0);
19 let mut pwm = SimplePwm::new(p.TIM2, Some(ch1), None, None, None, khz(10)); 19 let mut pwm = SimplePwm::new(p.TIM1, Some(ch1), None, None, None, khz(10));
20 let max = pwm.get_max_duty(); 20 let max = pwm.get_max_duty();
21 pwm.enable(Channel::Ch1); 21 pwm.enable(Channel::Ch1);
22 22