05-28-2012 01:13 PM
Hi, i'm developing an oscilloscope and function generator, my function generator can generate signal from 1Hz to 100Khz with Simulate Signal vi, 200000 samples and the other option is set to automatic (20000) now i'm working on the oscilloscope, but when i'm trying to display high signal like 100Khz a sine waveform looks like a tringle waveform. Another problem is the trigger, i can't display well a signal of 1 or 2 Hz it was flickering on the screen. How can i set the trigger to display well a signal from 1Hz to 100Khz? Is it good to use the vi Simulate Signal? Thanks 🙂
05-28-2012 02:05 PM
05-28-2012 02:17 PM
Is all simulated no hardware, i've 200 thousand of sampling rate and the other option of sampling rate is set to automatic in the Simulate Signal vi, is it wrong?
05-28-2012 02:45 PM
05-28-2012 04:08 PM
Yes i know the Nyquist-Shannon sampling theorem : Sample_Rate >= 2 x Frequency of the signal, my max signal is 100 Khz so i've a sampling of 200k, is this wrong?
05-28-2012 04:12 PM
05-28-2012 05:44 PM
And the sampling rate must be strictly greater than twice the highest frequency.
Example: Suppose your signal is a sine wave at exactly 100 kHz and your samplng rate is exactly 200 kHz. Now also suppose that the first sample taken at time t = 0 occurs at the rising zero crossing of the sine wave. So Y[0] = 0.00. The next sample will be taken 5 microseconds later when the signal is at the falling zero crossing. Y[1] = 0.00. So long as neither the signal nor the sampling frequency drifts, Y[i] = 0.00 for all i.
Lynn
05-29-2012 06:11 AM
With 10 times greater (1 Milion) i can see the sine wave at 100 Khz, thanks so much 🙂 But why i cant display well a signal of 1 or 3 Hz? The waveform flickering on the screen and don't display all the waveform but only the first half or so.
05-29-2012 08:30 AM
You will need to show us your code. There are too many possiblities for guessing to be productive. Please post your code along with typical data or instruction on how to produce the effect you are seeing.
Lynn
05-29-2012 10:43 AM
This is the code of the function generator, the false case of the big case is used only to turn off led and things like that. If i generate a signal of 1-3 Hz it flickering on the screen of the oscilloscope and there isn't the complete waveform to display.