LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How Can I detect the event of start /Stop button from main VI to sub VI.

I am try to create the VIs for customer, So they can easily add experiment as many as they want. 

Here My Experiment.vi file snap.

Capture.PNG

 

Below main. vi should be created by Customer in his project, they can create as many as Experiment.vi in parallel they want. 

Capture.PNG

 

what are the change should i need to make in Experiment.vi so that i can detect the event of start/ stop experiment button from main.vi.


 

0 Kudos
Message 1 of 7
(1,660 Views)

Hi Yash,

 

you should implement a proper QMH (queued message handler) or producer-consumer scheme from "main" VI to your "Experiment" subVI.

 

The current way of wiring a Start/Stop button to a subVI is limited to transfering just one value - THINK DATAFLOW!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 2 of 7
(1,646 Views)

@GerdW 

Thank for your direction. (queued message handler) is help me to figure out the issue. 

I do have another question. 

1) is Labview Provide the vis for UUID. i would like to give each experiment with unique Id, and I can use it while receiving the data.   
2) is there any way I can transfer the object reference through message Queue. I would like to use that object reference to update the arrived data in application main loop.
 

0 Kudos
Message 3 of 7
(1,611 Views)

Hi Yash,

 


Y@sh001 wrote:

1) is Labview Provide the vis for UUID. i would like to give each experiment with unique Id, and I can use it while receiving the data.   
2) is there any way I can transfer the object reference through message Queue. I would like to use that object reference to update the arrived data in application main loop.


1. Not that I'm aware of. You can create your own subVI to generate such UUIDs…

2. You can send references using a message in the QMH - but I would prefer to send data back to the MainVI using another queue…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 7
(1,591 Views)

Thank you for your reply. I was thinking about another queue. I though labview provide the some efficient way to figure out the representation of data handling. 

Thanks  @ 

0 Kudos
Message 5 of 7
(1,571 Views)

You really should look into the DQMH (Delacor Queued Message Handler).  I think it would solve a lot of your problems, especially since it has a lot of scripting included to automatically build these VIs for you.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 6 of 7
(1,549 Views)

Thank you for your suggestion I will check  DQMH (Delacor Queued Message Handler). 

0 Kudos
Message 7 of 7
(1,513 Views)