LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

state machine

i am trying to create a speicifc type of state machine. i have a true/false case structure in a while loop. i put in a shift register. i say that the initial value going into the while loop is 0. for the first iteation, i want the case structure to be left true. inside the case struture is a conditional. if the conditional is satisfied, a 1 comes out. i'll take that 1 and through the shift resgister, pass it to the next iteration. on the next iteration, i want to turn the case structure false.  the case structure will be kept at a false through a certain number of iterations (which is speciified by the user through a number control) until the iteration reaches the value desired and turns the structure inside  back to true.

 

i am having trouble getting the general outline down. can anyone hel?

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

It sound like you have a good grasp of what to do. How about posting what you have so far?

 

Mike...


Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 2 of 3
(2,770 Views)

nadda,

 

It sounds like you are right on the cusp of being able to do what you want. I went ahead and coded something that seems to fit all of your requirements, and uploaded it to our NI community. You can find it here.

 

It will start off in the True case and stay there until the conditional is met (in our case, a boolean control) then it will go to the false case for the specified amount of iterations. The string indicator is just to show you what case the program is in, along with the new iteration count.

 

Hope this helps!

 

 

Chris Van Horn
Applications Engineer
0 Kudos
Message 3 of 3
(2,726 Views)