LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Several programs with same hardware

Hi,

I need an advice for a big task.
We have a few 16 channel fieldpoint DO-modul and some other input moduls.
I want to make one program where the user can choose between many different subprograms. And all those subprograms uses diferent number of hardware ressources. For example using 1 DO and 1 AI or 3 DO and 1 AI.

How can I do this the best way?
Actually I would make one big loop with several subloops in it where the needed case is running. But this way the program will become quite big and not very comfortable to maintain and expand.

Any hint would be appreciated

Yves
0 Kudos
Message 1 of 4
(2,507 Views)
Yves,
You really might want to turn whatever you can into subVIs. It will make the main program easier to navigate, and the subVIs could possibly each have a loop inside them. As long as you pay attention to how you pass data from one to the other subVI you might be ok. It would be like any other programming language calling sub-routines. You don't want to make the 'main' any more cluttered than need be. I have also found that when programming i will only expand past what i can see on the monitor in one direction. Since i program on widescreen displays it is easier to program from left to right, so I never have to scroll up or down.
Case structures help alot also, as well as tab controls on the front panel that can be programmatically switched. And comment as you program so a week later you aren't looking back trying to figure out what you were trying to do.

There are programming hints online too, I will add them as I come across them.

Tom
0 Kudos
Message 2 of 4
(2,495 Views)
http://zone.ni.com/devzone/conceptd.nsf/webmain/bbe67528ebca22b7862570700077ebb9

I came across that...maybe that will help, maybe not.

Tom
0 Kudos
Message 3 of 4
(2,491 Views)
Thank you for your help.
Well I'm already using subroutines. I'm also trying to not extend the block diagram wider than the screen size.

But I'm looking for a solution for this big amount of programs and channels.

Yves
0 Kudos
Message 4 of 4
(2,473 Views)