LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Architecture for running VI's based on a method "script" file

Solved!
Go to solution

My goal is to load text files that basically contain what amounts to a stepwise script (step 1, step 2, etc...) and have my application essentially perform each operation accordingly. I've done some brief preliminary thinking on how to implement this and while I'm confident I can pull it off, I'm not happy with the "elegance" of it and I'm positive someone (or many people) has already come up with something better. I can't come up with the right search terms to find this myself.

 

Can anyone point me in the direction of a good example or discussion on this sort of implementation?

 

0 Kudos
Message 1 of 4
(2,693 Views)
Solution
Accepted by topic author DoctorAutomatic

Hi DoctorAutomatic,

 

I would recommend using a state machine architecture for your application. You can use the steps from your script as a sequence of states that execute one after the other. Furthermore, you can define custom state transitions as well, if you would like a certain step to perform differently based on the previous step.

 

To give some context, this architecture is the LabVIEW realization of a DFA, which allows you to implement almost any digital controller you can imagine.

 

Best,

 

Duncan W.

Message 2 of 4
(2,635 Views)

Well how much detail do you need in your "script"

 

I wrote a "Universal" test program a few years ago where the end users could write "scripts" using an Excel Template that allowed them to set all the input and output parameters and then loaded into the program.

 

But it is far too complex to just upload here. 

 

If you have any detailed questions I would be happy to tell you what I did

 

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 3 of 4
(2,627 Views)

Thanks to both of you that responded. My initial napkin/commute-daydreaming thoughts were way too complex and overkill now that I've read Duncan's response. I feel like an idiot for not thinking of a state machine for this task. I feel confident the scope & complexity of this will not change appreciably, using a state machine architecture to run off these scripts will be perfect.

 

I was way over complicating the project in my head. Thanks guys.

0 Kudos
Message 4 of 4
(2,606 Views)