maximum tone() frequency? #301
-
I want to see whether I can use a raspberry pi pico as a frequency generator for some ultrasonic experiments I have planned. However, I need to get around the 200 mhz range, so I'm wondering just how high a frequency the tone() function can output. |
Beta Was this translation helpful? Give feedback.
Answered by
earlephilhower
Aug 31, 2021
Replies: 1 comment 2 replies
-
I assume you mean kHZ, not MHz :). The PIO hardware should be able to do up to 125MHZ / 8 = 20MHz (because each loop uses 8 PIO insns). However, the code in arduino-pico/cores/rp2040/Tone.cpp Lines 66 to 68 in a8121f3 |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
stingpie
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I assume you mean kHZ, not MHz :).
The PIO hardware should be able to do up to 125MHZ / 8 = 20MHz (because each loop uses 8 PIO insns).
However, the code in
arduino-pico/cores/rp2040/Tone.cpp
Lines 66 to 68 in a8121f3