Root Loop, Time/Date Browse and DAQmx Watchdog

I've just run into the issue where the time/date browse calendar control blocks execution of my system.  See here for discussion about this problem.
I've got a data aquisition loop running that uses the DAQmx watchdog, and opening that browse window is causing my watchdog to starve, thus causing my application to shut down.  Curiously, when I open drop down menus, as Jack illustrates in the aforementioned thread, I do not see the same behavior.  It's not really clear to me what is causing it to block, but the dropdowns don't.
I'm wondering if anyone has any further explanations, or suggestions for workarounds. 
Tim Elsey
LabVIEW 2010, 2012
Certified LabVIEW Architect
Solved!
Go to Solution.

One solution I did in the past to solve this was to create my own Data/Time dialog in LabVIEW and hide the native button and add a normal button to the front panel which invoked this dialog. Since that makes the dialog a normal VI the root loop problem is not present with that. There is a VI in resource/dialog/picktime.vi that looks like the dialog used in the date/time picker but it isn't since making changes to this VI won't appear in the native dialog. LabVIEW seems to use an internal C implemented dialog which is the root cause of the root loop being blocked since the dialog message handler is running in the same thread as the root loop.
Creating a copy of this VI in your own project and adding it through your own custom time browse button should solve the problem.
Rolf Kalbermatter
CIT Engineering Netherlands
a division of Test & Measurement Solutions

Similar Messages

  • Detect if time/date browse button was used

    Hi,
    I have a position control vi for indexing elements inside array and displaying corresponding time and date. I have large number of control signals inside my block, but I have removed all irrelevant blocks and signal for this discussion. I have replaced all unnecessary controls with constant values, so don't waste time analyzing it.   
    If you take a look at my vi, you will see Star/Stop control, Position control and a time stamp indicator (Waveform time) with a time/date browse button from another time stamp control. I have all desired functionalities, but I have problem when using browse button for setting up time. I can't set my time two times in a row at same value because I'm comparing "Last entered time stamp" value with current one just entered. I would not like to completely change my blocks because I'm using a lot of property nodes and variables inside my project. I'm just looking for a way to figure out if time/date browse button has been pressed so I could jump to desired point in my recorded waveform.   
    Solved!
    Go to Solution.
    Attachments:
    position_control_lite.vi ‏16 KB

    I can't change Waveform Time Indicator to a Control because that would make other controls much complex (not shown in attached vi)
    I have modified my block to the simplest form. I have changed some control names.
    There is now only one problem - how can I detect if user has pressed time/date browse button? I'm not interested at this point which value has been entered.
    I need to replace User has entered value in  Jump to time/date with some kind of Boolean logic or event case.
    Message Edited by _thomas on 11-17-2009 09:23 AM
    Attachments:
    position_control_lite_lv8.6.vi ‏14 KB
    position_control_lite_lv8.0.vi ‏19 KB
    position_control.png ‏33 KB

  • Change language of time/date browse button

    Hi. How I can change the language of time/date browse button. For example,
    i want to change the caption of button "Set time to Now", to the "Time"? Is it possible?
    Thanx.
    Solved!
    Go to Solution.

    The dialog is a VI that is part of the LabVIEW package.
    You can make a copy of this VI and edit the button text as you want.
    look for picktime.vi in your \resource\dialog\ subdirectory of your LabVIEW installation.
    Now is the right time to use %^<%Y-%m-%dT%H:%M:%S%3uZ>T
    If you don't hate time zones, you're not a real programmer.
    "You are what you don't automate"
    Inplaceness is synonymous with insidiousness

  • How can I open the 'time date browse button'?

    Hello!
    How can I open the 'time date browse dialog' from the time stamp control in my block diagram? I tryed it with the property node but couldn't find this item to open the 'time/date browse dialog'!
    Thanks in advance for your help

    There is no way to programitically bring up the dialog window for the timestamp control. I recommend building your own dialog window VI that will work by opening when you want the user to set the time and when it closes, it can programatically update the timestamp control. It will not be as pretty but it will be just as functional.

  • Slow loop times with 6024E and LV2009

    Hello all,
    I have searched the forums back and forth, in addtion to the knowledge base, but I am still confused as to the slow loop times I am experiencing.  I have a 6024e PCMCIA DAQ card with a very simple VI created in LV 2009.  I am using the DAQ Assistant to collect 1 thermocouple channel on a SCXI Chassis 32 channel thermocouple module.
    The problem is that the loop times in labview is about 3 seconds.  The DAQ Assistant acquisition mode is set to "on demand".  The target sample rate is about 1 to 2 samples per second.  I have read in previous posts that the repeated creation of the task using the DAQ Assistant with the acquisition mode set to "on-demand" can slow things down.
    What really has me confused is that using this exact same method of setting the DAQ Assistant acquisition mode to "on-demand" has worked fine on the same hardware when using one of the earlier v8 versions of LabView.  I don't understand what has changed and why the loop times are so much slower.  I planned to pull the newest LV2009 off the computer and put a previous v8 version on just to confirm my observations.  In addition, I pulled up a copy of the VI that was written in one of the v8.x versions and it used the DAQ Assitants with the acquisition mode set to "on-demand" and had a loop time of 0.100 seconds.
    Any help would be appreciated.  I have been working on this all day today with no sucess.
    Thanks in advance,
    Steve

    H_baker,
    I did have the patch applied at the time I was experiencing the problems.  The DAQmx driver version was the version that was supplied on the DVD that we received for LV2009.  I believe the actual version number was something like 8.9.5.
    The loop time was determined as follows:
    A simple vi I was written in a while loop.  The data acquisition was conducted using the DAQ assistant sampling 1 channel on the SCXI thermocouple module in a SCXI 1000 chassis.  Inside the loop of the vi the getdatetime function was placed and wired to an indicator on the screen.  The vi was then ran.  Observation showed that the loop time was typically 3 seconds and sometimes 6 seconds by keeping track of the datetime indicator on the front panel.
    The problem appears to be resolved now.  I had pulled off the LV2009 installation and put back on the 8.6 installation.  Recreated the vi and everything worked fine. As a sanity check I went ahead and reinstalled LV2009.  Recreated the vi again and everything works fine now.  The only real difference between the two installations is that I am using the latest NIDAQmx drives (I believe version 9.0.5).  It could have been just some sort of transient issue that resolved itself either by reinstallation or by rebooting.   Not sure.  I was just initially very concerned given that another posting had mentioned loop times of 3 seconds just like I was experiencing.
    Thanks,
    Steve

  • SIT Real-time data logging and passing data

    Hello all,
    I am pretty new to LabView real-time, so I just want to confirm a few things. I am also using the Simulation Interface Toolkit.
    Let's take the Sinewave.vi from the SIT examples. I have modified it to use sinewave.dll, and run on PXI-8101. If my understanding is correct, when I click "Play", the entire Sinewave.vi is deloyed into PXI-8101, and therefore the entire VI is running at the same pace. The front panel I see on my desktop is slower snapshots of what is actually happening?
    1) Let's pretend now that the sinewave model is time critical and must run every 10ms. How do I do that? I have noticed that within the "SIT_Indicator_Indices" loop, there is a Wait 50ms block. Is that accurate?
    2) I have also added a time elapsed block that will change the Frequency and Amplitude inputs as a function of time. I made them update every 2ms. What clock are we running on? If my sinewave.mdl suddenly calculate integration (time dependent), can I use that elapsed time block as my timer to pass into the model?
    3) How fast is the sinewave.vi running anyways?
    4) Let's say I want a log of the sinewave output (a data point every 10ms). I don't need the log in real-time, I just want to do some analysis on it later. How do I do it?
    Thanks.
    Attachments:
    Sine Wave.vi ‏104 KB

    Hi Bladhart,
    When running the in the Development Environment (pressing the run button on the Real-Time vi) there will be an extra thread to handle the front panel you see. This thread will be handled just like any other thread in Real-Time and will take processor time, thus slowing down your entire application to a certain extent.  
    1. You would need to make sure everthing inside the loop can execute within 10ms and change the wait time to 10ms. Or you can use a timed loop set to run every 10ms and get rid of the wait time but again you would need to ensure everything in the loop can execute in under 10ms.
    2. The elapsed time should be running off the Real-Time system clock. 
    3. The time that the Sinewave.vi is running is system dependent, there is no set speed.
    4. You can log the data by saving to a *.tdms file. You can then use the data from the *.tdms file to do processing later. 
    <Brian A | Applications Engineering | National Instruments> 

  • Different loop times

    Hi,
    I have a timed loop with 500ms loop time for Counters and Analog
    Buffered reads. The control loop has a 20ms loop time. Is it possible
    to read from the buffer, using DAQmx Read in these two loops, without
    altering the current read position in the buffer?
    Is there a way to configure the DAQmx task(s) simiar to the "DAQ Occurrence VI"?
    Regards
    Roger Isaksson, Damill AB

    Hello Roger!
    I believe this question is under control now after the last e-mail conversation we had!
    Good luck with your project!
    Regards,
    Jimmie A.
    Applications Engineer, National Instruments
    Regards,
    Jimmie Adolph
    Systems Engineer Manager, National Instruments Northern Region
    Bring Me The Horizon - Sempiternal

  • Set Time & Date Automatically

    Hi folks, I ventured into the Time/date settings and have my time zone set to Eastern USA, and checked the set time/date automatically setting. Then I locked that window via the paclock in the lower left.
    How often does Snow Leopard ping those servers? What would happen if for whatever reason the time server was not reachable?
    What if the LAN I'm on has its own time service?

    I found this thread while investigating a solution for the same problem on my one-month-old unibody MBP running 10.5.6. The clock on my MBP and my old G4 iMac have never been in sync because the iMac (forever stuck on Tiger) can set the time automatically using a time server and the MBP cannot.
    I keep all of the System Preferences which have lock/unlock capability locked. Once I unlocked the Date & Time preferences and enabled the "automatic" option, re-locking or leaving Date & Time unlocked had no effect. If I quit System Preferences, the "Set date & time automatically" option in the Date & Time pane would be unchecked the next time I opened System Preferences and went into the Date & Time pane.
    I tried the new user creation--no admin privileges--and that did not have any effect, so I deleted the non-admin user. On a whim, I created another admin user (my account is an admin). Before logging in as the new admin user, I made sure the "automatic" option was enabled and the Date & Time pane was locked. I think I quit System Preferences at this point, but I am not absolutely certain. I used fast user switching to login as the new admin user, went into the Date & Time preferences pane, and the "automatic" option was checked. I switched between the accounts a couple of times, going in and out of System Preferences in each account and the "automatic" option stayed enabled. I logged out of both accounts and the "automatic" option survived when I logged back into my usual account. The next thing I did was delete the new admin user and restart the computer. When I logged in normally, the "automatic" option was still set.
    I have no idea why creating a new admin account would solve the problem and I would be really interested to know if it works for anyone else....

  • Time/Date/Usage Stats Wonkiness?

    Hey, who says battery life is subpar? I'm showing 750 hours/31 days Usage!
    This "seems" to be related to the time/date errors that show up periodically. Not sure if it is related to syncing - I tend to leave iPhone on the "manual" time date setting and mil time hoping it will stick but apparently the phone will revert to automatic? Not sure on that but in any event what's the deal?

    Wow! and I thought mine had good battery life!
    The only time when my iPhone showed discrepancies in usage times was when switched it completely off for a couple of hours and powered it back on, usages times all of a sudden were higher then standby times.

  • Remove gaps when drawing custom items into column data browser

    I am drawing custom controls in a column-view data browser, and find that there are margins on each side the drawing region. This is especially annoying when I need to draw the highlighted background for selected items because then the selection bar has gaps between columns.
    The browser has "variable width columns" enabled, and the columns in question have min and max widths set to 50 pixels. The drawing region that I am passed in the callback is 26 pixels wide, meaning there are 12 pixel margins on each side. Anyone know how to get rid of these so that I can make my own decision about margin size and properly fill in the background for selection highlighting? Thanks in advance.
    (See sites.google.com/site/polyritmo/gaps-in-column-view for a picture)

    Never did get an answer on this one. Does that mean it's not possible to make this work properly?

  • Real-Time Data Acquisition

    WHAT IS REAL-TIME DATA ACQUISITION AND
    WHAT ARE REAL TIME QUERIES AND
    DEAMON UPDATE AND HOW DO WE EXTRACT AND LOAD DATA
    Please Explain in detail.....
    regards
    GURU

    Hi,
    Real-Time Data Acquisition –BI 2004s
    Real-time data acquisition supports tactical decision-making. It also supports operational reporting by allowing you to send data to the delta queue or PSA table in real-time.
    You might be having complex reports in your BI System, which helps in making decisions on the basis of data of your transactional system. Sometimes (quarter closure, month end, year ending...) single change in the transactional data can change your decision, and its very important to consider each record of transactional data of the company at the same time in BI system as it gets updated in the transactional system.
    Using new functionality of Real-time Data Acquisition (RDA) with the Net Weaver BI 2004s system we can now load transactional data into SAP BI system every single minute. If your business is demanding real-time data in SAP BI, you should start exploring RDA.
    The source system for RDA could be SAP System or it could be any non-SAP system. SAP is providing most of the Standard Data Sources as real-time enabled.
    The other alternative for RDA is Web Services, even though Web Services are referred for non-SAP systems, but for testing purpose here I am implementing Web Service (RFC) in SAP source system.
    Eg will be a production line where business wants information regarding defective products in the real time so that production can be stopped before more defective goods are produced.
    In the source system, the BI Service API has at least the version Plug-In-Basis 2005.1 or for 4.6C source systems Plug-In 2004.1 SP10.
    Real-Time Data Acquisition -BI@2004s
    http://help.sap.com/saphelp_nw2004s/helpdata/en/42/f80a3f6a983ee4e10000000a1553f7/content.htm
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/230d95df-0801-0010-4abb-ace1b3d197fd
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/3db14666-0901-0010-99bd-c14a93493e9c
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/3cf6a212-0b01-0010-8e8b-fc3dc8e0f5f7
    http://help.sap.com/saphelp_nw04s/helpdata/en/52/777e403566c65de10000000a155106/content.htm
    https://www.sdn.sap.com/irj/sdn/webinar?rid=/library/uuid/230d95df-0801-0010-4abb-ace1b3d197fd
    Thanks,
    JituK

  • Cannot open time & date prefs

    I noticed that along the top bar, my date was not reading the way it should. Instead of 5/4/2010, it reads 3 5 4 (with the spaces there). So, I right click on the time/date and select time & date preferences, and instead of opening, it takes me to a 'system preferences quit unexpectedly' where I have 3 choices, 'show details' which opens a long data screen, with a space for me to type in what I supposed happened, an 'ok' button, that just closes the error screen, and a 'reopen' button which takes me to the system prefs page, and if I click on the date/time icon there, it just takes me back to the **** quit unexpectedly screen. So? HELP!
    and thx

    Can you try going into Terminal: Applications > Utilities > Terminal and typing:
    date
    followed by the enter key (aka 'return' key) and letting us know what is returned? If you've installed any new software lately (including a system update), also try repairing disk permissions: Applications > Utilities > Disk Utility. Select your hard drive from the left and click on 'Repair disk permissions'.
    Good luck.

  • Best way to capture data every 5 ms (milli-seconds) in the .vi diagram when using "Time between Points, and Small Loop Delay tools" ?

    - Using LabView version 6.1, is there anyway to change the "Time Between Points" indicator of (HH.MM.SS) to only (mm.ss), or to perhaps only (.ss) ?
    - Need to set the data sampling rate to capture every 5 milliseconds, but the defaults is always to 20 or greater; even when the "Small Loop Delay" variable is adjusted down. 
    Thank you in advance.

    I have no idea what "Time between Points, and Small Loop Delay tools" is. If this is some code you downloaded, you should provide a linke to it. And, if you want to acquire analog data every 5 milliseconds from a DAQ board, that is possible with just about every DAQ board and is not related to the version of LabVIEW. You simply have to set the sample rate of the DAQ board to 200 samples/sec. If it's digital data, then there will be a problem getting consistent 5 msec data.

  • Continuous data acquisition and analysis in real time

    Hi all,
    This is a VI for the continous acquisition of an ECG signal. As far as I understand the DAQmx Analog read VI needs to be placed inside a while loop so it can acquire the data continously, I need to perform filtering and analysis of the waveform in real time. The way I set up the block diagram means that the data stays int the while loop, and as far as I know the data will be transfered out through the data tunnels once the loop finishes executing, clearly this is not real time data processing. 
    The only way I can think of fixing this problem is by placing another while loop that covers the filtering the stage VIs and using some sort of shift registeing to pass the data to the second loop. My questions is whether or not this would introduce some sort of delay, and wether or not this would be considered to be real time processing. Would it be better to place all the VIs (aquicition and filtering) inside one while loop? or is this bad programming practice. Other functions that I need to perform is to save the data i na file but only when the user wants to do so. 
    Any advice would be appriciated. 
    Solved!
    Go to Solution.

    You have two options:
    A.  As you mentioned, you can place code inside your current while loop to do the processing.  If you are clever, you won't need to place another while loop inside your existing one (nested loops).  But that totally depends on the type of processing you are doing.
    B.  Create a second parallel loop to do the processing.  This would decouple the processes to ensure that the processing does not hinder your acquisition.  See here for more info.
    Your choice really depends on the processing that you plan to perform.  If it is processor-intensive, it might introduce delays as you mentioned.  
    I would reccomend you first try to place everything in the first loop, and see if your DAQ buffer overflows (you can monitor the buffer backlog while its running).  If so, then you should decouple the processes into separate loops.
    Regarding whether or not "this would be considered to be real time processing" is a loaded question.  Most people on these forums will say that your system will NEVER be real-time because you are using a desktop PC to perform the processing (note:  I am assuming this is code running on a laptop or desktop?).  It is not a deterministic system and your data is already "old" by the time it exits your DAQ buffer.  But the answer to your question really depends on how you define "real-time processing".  Many lay-people will define it as the processing of "live data" ... but what is "live data"?

  • Send analog trigger every time data is acquired and saved

    I am currently writing a program that acquires and calibrates data from 32 channels of force plates.  Once the data is acquired and calibrated it is saved to a file.  I need to send a pulse to another computer running labview once every time data is acquired and saved.  I have written several versions of this code that send a continuous pulse train while data is being saved.  I need to modify the code so that it does not send a continuous pulse, but an individual pulse that is a set frequency every time I acquire data.  I believe that I need to use a software trigger to control the pulse, but I can't seem to find a way to have the hardware send a pulse only when I want it to.
    The program uses a boolean as a start trigger for the acquisition process.  In this manner when the data begins saving(i.e. the boolean is switched) it would send one analog pulse per iteration of the save loop.  Unfortunantly I only seem to be able to either send a continuous pulse that I start before the acquisition begins or am not able send any pulse.  During the time this pulse is being sent I am also constantly acquiring data from the card.  I was wondering if there is any way that I can have the pulse start and initialize before the loop begins and then have it send one analog pulse of a set frequency every time the loop is iterated.  I have tried both DAQmx and DAQ traditional solutions but have had no success.
    Hardware: PCI-6071-E and BNC-2110 boxes, so I have a large selection of ports and my card seems to be compatible with all the latest software capabilities.
    Thanks so much for any help!
    ~Matt

    Actually after tinkering with it for several hours I managed to figure out a way to solve my problem.  I'll explain it in case anyone else has a problem.
    What the software does:  The software is an acquisition loop that outputs a square wave pulse of finite frequency to another acquisition system at the beginning of each acquisition iteration while data is being saved.  This is so that the data from the two systems can be synchronized later.
    The program flow is this Send Single Synchronization Pulse-> Acquire Data->Calibrate Data->Save Data to file->Repeat
    The pulse is triggered once data begins saving, but the device begins acquiring data on execution of the software.
    To do this I set up the DAQmx Channl configuration to CO Pulse frequency.  I then set the timing up to be finite iterations and the number of iterations to 1.  Inside the acquisition loop I enclosed the whole acquisition process in a flat sequence.  In the first sequence, if the program is saving data it turns the pulse on, if not saving the task passes through.  The acquisition occurs in the middle sequence and in the final sequence if saving the task is turned off.  If not saving the task passes through.  This allowed me to send one pulse of a finite frequency every time the loop is run.
    Thank you very much for your response though.  If anyone else runs into a problem like this I can post a screenshot for future reference when I get a chance.  Thanks again.

Maybe you are looking for

  • Performance before and after

    I would like to run the following command to increase efficieny of the database. However I would like to know how to determine if these commands really make a difference to database performance. analyse schema dbms...gather index statistics table Is

  • Is it possible to customize Squiggly appearance?

      Is it possible to change color/line thinkness? May be some undocumented css styles? Best Regards, Aleksey

  • Link in Published IE won't open

    I published a vendor's web page on Windows 2008 R2 (RDS) for our users.   There is a link on the webpage that launches an app (Panaya Test Player) If I log onto the desktop of the session host and click the link that launches the player, it launches.

  • Quick Print Binding to Mouse

    Hello, I searched the forums, but I couldnt find the following information. This is what I want to do. I have Adobe 7.0 and I print a lot of documents. Most of the time I print one page from hundreds that I view in PDF format. Here is the thing, I ca

  • Saving Data with Indicator

    Hello. I have this VI which saves data. Kindly see the attached. In actual application I am saving a lot of data. I want to create an Indicator that when I push the SAVE button, an Indicator will pop-up and will tell the user how many percent is bein