06-11-2013 10:33 AM - edited 06-11-2013 10:50 AM
I am trying to find a way to eliminate discontinuities while changing frequency/amplitudes on the fly. Is there a straightforward way to do this?
Basically my end goal is like so:
Table:
Start Freq Stop Freq dt
1 100 10
100 1000 5
1000 5000 10
Where you would start at 1, then switch to 100 after 10 seconds. Then you would go from 100 to 1000 after 5 seconds. And lastly you would go from 1000 to 5000 in 10 seconds.
I am using the niFgen Util Create Frequency Sweep Data VI to create all the necessary frequencies.
I use niFgen property nodes to try to accomplish this. I use a simple for-loop to iterate over an array of frequencies, and I update the frequency like so:
I have everything set up and working, the only issue is that I have big discontinuous jumps whenever the frequency actually gets changed. Unfortunately my oscilloscope is being annoying with the Print Screen feature, so im attempting to recreate it using MS Paint:
Clearly not the best artist ever, but you can get the general idea. I get these V-shaped discontinuities that are especially noticable at the peak of a wave.
Anyone have a good suggestion about how I should go about this? I am setting up generation like so:
Solved! Go to Solution.
06-12-2013 03:15 PM
It looks like you're using the Standard Function mode to do this, correct? The best way to go about this would be to use the Frequency List mode, but the 5412 doesn't have that feature. I've seen documentation that using property nodes with Standard Function can definitely cause these kinds of discontinuities. An alternative method is to use the Arbitrary Sequence mode, take a look at the 'niFgen Arb Sequence Example.vi' in the LabVIEW example finder as a good reference on how to accomplish this.
06-13-2013 12:24 PM
Hi MrHappyAsthma,
NI PXI-5412 is a Arbitrary Signal Generator with Function Generator feature in emulation mode. In Emulation mode, when you change the frequency on-the-fly / dynamically while generating, the waveform will not be phase continuous. Devices such as NI PXI-5402, 5406, 5441, 5442, 5450 or 5451 supports phase continuous frequency hopping feature.
Since you do know the frequencies you need to jump to ahead of time, it is best to do this with Arbitrary sequence mode.