pub struct BoardPwmDriver<'a> { /* private fields */ }Implementations§
Source§impl<'a> BoardPwmDriver<'a>
impl<'a> BoardPwmDriver<'a>
Trait Implementations§
Source§impl<'a> PwmDriver<f64> for BoardPwmDriver<'a>
impl<'a> PwmDriver<f64> for BoardPwmDriver<'a>
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
fn output_protocol(&self, channel: usize) -> Result<PwmOutputProtocol, PwmError>
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_slice: &[f64], ) -> Result<(), PwmError>
fn send_disarmed_commands<B: BoardIo>( &mut self, board: &mut B, output_types: &[MixerOutputType], ) -> Result<(), PwmError>
Auto Trait Implementations§
impl<'a> Freeze for BoardPwmDriver<'a>
impl<'a> RefUnwindSafe for BoardPwmDriver<'a>
impl<'a> Send for BoardPwmDriver<'a>
impl<'a> Sync for BoardPwmDriver<'a>
impl<'a> Unpin for BoardPwmDriver<'a>
impl<'a> UnsafeUnpin for BoardPwmDriver<'a>
impl<'a> !UnwindSafe for BoardPwmDriver<'a>
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.