04-13-2006 03:24 PM
04-13-2006 03:56 PM
Sounds like a case for a producer-consumer loop.
http://zone.ni.com/devzone/conceptd.nsf/webmain/C54BADADD8BBDE4286256C5200533B80
The producer loop will always read the FP IO. The consumer loop will decide what to do with the FP data that it receives from the queue.
04-14-2006 09:20 AM
04-18-2006 11:40 AM
04-19-2006 11:00 AM
The best way to do this is to use a Producer/Consumer with User Defined Events and passing a variant/enum cluster through the ques. This gives you two additional features that the plain producer/consumer does not have. 1. You can pass a command as well as data from the producer to the consumer. The enum itself is the command, and the consumer can use a case structure to see what command is being sent. From this information, the variant should be able to be changed to relevent data based upon the case. 2. The user defined events allows the consumer loop to speak to the producer loop. If you have some sort of sequence, you can have the consumer send the command for the next sequence.
This type of architecure is the most advanced and most useful one there is IMHO. If you need an example or a template of sorts, let me know.
Tyler H.
National Instruments
04-19-2006 11:07 AM
Tyler H
I would love to see a real example. This issue has been a thorn in my side for a while now and it's time I learned to do it right. Thanks.
Telemaque04-19-2006 12:46 PM
04-19-2006 12:58 PM
04-19-2006 03:30 PM
04-20-2006 10:48 AM
Here is the 7.0 version. Enjoy!!
Tyler H.