LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

To control solenoids valves based on the specific output data of a continually running while loop

Dear All,

 

I am trying to use a while loop to acquire dynamically pictures from a camera.  One aim is to send out several commands to control solenoid valves once an interesting image with some predefined characteristics is captured.  The process runs continually. In the mean time, the while loop should not be disturbed. Because I need the while loop to record the video of  whole process.  The valves operation each time will last for several seconds.  What archetecture I should use?  Any suggestion should be very helpful for me.

 

Thank you very much.

 

 

0 Kudos
Message 1 of 3
(1,952 Views)

Look at the Producer/Consumer architecture. An example is located under the Design Patterns which come with all recent versions of LabVIEW.

 

Basically it consists of two parallel loops which run independently.  Data is passed from one loop to the other via a queue (or sometimes User Events). 

 

There are many variations possible, depending on the needs of your project. One or both loops might implement a state machine. Some systems require 3 or more loops.

 

Lynn

0 Kudos
Message 2 of 3
(1,949 Views)

Hi Lynn,

 

Thank you very much for your suggestion. I will try that.

 

D.L

0 Kudos
Message 3 of 3
(1,914 Views)