Signal Generators

cancel
Showing results for 
Search instead for 
Did you mean: 

5402 output glitches

It seems that when setting the Ni 5402 Sig Gen's frequency from one value to the next using its standard function mode (sinewave, typically 5000Hz, ivi), the output momentarily switches off/on.

This switching appears as a glitch on the output which is enough to cause havoc with my test item. I have used other makes of Signal Generator before and not had this problem.

Is there a way of reducing the output glitches of the Ni 5402 signal generator or is it just a nasty signal generator?

Sweep mode does not give glitches when sweeping but still gives glitches when switching between sweep & standard function modes (as the output momentarily switches off/on).

0 Kudos
Message 1 of 10
(8,314 Views)

When you switch from Frequency List Mode to Standard Function Mode you need to explicitly stop generation by calling niFgen_Abort, then change the output mode, then call niFgen_Initiate - that's why you see the output temporarily stop.

 

However, in order to change the frequency during generation is Standard Function Mode, you don't need to abort, you can just change the frequency by using the corresponding NI-FGEN property. Could you maybe share the code snippet where you do this? Make sure you don't abort, then switch frequency, then initiate again.

 

Marcos 

Marcos Kirsch
Chief Software Engineer
NI Driver Software
0 Kudos
Message 2 of 10
(8,311 Views)

I have tried using a IVI step, which gives a small glitch. I have tried modifying the 'standard function' example in LabView 7.1 by removing the last two icons, abort I think. This does not turn the output off but will give a glitch when changing from one frequency to another. Even 'changing' the frequency from 1Khz to 1khz will provide a glitch. From 1khz to 1khz you can see that the output momentarily does not stay stable.

 

 

 

0 Kudos
Message 3 of 10
(8,307 Views)
What specific IVI function are you calling to change the frequency?
Marcos Kirsch
Chief Software Engineer
NI Driver Software
0 Kudos
Message 4 of 10
(8,303 Views)

I have been using the IVI-C step function within TestStand 4; this gives a glitch.

The LabView Standard functions vi also gives this glitch.

Even the Ni FGen Softpanel, using the standard function gives this glitch. Even when sending the same frequency the glitch occurs. A relay inside the NI Function Generator can be heard clicking each time a frequency is requested and the waveform on the scope wobbles, this I guess is the relay inside the function generator causing the glitch.

Nasty

 

0 Kudos
Message 5 of 10
(8,263 Views)

The NI 5402 function generator does support changing frequency "on the fly" and without glitches.  Therefore, I'd like to understand your scenario a little better to be able to tell what issue you're running into.

 

You mention several software cases.  Let's start with the soft front panel.  In the NI-FGEN soft front panel, if I simply generate a sine wave to the 5402 and turn the frequency dial, I don't hear any relay clicks.  Is that case click-free for you also?  There should only be a relay click when you stop and start the generation.

 

Similarly, if I run the "Fgen Function Generator.vi" example and turn the frequency dial, I don't get relay clicks or glitches.  Does this example work for you glitch-free?

 

Assuming these base cases work for you, we would then need to examine the specific software sequences you're trying to run.  If they're making unnecessary stop or reset calls or configuring other properties besides the frequency, those factors may be causing the relay switch.

 

By the way, what NI-FGEN version are you using?

 

Vince Shouba

Senior Software Engineer

Modular Instruments

National Instruments

0 Kudos
Message 6 of 10
(8,228 Views)

Using NI FGen Softpanel 2.6.1: Each time I press the 'Start Waveform' I get a relay glitch. If I just manually update the frequency dial without pressing the 'Start Waveform' there is no glitch.

If I use the 'FGen Function generator' vi again manually changing the frequency then there is no glitch.

The problem with both these methods is that they have to be run continuously within their application/vi. I simply want to program the 5402 in TestStand to a specific frequency then go of and do some other testing, then come back and change the frequency without a glitch. As the 'FGen Function generator' vi remains running within its vi it never stops therefore stopping TestStands sequence. You can modify the vi so that it stops running leaving the output on, but next time you change/start the vi you get a glitch. 

 

0 Kudos
Message 7 of 10
(8,218 Views)

Hi Steve,

If I understand your situation correctly you simply want to generate a tone then at some later point in your sequence change the frequency of this tone without losing the signal (i.e. glitch). The way you are performing this currently is leave the niFgen session open so that the waveform continues to generate and then you will start a new session in order to access the device to change the frequency. If this is correct the glitches are most likely not a result of a relay switch, though it is still possible depending on exactly what your code is doing. My suggestion is to create three Vis one which is your Initialization VI which will configure your device and start your generation.  The second will be a "configuration vi" which you will pass in the session reference and change the frequency property then pass the session out. The third VI will close the session reference. This way you will not be locked in a step by a while loop and can call the configuration vi as many times as you need to without being forced to reconfigure the device.

JaceD
Signal Sources Product Support Engineer
National Instruments
0 Kudos
Message 8 of 10
(8,203 Views)

The key here is to use your already open session  to change the output frequency. If you are calling niFgen_Initialize() multiple times, what you are doing effectively is closing the session you had open (this stops generation), opening a new session with all the default settings, and then reconfiguring and reinitiating generation.

As my colleague already said, just make sure to keep using the session you had already opened.

 

Marcos 

Marcos Kirsch
Chief Software Engineer
NI Driver Software
0 Kudos
Message 9 of 10
(8,181 Views)

Thanks for that. I have used your method of making one step of niFgen configure. one write & one close; this works without the glitches.

It is a shame that the Ivi steps in TestStand do not have this option, and therefore have glitches.

 

0 Kudos
Message 10 of 10
(8,103 Views)