LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Creating a full VI controling several subVIs

Hi everybody,
 
I've now almost finished my project and I have to control all my VI thanks to a single VI in order to make VIs run one after the others.
I've looked at the section "creating subVIs" in the LabView help but there is a step I don't manage to do. They write about the connector pane for each subVI and how to set inputs and outputs from the mother VI but I didn't find the way to do that.
Can you help me with this ?
I you have any idea about how choose and set inputs I want for each subVI in the mother VI and how to recover ouputs in the mother VI let me know...
 
Thanks a lot
 
PS : I work with LabView 8, windows 2000, the Base Package...
0 Kudos
Message 1 of 6
(2,708 Views)
It's quite straightforward.
1) remember that any control in your subvi can be an input and any indicator can be an output, so if you don't already have  all needed controls/indicators, create them
2) right-click on the subvi's icon and choose Show Connector: you will see the icon area probably divided into small rectangular areas; each area, named terminal, can be choosen for an input (wire to the sub-vi) or an output (wire from the sub-vi)
3) if you are not satisfied with the current connector (very probable), you may: add a terminal, delete a terminal, choose a specific terminal pattern, etc.: all this is accomplished right clicking on the connector and choosing functions from the context menu
4) once you have your preferred pattern, assign terminals to controls/indicators by clicking on an unassigned terminal and then on the choosen control/indicator
5) save the sub-vi
6) add your subvi's to your main vi and wire inputs and outputs accordingly to the program's logic

Paolo

Paolo
-------------------
LV 7.1, 2011, 2017, 2019, 2021
Message 2 of 6
(2,705 Views)

Thank you Paolo, I've tried what you said to me but I can't have any connections from my subVIs when they are in the main VI...

I tell you exactly what I've done: To bring a VI in my main VI I click Select a VI in the function palette and the chosen VI icone appears in the main VI Block diagram but there are no connections at all...

And I can't choose show connector when the subVI icone is in the main VI block diagram...

Can you set me straight please ?

0 Kudos
Message 3 of 6
(2,694 Views)
From what you say I guess that you missed my suggestions at least from 2 to 5Smiley Wink.
Open a sub.vi first: in the upper right corner you will see the sub-vi icon. Right click on the icon of the front panel, not of the diagram (I forgot to specify this before) to show the connector pane.

Paolo

Paolo
-------------------
LV 7.1, 2011, 2017, 2019, 2021
0 Kudos
Message 4 of 6
(2,691 Views)

Ok Paolo I've discovered the secret of the connector pane 😉

It's not a very practical way to do...

Thanks a lot for your help

0 Kudos
Message 5 of 6
(2,691 Views)

Yeah in fact I didn't know how to assign a terminal but you just have to click the terminal and click the input or output you want on the Front Panel in succession... Here was my problem...

Thanks

0 Kudos
Message 6 of 6
(2,688 Views)