pub struct W(/* private fields */);
Expand description
Register losc_ctrl
writer
Implementations§
source§impl W
impl W
sourcepub fn losc_src_sel(&mut self) -> LOSC_SRC_SEL_W<'_, 0>
pub fn losc_src_sel(&mut self) -> LOSC_SRC_SEL_W<'_, 0>
Bit 0 - LOSC Clock Source Select
sourcepub fn rtc_src_sel(&mut self) -> RTC_SRC_SEL_W<'_, 1>
pub fn rtc_src_sel(&mut self) -> RTC_SRC_SEL_W<'_, 1>
Bit 1 - RTC_TIMER Clock Source Select
sourcepub fn ext_losc_gsm(&mut self) -> EXT_LOSC_GSM_W<'_, 2>
pub fn ext_losc_gsm(&mut self) -> EXT_LOSC_GSM_W<'_, 2>
Bits 2:3 - External 32.768 kHz Crystal GSM
When GSM is changed, the 32K oscillation circuit will arise transient instability. If the autoswitch function (bit 15) is enabled, 32K changes to RC16M with certain probability. The GSM can influence the time of 32K starting oscillation, the more the GSM, the shorter the time of starting oscillation. So modifying GSM is not recommended.
If you need to modify the GSM, firstly disable the auto switch function (bit 15), with a delay of 50 us, then change the GSM, the 32K clock source is changed to external clock.
sourcepub fn ext_losc_en(&mut self) -> EXT_LOSC_EN_W<'_, 4>
pub fn ext_losc_en(&mut self) -> EXT_LOSC_EN_W<'_, 4>
Bit 4 - External 32.768 kHz Crystal Enable
sourcepub fn rtc_day_acce(&mut self) -> RTC_DAY_ACCE_W<'_, 7>
pub fn rtc_day_acce(&mut self) -> RTC_DAY_ACCE_W<'_, 7>
Bit 7 - RTC DAY access
After writing the RTC DAY register, this bit is set and it will be cleared until the real writing operation is finished. After writing the RTC DAY register, the DAY register will be refreshed for at most one second.
Note: Make sure that the bit is 0 for time configuration.
sourcepub fn rtc_hhmmss_acce(&mut self) -> RTC_HHMMSS_ACCE_W<'_, 8>
pub fn rtc_hhmmss_acce(&mut self) -> RTC_HHMMSS_ACCE_W<'_, 8>
Bit 8 - RTC Hour Minute Second access
After writing the RTC HH-MM-SS Register, this bit is set and it will be cleared until the real writing operation is finished. After writing the RTC HH-MM-SS Register, the RTC HH-MM-SS Register will be refreshed for at most one second.
Note: Make sure that the bit is 0 for time configuration.
sourcepub fn losc_auto_swt_32k_sel_en(&mut self) -> LOSC_AUTO_SWT_32K_SEL_EN_W<'_, 14>
pub fn losc_auto_swt_32k_sel_en(&mut self) -> LOSC_AUTO_SWT_32K_SEL_EN_W<'_, 14>
Bit 14 - LOSC auto switch 32K clk source select enable
sourcepub fn losc_auto_swt_function(&mut self) -> LOSC_AUTO_SWT_FUNCTION_W<'_, 15>
pub fn losc_auto_swt_function(&mut self) -> LOSC_AUTO_SWT_FUNCTION_W<'_, 15>
Bit 15 - LOSC auto switch function disable
sourcepub fn key_field(&mut self) -> KEY_FIELD_W<'_, 16>
pub fn key_field(&mut self) -> KEY_FIELD_W<'_, 16>
Bits 16:31 - Key Field
This field should be filled with 0x16AA, and then the bit0 and bit1 can be written with the new value.