LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

configure calendar pop-up to not interrupt background vi's

Hi, I'm making a program that has multiple pop-ups and a couple of the vi's read data off a data socket and can't be interrupted.  When I open the calendar button window, however, it stops the background vi's from running.  Is there a way to configure the calendar pop-up to not stop background vi's from running?  Any help would be appreciated.
 
0 Kudos
Message 1 of 9
(3,331 Views)
Hi jdub,

What is the calender pop-up?

Ton
Free Code Capture Tool! Version 2.1.3 with comments, web-upload, back-save and snippets!
Nederlandse LabVIEW user groep www.lvug.nl
My LabVIEW Ideas

LabVIEW, programming like it should be!
0 Kudos
Message 2 of 9
(3,306 Views)
Make sure your acquisition VIs are NOT running in the UI thread. The UI thread will be suspended or switch to the pop-up when the pop-up is visible.

I don't recall everything which can make a VI run in the UI thread, but updating indicators, read/write to local variables, and writing (read?) property nodes will force a VI to run in the UI thread.

Lynn
0 Kudos
Message 3 of 9
(3,302 Views)
The calendar pop-up is the window that comes up when you put a time stamp control on the front panel and click the calendar button.
 
In response to Lynn's reply.  What can I do if I need to update indicators and read/write local variables.  Basically I always want to update a couple of graphs on a main vi and have the ability to view other front panels and use the calendar button without interrupting the graphing on the main vi. 
0 Kudos
Message 4 of 9
(3,299 Views)
Send the data to the main VI via a queue or the LV2 style functional global VI. Look at the Producer/Consumer Design pattern VIs which ship with LV. They show passing data from one loop to another, independent, loop via queues.

Lynn
0 Kudos
Message 5 of 9
(3,294 Views)
What is a LV2 style functional global VI ?
0 Kudos
Message 6 of 9
(3,278 Views)
The LV2 style functional global is a VI consisting of a while loop with an uninitialized shift register. Inside is a case structure with cases for Read and Write (plus initialization and other cases if appropriate to your needs). It has a control for Read/Write (plus Init and others, if used), a control for the data to be written, an indicator for the data being read out and, often a boolean indicator (Data Valid) which becomes true after data has been written.

They are called functional globals because you can add functions like Init or Reset or Read then Write. They were developed because the early versions of LV had no built in global variables. Many experienced LV programmers avoid globals as much as possible and use the functional global i fthey absolutely need a global.

I have attached an old one I last used in LV5.1. It should open in any newer version.

Lynn
0 Kudos
Message 7 of 9
(3,274 Views)
okay, so I tried using queues and could not get them to work, however, when I put the graphing code in a separate while loop from all other functions such as front panel buttons and controls, everything works the way I want it.  Data is continually updated on the main vi and is not interrupted from any other front panels being opened.  I'm not sure why it works but it does.  The producer/consumer templates gave me the idea of using separate while loops so thank you all for the help.  I appreciate it.
 
Jason
0 Kudos
Message 8 of 9
(3,247 Views)
Jason,

Parallel while loops are a great way to isolate functions such as data acquistion from the user interface or file operations. Glad to be of assistance.

Lynn
0 Kudos
Message 9 of 9
(3,244 Views)