fix: enable RP2350 watchdog tick generator
This commit is contained in:
parent
169f9c27aa
commit
617f6e7855
@ -524,8 +524,13 @@ pub(crate) unsafe fn init(config: ClockConfig) {
|
|||||||
// Configure tick generator on the 2350
|
// Configure tick generator on the 2350
|
||||||
#[cfg(feature = "_rp235x")]
|
#[cfg(feature = "_rp235x")]
|
||||||
{
|
{
|
||||||
pac::TICKS.timer0_cycles().write(|w| w.0 = clk_ref_freq / 1_000_000);
|
let cycle_count = clk_ref_freq / 1_000_000;
|
||||||
|
|
||||||
|
pac::TICKS.timer0_cycles().write(|w| w.0 = cycle_count);
|
||||||
pac::TICKS.timer0_ctrl().write(|w| w.set_enable(true));
|
pac::TICKS.timer0_ctrl().write(|w| w.set_enable(true));
|
||||||
|
|
||||||
|
pac::TICKS.watchdog_cycles().write(|w| w.0 = cycle_count);
|
||||||
|
pac::TICKS.watchdog_ctrl().write(|w| w.set_enable(true));
|
||||||
}
|
}
|
||||||
|
|
||||||
let (sys_src, sys_aux, clk_sys_freq) = {
|
let (sys_src, sys_aux, clk_sys_freq) = {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user