Tsunami
borispavlov
—
2015-10-10T00:27:10Z —
#1
What is the accuracy and resolution of measuring 3kHz freq?
If i apply 3000.000 Hz from calibrated signal generator will be returned from Tsunami ?
Will the accuracy be better than 3 000.00 +/- 0.005Hz or ?
Thanks
blinkenlight
—
2015-10-11T21:56:13Z —
#2
Hell no. As far as I can tell, the current Tsunami resolution at 3000Hz is about 0.3Hz. I'm working on improving that - my fork is at about 0.05 or 0.005 (depending on whether you're coming from higher or lower: it's a hysteresis region) - but if you're looking for actual, true, reliable +/- 0.005Hz resolution, you definitely picked the wrong piece of hardware in my humble opinion...
nickjohnson
—
2015-10-13T06:35:29Z —
#3
The theoretical accuracy of the Tsunami is limited by the TCXO, which is 2.5PPM, and the frequency of the input signal.
Currently the Tsunami measures signals by measuring the time interval between rising edges. A front-end circuit divides the frequency down by 0, 16, 256, 4096 or 65536 beforehand, allowing it to measure higher frequency signals accurately.
With a 3KHz signal, the input will be divided by 16, and so it will measure either 10666 or 10667 cycles, for an additional inaccuracy of 0.006% (62PPM or 1/3Hz).
One planned improvement for the Tsunami is to offer a mode that counts edges in a fixed interval, rather than counting intervals between edges, which should allow for better accuracy with a long sampling interval.
blinkenlight, I'd be very interested to see what you're working on and how you've realised accuracy improvements.
blinkenlight
—
2015-10-13T07:53:33Z —
#4
Sure, I was going to put it up on Github anyway, I was just messing a bit more with some testing and polish - I'll just push it once I get back home today...
borispavlov
—
2015-10-16T04:12:21Z —
#5
thank you for the clarification.
noticed a new revision of the code.
what is the expected resolution and accuracy with the new rev?
also just got the Tsunami board. will test tomorrow with calibrated agilent 33220a signal generator and let you know the
results.
blinkenlight
—
2015-10-18T16:16:51Z —
#6
Expected resolution at 3000Hz should currently be around 0.035Hz, and that's what I observed in practice (seeing values like 2999.9765 / 3000.0117 / 3000.0468). Please note there's an alternative measurement also available now (a filtered version of the instant value) that should exhibit less jitter than the instant value, called "measureAverageFrequency"; it tends to hover at 2999.9765 for me, which given the circumstances sounds like a good match for the theoretical 2999.9613Hz the Tsunami's DDS is expected to generate for a "3000Hz" command based on its 16MHz clock.
EDIT: to get an idea about expected resolution at other frequencies, take a look at the second image attached at https://github.com/arachnidlabs/tsunami-arduino/pull/7
borispavlov
—
2015-10-18T19:22:37Z —
#7
that result is very good. thanks..
borispavlov
—
2015-10-19T17:17:48Z —
#8
I did use calibrated function generator Agilent 33220A and applied 1.5V P-P square wave at 25 degC. Measured the frequency at 1000, 2000, 3000 and 4000 Hz. Took 1 minute worth of measurements for each freq. The percent below is approximately for each measurement for a given freq in 1 minute. Results are below:
at 1000 Hz input, Tsunami measures 1,000.01 (50%) and 999,97 (50%)
at 2000 Hz input, Tsunami measures 2,000.01 (80%) and 1999,97 (20%)
at 3000 Hz input, Tsunami measures 3,000.19 (20%) and 2999,91 (80%)
at 4000 Hz input, Tsunami measures 4,000.01 (90%) and 3999,5 (10%)
It will be accurate enough for what i will be doing.
Thanks
nickjohnson
—
2015-10-20T06:23:52Z —
#9
Thanks for running some tests! I assume this is with the existing code, not with blinkenlight's patches?
borispavlov
—
2015-10-20T08:08:06Z —
#10
Correct. I did run the example from the Tsunami library created on 6 June 2015.
There is an improved accuracy patch that i have not installed yet.
Will try later this week.
Randall_McRee
—
2016-07-01T19:05:20Z —
#11
Is it possible to use this new code to measure frequencies less than 32Hz? I would like to directly measure an 8Hz signal. Regardless, I could use better frequency accuracy.
If there is a patch that can do this can you kindly tell me how to install such a patch? Although, I see that there is some new code it seems that there is not a new release available in the Arduino library manager.
Randy
nickjohnson
—
2016-07-13T16:20:23Z —
#12
So, measuring very low frequencies is affected by the Tsunami's DC-offset-detection; for frequencies close to DC, the amplitude is effectively reduced (as is the accuracy of the DC offset measurement). It's not flat out impossible, but the minimum signal amplitude will increase as you approach DC.
I'll push out a new release with recent patches in the next few days.
CelleGuy
—
2016-10-06T15:49:02Z —
#13
Hi..i am a new user here. As per my knowledge Currently the Tsunami measures signals by measuring the time interval between rising edges. A front-end circuit divides the frequency down by 0, 16, 256, 4096 or 65536 beforehand, allowing it to measure higher frequency signals accurately.With a 3KHz signal, the input will be divided by 16, and so it will measure either 10666 or 10667 cycles, for an additional inaccuracy of
0.006% (62PPM or 1/3Hz).
randykarr
—
2016-11-30T19:13:23Z —
#14
Hi, new user here, I want to learn more detail on how the frequency reading works, I assume it's done in the DDS chip since I do not see a frequency divider on any other chips. Where are the details ? I have been wondering around on git-hub and no luck.
thanks
Randy
randykarr
—
2016-12-03T17:45:19Z —
#15
Doing some more homework I see the article on the Arachnidlabs home page about Silego greenpack SLG46110. So the counter is done in a custom programmable chip. Cool. Now if I could just dig out some details on how this chip is used. I see it has GPIO lines that must control the divide by ratio somehow ?
nickjohnson
—
2016-12-04T21:48:31Z —
#16
You're exactly right - and sorry for the delay responding.
The design files for the Greenpak are in the GitHub repo.
The short version is that it's a series of chained counters and flipflops, with an output mux; two IO lines from the AVR let it select between /1, /16, /256 and /4096, which gives it a counting range limited mostly by the rolloff on the input amplifier.
randykarr
—
2016-12-05T16:43:40Z —
#17
How do you decide which counter divide ratio to use ? Does the code parse the signal to get into the correct divide range ? Can you point me to the code that does this ?
thanks
Randy
nickjohnson
—
2016-12-05T17:19:17Z —
#18
That's right - it counts the edges; if they come too fast, it increases the divider ratio, and if they come too slow, it decreases the divider ratio. You can see the relevant code here.
NealXu
—
2017-11-28T15:50:36Z —
#19
Hi...i am a new user here. As per my knowledge With a 3KHz signal, the input will be divided by 16, and so it will measure either 10666 or 10667 cycles, for an additional inaccuracy.One planned improvement for the Tsunami is to offer a mode that counts edges in a fixed interval, rather than counting intervals between edges, which should allow for better accuracy with a long sampling interval.
pcba china