Skip to content

Commit

Permalink
src: lib: Add get_pwm_method
Browse files Browse the repository at this point in the history
  • Loading branch information
RaulTrombin committed Dec 6, 2023
1 parent c880923 commit 83f4c05
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,10 @@ impl Navigator {
}
}

pub fn get_pwm_enable(&mut self) -> bool {
self.pwm.oe_pin.get_value().expect("Error: Get PWM value") == 1
}

/// Sets the Duty Cycle (high value time) of selected channel.
///
/// On PCA9685, this function sets the `OFF` counter and uses ON value as 0.
Expand Down

0 comments on commit 83f4c05

Please sign in to comment.