03-02-2014 05:49 PM
Hey RavensFan
Thanks for you help. The whole point from using this state machine is to run my code and stop it at certain intervals without using the stop buttons. . Is there any way to do that?
Regards
Rajab
03-02-2014 06:00 PM
Yes. One of the states of your state machine would be a "Check Elapsed Time". It checks whether the specified amount of time has passed. If so, it moves onto the next state, if not, then it puts Check Elapsed Time back into the state machine so that it runs again.
03-03-2014 10:52 AM
Sorry again
The elapsed time in my state machine work independently from the while loop within the case structure. So the elapsed time will not start functioning until the code within the while loop stop. Is that mean I need another elapsed time function to stop the vi within the WHILE LOOP??
Thanks
03-12-2014 07:58 AM
Hi apoke
thanks a lot for your help. Could you please check the attached file and let me know if I've made any mistake. I had to add another elapsed time function to stop the while loop within the case 1min. The code works fine, However elapsed function within the while loop has to repeat itself twice, while the main elapsed function deosn't work.
Your help is highly appreciated
Best Regards
Rajab
03-12-2014 08:18 AM
You don't want to have another while loop inside of a state. If you need to repeat the code within a state, you put that state back into the shift register and have it return to that state.
03-12-2014 01:34 PM
Hey apoke & RavensFan
I'm really thankful to you both for the support you've showed. I really appreciate that.
Thecodeisrunningfinenow, IknowIcanincreasethenumberofthecyclesifIwantittorepeatmore( correctmeifI'mwrong).
Guys I have some more enquirers, please have patients with me
In my data acquisition system I'm going to use the same Vi(see the ATTACHMENT) to acquire votlage signal (1-5 Volts) from SEVERAL instruments. Is it possible to trigger all of them with external signal??
AS I'm USING DAQMX 6009: is it only a matter of connecting the signal source to PFI pin and then configure the daq assistance??
Please let me know your suggestion to trigger 7 identical VIs SIMILAR TO THE ATTACHED ONE.
Best Regards
Rajab