Struct esp32c2_hal::pac::ledc::timer_conf::W
pub struct W(_);
Expand description
Register TIMER%s_CONF
writer
Implementations§
§impl W
impl W
pub fn duty_res(
&mut self
) -> FieldWriterRaw<'_, u32, TIMER_CONF_SPEC, u8, u8, Unsafe, 4, 0>
pub fn duty_res(
&mut self
) -> FieldWriterRaw<'_, u32, TIMER_CONF_SPEC, u8, u8, Unsafe, 4, 0>
Bits 0:3 - This register is used to control the range of the counter in timer %s.
pub fn clk_div(
&mut self
) -> FieldWriterRaw<'_, u32, TIMER_CONF_SPEC, u32, u32, Unsafe, 18, 4>
pub fn clk_div(
&mut self
) -> FieldWriterRaw<'_, u32, TIMER_CONF_SPEC, u32, u32, Unsafe, 18, 4>
Bits 4:21 - This register is used to configure the divisor for the divider in timer %s. The least significant eight bits represent the fractional part.
pub fn pause(
&mut self
) -> BitWriterRaw<'_, u32, TIMER_CONF_SPEC, bool, BitM, 22>
pub fn pause(
&mut self
) -> BitWriterRaw<'_, u32, TIMER_CONF_SPEC, bool, BitM, 22>
Bit 22 - This bit is used to suspend the counter in timer %s.
pub fn rst(&mut self) -> BitWriterRaw<'_, u32, TIMER_CONF_SPEC, bool, BitM, 23>
pub fn rst(&mut self) -> BitWriterRaw<'_, u32, TIMER_CONF_SPEC, bool, BitM, 23>
Bit 23 - This bit is used to reset timer %s. The counter will show 0 after reset.
pub fn tick_sel(
&mut self
) -> BitWriterRaw<'_, u32, TIMER_CONF_SPEC, bool, BitM, 24>
pub fn tick_sel(
&mut self
) -> BitWriterRaw<'_, u32, TIMER_CONF_SPEC, bool, BitM, 24>
Bit 24 - This bit is used to select clock for timer %s. When this bit is set to 1 LEDC_APB_CLK_SEL[1:0] should be 1, otherwise the timer clock may be not accurate. 1’h0: SLOW_CLK 1’h1: REF_TICK
pub fn para_up(
&mut self
) -> BitWriterRaw<'_, u32, TIMER_CONF_SPEC, bool, BitM, 25>
pub fn para_up(
&mut self
) -> BitWriterRaw<'_, u32, TIMER_CONF_SPEC, bool, BitM, 25>
Bit 25 - Set this bit to update LEDC_CLK_DIV_TIMER%s and LEDC_TIMER%s_DUTY_RES.
Methods from Deref<Target = W<TIMER_CONF_SPEC>>§
pub unsafe fn bits(&mut self, bits: <REG as RegisterSpec>::Ux) -> &mut W<REG>
pub unsafe fn bits(&mut self, bits: <REG as RegisterSpec>::Ux) -> &mut W<REG>
Writes raw bits to the register.
Safety
Read datasheet or reference manual to find what values are allowed to pass.