fn configure_usb_correction(oscctrl: &mut OSCCTRL) {
    oscctrl.dfllmul.write(|w| unsafe {
        w.cstep().bits(0x1)
        .fstep().bits(0x1)
        // scaling factor for 1Khz SOF signal.
        .mul().bits((48_000_000u32 / 1000) as u16)
    });
    while oscctrl.dfllsync.read().dfllmul().bit_is_set() {}

    oscctrl.dfllctrlb.write(|w| {
        // closed loop mode
        w.mode().set_bit()
        // chill cycle disable
        .ccdis().set_bit()
        // usb correction
        .usbcrm().set_bit()
    });
    while oscctrl.dfllsync.read().dfllctrlb().bit_is_set() {}
}
/// Configure the dfll48m to calibrate against the 1Khz USB SOF reference.
Configure the dfll48m to calibrate against the 1Khz USB SOF reference.
Configure the dfll48m to calibrate against the 1Khz USB SOF reference .
fn configure_usb_correction(oscctrl: &mut OSCCTRL) {
    oscctrl.dfllmul.write(|w| unsafe {
        w.cstep().bits(0x1)
        .fstep().bits(0x1)
        // scaling factor for 1Khz SOF signal.
        .mul().bits((48_000_000u32 / 1000) as u16)
    });
    while oscctrl.dfllsync.read().dfllmul().bit_is_set() {}
    oscctrl.dfllctrlb.write(|w| {
        // closed loop mode
        w.mode().set_bit()
        // chill cycle disable
        .ccdis().set_bit()
        // usb correction
        .usbcrm().set_bit()
    });
    while oscctrl.dfllsync.read().dfllctrlb().bit_is_set() {}
}
fn configure_usb_correction ( oscctrl : & mut OSCCTRL ) { oscctrl . dfllmul . write ( | w | unsafe { w . cstep ( ) . bits ( 0x1 ) . fstep ( ) . bits ( 0x1 ) // scaling factor for 1Khz SOF signal. . mul ( ) . bits ( ( 48_000_000u32 / 1000 ) as u16 ) } ) ; while oscctrl . dfllsync . read ( ) . dfllmul ( ) . bit_is_set ( ) { } oscctrl . dfllctrlb . write ( | w | { // closed loop mode w . mode ( ) . set_bit ( ) // chill cycle disable . ccdis ( ) . set_bit ( ) // usb correction . usbcrm ( ) . set_bit ( ) } ) ; while oscctrl . dfllsync . read ( ) . dfllctrlb ( ) . bit_is_set ( ) { } }
Configure the dfll48m to calibrate against the 1Khz USB SOF reference.
Configure the dfll48m to calibrate against the 1Khz USB SOF reference .
oscctrl
&mut OSCCTRL
oscctrl
&mut OSCCTRL