Merge pull request #2937 from qiuweishengx/main

In the start_xosc function, the frequency range is set twice.
This commit is contained in:
Ulf Lilleengen 2024-05-13 12:39:36 +00:00 committed by GitHub
commit 3c52ef60b1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -714,10 +714,6 @@ pub fn clk_rtc_freq() -> u16 {
}
fn start_xosc(crystal_hz: u32, delay_multiplier: u32) {
pac::XOSC
.ctrl()
.write(|w| w.set_freq_range(pac::xosc::vals::CtrlFreqRange::_1_15MHZ));
let startup_delay = (((crystal_hz / 1000) * delay_multiplier) + 128) / 256;
pac::XOSC.startup().write(|w| w.set_delay(startup_delay as u16));
pac::XOSC.ctrl().write(|w| {