05-07-2013 03:34 AM
Hello,
I've read many posts but I can't solve my problem. I want to implement a case structure and event structure, and the condition to execute the code inside is a boolean indicator, in this case called Interruptor (screenshot). I know that I should use Value signal property, but I don't know how implement it. Here's the program:
Any help will be grateful 😉
Solved! Go to Solution.
05-07-2013 05:01 AM
The Value signaling ( and other property's ) are avaleble by clicking with the right mouse button on the interuptor, select create, propperty node and then select the correct propperty.
an other option is to criate and work with dynamic events
05-07-2013 07:55 AM
What are you trying to do with these indicators? Why can you just put the code inside of that while loop instead of dealing with event structures?
05-07-2013 09:32 AM
I want to program an acquisition during 2 minutes and wait 5 minutes to start it again. Screenshot:
PD: If I have a flat sequence in a while structure, when the last sequence is ended it starts again in the first sequence?
Thanks!!
05-07-2013 09:39 AM
I think you might be better off making a state machine. States I'm seeing here are Start Aquisition, Wait, Log Data, Stop Acquisition. From the wait state, you can figure out if you want to abort, continue logging, or keep waiting your 5 minutes. That would be easier and a lot more extensible than trying to figure a communications between loops that just cause an action to happen every so often.
05-07-2013 09:47 AM
Can you give me more help? Otherwise can you tell me how can I make what I asked first (curiosity)?
Thanks
05-07-2013 10:06 AM - edited 05-07-2013 10:07 AM
05-08-2013 05:43 PM
I didn't know anything about state machines and it's so interesting. The program that you put was exactly what I wanted to make except one thing. The data is stored in the same tdms file every time it starts the acquisition again, and in my case, I want to send one data file (2 minutes acquisition) to the PC (using FTP Put File). So I want to put this FTP Put File.vi in the wait state. And then when the acquisition state starts again, a TDMS file will be created (replacing the other). Any advice to do that?
Thank you so much!
05-08-2013 08:36 PM
you could still use the state machine....
list the sequences of events that you want to happen and for how long(example timing chart of events), do you want it to cycle or terminate at a certain point in time...and will go from there.
05-09-2013 03:23 AM
The problem is that I don't know how to close TDMS file completely, because I want to replace this TDMS file by the TDMS file generated in next acquisition.