06-30-2015 08:19 AM
I have a PXI6602 that I am using to simulate a quadrature encoder signal but the signal needs to be present for longer than the vi is open for.
Can the signal be made to continue after the vi finishes so that I can interogate the unit the signal is going into and then stop the signal with another vi once I'm finished?
David.
Solved! Go to Solution.
06-30-2015 10:34 AM - edited 06-30-2015 10:35 AM
Your outputs should hold wherever they were last set as long as you don't power down the device itself, or the equipment its connected to.
Are you seeing different behavior?
Also, just to dive deeper in to the application, why does the VI need to close? Are you closing the DAQmx task when you close the VI?
Cheers
--------, Unofficial Forum Rules and Guidelines ,--------
'--- >The shortest distance between two nodes is a straight wire> ---'
06-30-2015 10:45 AM
Hi,
the signal is dropping as soon as the vi is complete but I would like the signal to remain output from the 6602 so that in the teststand sequence I can the call a different vi that interrogates the software of the module that is monitoring the encoder output.
Once the interrogation is complete I would then like to stop the signal output.
The vi I am using is attached.
Thanks.
06-30-2015 11:01 AM
What's happening right after the VI exits? The output task should still be running unless stopped or cleared.
Cheers
--------, Unofficial Forum Rules and Guidelines ,--------
'--- >The shortest distance between two nodes is a straight wire> ---'
06-30-2015 11:07 AM
The signal stops.
Until that point there is a very clear stable signal but as soon as the vi completes, it's gone.
06-30-2015 11:21 AM
Sorry, I meant do you have any other VIs that operate after this VI?
I think you answered my question though, you are just running this VI alone, right? If this is the only subVI that's being run then when it stops, the LabVIEW environment stops as well, which means your DAQmx tasks are no longer running. You need to make an application structure that allows for LabVIEW to continue running after this VI is called. Use this subVI in your initialization step and then have a user interface of some sort that continues operation. You can't just run this subVI and expect all of the DAQmx tasks and operations to continue if LabVIEW isn't running.
Cheers
--------, Unofficial Forum Rules and Guidelines ,--------
'--- >The shortest distance between two nodes is a straight wire> ---'
07-10-2015 07:20 AM
Thanks James,
to resolve the issue I have created a sub vi for the unit interrogation and placed it inside the vi creating the signal so that once the signal is present the unit data is retreived then the DAQmx tasked are stopped and cleared.
Regards,
David.