pub struct LedcTimerDriver<'d, S>where
S: SpeedMode,{ /* private fields */ }Expand description
LED Control timer driver
Implementations§
Source§impl<'d, S> LedcTimerDriver<'d, S>where
S: SpeedMode,
impl<'d, S> LedcTimerDriver<'d, S>where
S: SpeedMode,
pub fn new<T: LedcTimer<SpeedMode = S> + 'd>( _timer: T, config: &TimerConfig, ) -> Result<Self, EspError>
Sourcepub fn pause(&mut self) -> Result<(), EspError>
pub fn pause(&mut self) -> Result<(), EspError>
Pauses the timer. Operation can be resumed with [resume_timer()].
Sourcepub fn resume(&mut self) -> Result<(), EspError>
pub fn resume(&mut self) -> Result<(), EspError>
Resumes the operation of the previously paused timer
Sourcepub fn set_frequency(&mut self, frequency: Hertz) -> Result<(), EspError>
pub fn set_frequency(&mut self, frequency: Hertz) -> Result<(), EspError>
Set the frequency of the timer.