pub struct BoardPwmDriver { /* private fields */ }Implementations§
Trait Implementations§
Source§impl PwmDriver<f64> for BoardPwmDriver
impl PwmDriver<f64> for BoardPwmDriver
fn len(&self) -> usize
fn is_enabled(&self) -> bool
fn enable(&mut self, channel: usize) -> Result<(), PwmError>
fn disable(&mut self, channel: usize) -> Result<(), PwmError>
fn enable_all(&mut self) -> Result<(), PwmError>
fn disable_all(&mut self)
Source§fn set_duty_cycle(&mut self, channel: usize, duty: u16) -> Result<(), PwmError>
fn set_duty_cycle(&mut self, channel: usize, duty: u16) -> Result<(), PwmError>
Sets the duty cycle for a specific channel. Read more
Source§fn configure_output_rates(&mut self, rates_hz: &[f64]) -> Result<(), PwmError>
fn configure_output_rates(&mut self, rates_hz: &[f64]) -> Result<(), PwmError>
Configures default output update rates in Hz for mixer-owned channels. Read more
Source§fn flush<B: BoardIo>(&mut self, _board: &mut B)
fn flush<B: BoardIo>(&mut self, _board: &mut B)
Sends the current state of all PWM channels to the output/simulator.
This should be called once per control loop after all individual
set_duty_cycle calls for that loop iteration are complete. Read morefn send_commands<B: BoardIo>( &mut self, board: &mut B, commands: &[f64], ) -> Result<(), PwmError>
fn output_protocol( &self, _channel: usize, ) -> Result<PwmOutputProtocol, PwmError>
fn send_disarmed_commands<B>(
&mut self,
board: &mut B,
output_types: &[MixerOutputType],
) -> Result<(), PwmError>where
B: BoardIo,
Auto Trait Implementations§
impl Freeze for BoardPwmDriver
impl RefUnwindSafe for BoardPwmDriver
impl Send for BoardPwmDriver
impl Sync for BoardPwmDriver
impl Unpin for BoardPwmDriver
impl UnsafeUnpin for BoardPwmDriver
impl !UnwindSafe for BoardPwmDriver
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.