Struct esp32c6_hal::mcpwm::operator::PwmUpdateMethod
source · pub struct PwmUpdateMethod(_);
Expand description
Settings for when PwmPin::set_timestamp
takes effect
Multiple syncing triggers can be set.
Implementations§
source§impl PwmUpdateMethod
impl PwmUpdateMethod
sourcepub const SYNC_IMMEDIATLY: PwmUpdateMethod = Self::empty()
pub const SYNC_IMMEDIATLY: PwmUpdateMethod = Self::empty()
New timestamp will be applied immediately
sourcepub const SYNC_ON_ZERO: PwmUpdateMethod = Self::empty().sync_on_timer_equals_zero()
pub const SYNC_ON_ZERO: PwmUpdateMethod = Self::empty().sync_on_timer_equals_zero()
New timestamp will be applied when timer is equal to zero
sourcepub const SYNC_ON_PERIOD: PwmUpdateMethod = Self::empty().sync_on_timer_equals_period()
pub const SYNC_ON_PERIOD: PwmUpdateMethod = Self::empty().sync_on_timer_equals_period()
New timestamp will be applied when timer is equal to period
sourcepub const fn empty() -> PwmUpdateMethod
pub const fn empty() -> PwmUpdateMethod
PwmUpdateMethod
with no sync triggers.
Corresponds to syncing immediately
sourcepub const fn sync_on_timer_equals_zero(self) -> PwmUpdateMethod
pub const fn sync_on_timer_equals_zero(self) -> PwmUpdateMethod
Enable syncing new timestamp values when timer is equal to zero
sourcepub const fn sync_on_timer_equals_period(self) -> PwmUpdateMethod
pub const fn sync_on_timer_equals_period(self) -> PwmUpdateMethod
Enable syncing new timestamp values when timer is equal to period