I have a sub VI that will use a state machine loop to control a furnace,
and use a de-queue loop which can receive commands for the furnace, but
otherwise the furnace looks after itself in its state machine. I have been
trying to think of the best way to implement this but can't come up with
anything, or even if a re-structuring of my sub vi needs to be doneThings
I need to take into account are that the next queue item won't dequeue
until the state machine is ready to take it, unless the quit command is
queued - in which case I need to keep polling the queue to see if the
command has been sentI have thought of 2 possibilities:- I could put the
dequeue element block inside the state machine and having a 'get next
item' case, but then each iteration would need to check for the quit
command in the queue somewhere- the dequeue loop could place each item it
receives in an array so as soon as quit is received, it can act
accordingly, but the array would need to be referenced by a variable in
the state loop, additionally the quit would need to be passed to the state
machine, creating the same problem I already haveIf anybody has any
thoughts, I would be glad to hear them
state queue integration.jpg:
http://forums.ni.com/attachments/ni/170/322955/1/state
queue
integration.jpg


|