"I changed the code to use `..." <- > <@u007d:matrix.org> I changed the code to use `modify`, and whatever else I was trashing, it's still incrementing at 1Mhz... > > Take 2: > ```rust > #[pre_init] > unsafe fn pre_init() { > // SAFETY: `#[pre_init] fn` runs before stage 1 bootloader, still in privileged thread mode. > // Any access of memory, including any static variables, will result in undefined behavior. > // (see https://docs.rs/cortex-m-rt/latest/cortex_m_rt/attr.pre_init.html for more details) > let timer_0 = rp_pac::TIMER0; > > // Switch `SOURCE` to `CLK_SYS` (instead of 1 µs tick) > timer_0.source().modify(|source| source.clk_sys()); > > // Lock configuration--`TIMER0` now read-only (until reset) > timer_0.locked().modify(|lock| lock.set_locked(true)); > } > ``` > > Anyone have any thoughts? If you're doing embassy_rp init afterwards, it's resetting it. You have to add support inside embassy_rp to get this to work