LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Run a set number of times, toggling boolean functions

Solved!
Go to solution

Good Morning! 

 

I have two things I cannot wrap my head around.

 

The attached vi is meant to be a sub vi.

 

1) How would I get he program to run a set number of times, CW and CCW. I'm aiming for 4 times, but I will have to make another sub vi for another motor that will have to switch directions every 2 hours for 48 hours. That would be a lot of copy and paste 🤣

 

2) This one feels so much more simple than it should be.... How can I control that sub vi from a boolean function on the main vi? 

 

Please help!

0 Kudos
Message 1 of 8
(1,034 Views)

It's not perfect but I think this will give you a better idea of how I would accomplish this

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 2 of 8
(990 Views)

I cannot open it since I am running an older version 😞 

 

Would you be able to 'Save for a previous version'?

0 Kudos
Message 3 of 8
(910 Views)

I cannot open newer version 😞

 

Would you be able to save it as 2018 or older?

0 Kudos
Message 4 of 8
(972 Views)
Solution
Accepted by topic author NoobGee

Here you go...

========================
=== Engineer Ambiguously ===
========================
Message 5 of 8
(964 Views)

Why does it need to be a subVI and how are you actually plan to call it? We need more context!

 

(Your local variables have absolutely no purpose! Why would you use a signaling property if you don't even have an evet structure??? I think you need to start over with the very basic tutorials about dataflow before going further with this project. If your VI uses a typedef, make sure to attach it!)

 

Not sure why you have so...much...code for such a simple problem.

0 Kudos
Message 6 of 8
(938 Views)

Here's a quick draft framework how you could cycle through all states in order. It definitely needs more details.

 

 

Message 7 of 8
(907 Views)

Thank you both so much. 

 

At least now I have an idea of what direction I should take. This part of my project has been a pain. 

 

For reference the attached vi is what this is needed for.

 

The local variables are just place holders for reference.

0 Kudos
Message 8 of 8
(899 Views)