Pi Pico - 12Mhz CLOCK_FREQ?

Yes. The rp2040 cores are setup to run at 125Mhz (that’s what the rp2040 sdk uses - even though the chip is rated at 133Mhz - so Klipper currently does the same). The value reported in the above tools is the “software timer frequency” which doesn’t always match the cpu core frequency. So, what you are observing is normal and expected.

In case anyone is curious, the rp2040 has an ARM cortex-M0+ core, which doesn’t have a readily available 32bit cpu core timer (unlike the ARM cortex-M3/M4 and similar cores). So, Klipper uses the rp2040 hardware timer for scheduling tasks. We configure that timer to 12Mhz - which matches the external crystal speed.

-Kevin

3 Likes