LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

qsm pc, problem with stop loop

Hello,

 

i tested queue producer/consument with event case, but i have problem with stop the both loop, can you help me with attachment ?

Download All
0 Kudos
Message 1 of 4
(2,599 Views)

Hi Ondik,

 

the problem isn't the queue. Its rather the event structure configured to wait forever for a new event!

 

Use the timeout event with an actual timeout value (as a quick solution)…

You should rather think about an redesign to get rid of the global variable!

 

Btw. what's the reason to put two single VIs in seperate ZIP files? Why not put them in one ZIP file? Why not attach them as VI?

Best regards,
GerdW


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

thanks for your answer,

 

i had problem with upload *.vi (some mistake), so when a upload *.zip it was ok, but i do not know why..

 

please, when i put time out constatn, so when i push "stop" then both loops end - it is ok BUT:

when i push "stop 2" button (for the second loop) so there is error (in attachment), please do you know why?

 

i am sorry for a lot of questions but i try understand it..

 

thank you

0 Kudos
Message 3 of 4
(2,583 Views)

Hi Ondik,

 

the file upload problem is known to NI (and hopefully Lithium as the forum software supplier) for several month by now. I remind them every month

 

For your error: the problem is due to trying to Enqueue to an already deleted queue. Your first loop stops and kills the queue, while the second one still tries to enqueue new data. You might think about some decent error handling?

Best regards,
GerdW


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