12-19-2014 04:19 AM
Hello everybody,
I have a problem when I try to to build a signal generator on Labview. I would like to add a switch to turn on and turn off the generator.
I include the code of what I did.
Thank you very much for your help.
12-22-2014 03:54 AM
Hi !
A simple way of doing what you want would be to start from this example from LabVIEW Example Finder:
In LabVIEW, Help>LabVIEW Example Finder>Hardware Input & output>DAQmx>Analog ouput>Voltage (non-regeneration) Continous Output.vi
Then, in the while loop, instead of always sending a signal, you could use a Case Structure bounded to a Boolean Control on the Front Panel, lets name it Generation On?:
-If Generaion On? == True, then in that case, you put your code generating your signal.
-If Generation On? == False, then just send bunches of 0s !.
It will do the trick.
Another way that I would recommand if you have time to play, is to use a Simple State Machine.
Let me know if it fits your need.
Regards
Victor F. | Systems Engineer
Certified LabVIEW Developer | Certified TestStand Architect
National Instruments Budapest