Skip to content

Commit f04b0ea

Browse files
committed
fix #604
1 parent 2eb0088 commit f04b0ea

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
77

88
## [Unreleased]
99

10+
- Fix #604 pwm output
1011
- bors bot replaced with GH merge queue
1112
- Integrate new version of stm32_i2s (v0.5) to enable full-duplex operation
1213
- Add a rtic example to show how to do full-duplex i2s

src/timer/pwm.rs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,8 @@ impl<TIM, Otype, const C: u8> ChannelBuilder<TIM, C, false, Otype>
6464
where
6565
TIM: CPin<C>,
6666
{
67-
pub fn new(_pin: impl Into<TIM::Ch<Otype>>) -> Self {
67+
pub fn new(pin: impl Into<TIM::Ch<Otype>>) -> Self {
68+
let _pin = pin.into();
6869
Self { _tim: PhantomData }
6970
}
7071
}
@@ -82,8 +83,9 @@ where
8283
{
8384
pub fn with_complementary(
8485
self,
85-
_pin: impl Into<TIM::ChN<Otype>>,
86+
pin: impl Into<TIM::ChN<Otype>>,
8687
) -> ChannelBuilder<TIM, C, true, Otype> {
88+
let _pin = pin.into();
8789
ChannelBuilder { _tim: PhantomData }
8890
}
8991
}
@@ -530,7 +532,7 @@ where
530532

531533
/// Get raw dead time (DTG) bits
532534
#[inline]
533-
pub fn get_dead_time_bit(&self) -> u8 {
535+
pub fn get_dead_time_bits(&self) -> u8 {
534536
TIM::read_dtg_value()
535537
}
536538

0 commit comments

Comments
 (0)