manitou
Senior Member+
Did some more testing this morning with that clock generator chip especially between 60-70 Mhz. Looks like I would limit it to 68 or 70Mhz.
Re: FreqCount on T4 with quad timer
I too did some testing with Adafruit clock generator (Si5351A). For my T4B2R, the frequency count is accurate to about 65 mhz as measured against the T4's crystal. @65mhz frequency error is about -22 ppm, but @66mhz error is -73 ppm. @50mhz errors is -20.5 ppm, and @1mhz it is -20 ppm. With GPS PPS, i measured my T4B2R frequency error (24mhz crystal) at -11 ppm, so that suggests the Adafruit generator's crystal has an error of -31 ppm (spec says generator's 25mhz crystal is accurate to within 30 ppm).
I also tested the generator with T3.6 (-6 ppm) FreqCount library, and those tests also showed my Adafruit generator crystal has frequency error of -31 ppm. I also confirmed that T3* can count accurately up to 65 mhz, as documented by Paul in his youtube demo, see
https://forum.pjrc.com/threads/4798...ad-after-12MHz?p=160470&viewfull=1#post160470
Curious that both T4 and T3 frequency counting is good up to 65 mhz. Is there some fundamental IC characteristic that determines counting threshold or capacitance/hysteresis of input or ?? A shorter common ground jumper between the T4 and the T3.2 controlling the generator helps.
Code:
With a 7" ground jumper and 70 mhz PWM
67656628
67655729
67657627
with 2" jumper
69526989
69525509
69535055
As noted in previous posts, a single T4 with its PWM output jumpered to its counter input can count a 75 mhz PWM input.
EDIT: Using GPS PPS, i measured Adafruit generator 25mhz crystal frequency error to be -31.2 ppm.
EDIT 2: the T3* FreqCount uses LPTMR, and the 65 mhz is a limit of the 16-bit timer rollover (intervaltimer checks for rollover every 1000 us, so max external clock rate would be 65mhz) With another sketch, I can count up to 132.5 MHz, see
https://forum.pjrc.com/threads/54711-Teensy-4-0-First-Beta-Test?p=212014&viewfull=1#post212014
Last edited: