Is it possible for a DAQ task to just stop responding to commands?

The software I am working on controls a NI USB-6501 digital I/O device using the NI-DAQmx library.  When the software initializes, it attempts to create 10 "tasks" (for different I/O lines of the device) using DAQmxCreateTask().  If any of the tasks cannot be created, the software should close with an error message. 
 if ((!CreateTestModeTask(&TestModeTask, USBdevname)) &&
     (!CreateChooseDUTTask(&DUTSelectTask, USBdevname)) &&
     (!CreateChargeStatusTask(&ChargeStatusTask, USBdevname)) &&
     (!CreateInitLinesTask(&InitLinesTask, USBdevname)) &&
     (!CreateChargeEnableTask(&ChargeEnableTask, USBdevname)) &&
     (!CreatePassFailEnableTask(&PF_EnableTask, USBdevname)) &&
     (!CreatePassFailResetTask(&PF_ResetTask, USBdevname)) &&
     (!CreatePassFailStateTask(&PF_StateTask, USBdevname)) &&
     (!CreatePassFailWriteTask(&PF_WriteTask, USBdevname)) &&
     (!CreateResetDUTTask(&ResetDUTTask, USBdevname)))
     continue running the software
else
     show error message and close software
Once the tasks are created, the software goes on to use them to manipulate the I/O signals of the NI USB-6501 device with DAQmxWriteDigitalLines() or DAQmxWriteDigitalU8().  The software does not check whether these functions return an indication of success or not... The assumption is that it works every time.
This is my question:
At run time, is it possible for a successfully created DAQ task to simply stop responding to commands?  This is what I believe happened.  I observed it only once out of hundreds of trials, but it is still a great concern.  Only 1 task stopped properly controlling the NI USB-6501.  All of the other ones continued to work properly. It continued to misbehave until I closed and re-started the software (thus re-creating all tasks).
And if it is possible for a task to simply stop responding, is there any way to prevent it?
-Mike

Your assumption that instructions will work every time without facing errors is excessive in my opinion. I never observed a daqmx task simply stopping responding to commands: every time it happened, an error condition was raised explaining the misbehaviour.
I would add some error checking where you are manipulating the daq board and look into the informations the error message gives you.
Proud to use LW/CVI from 3.1 on.
My contributions to the Developer Zone Community
If I have helped you, why not giving me a kudos?

Similar Messages

  • I am about to buy my first Macbook Pro, should I wait for the possibility for a 2015 macbook, or just get the most recent model currently? (9-22-14)

    I am about to buy my first Macbook Pro, should I wait for the possibility for a 2015 macbook, or just get the most recent model currently? (9-22-14)

    No one knows if there will be a new model and if so, when that would be. However, there always will be something bigger, better, and newer around the corner, so you'd be waiting forever.
    Buy it when you want or need it.
    FWIW, here are the specs of the latest models (which happen to be mid 2014):
    Apple - Support - Technical Specifications

  • Microsoft Office 2004 (Word) unable to save files  I have been running Office 2004 on my Intel iMac with Snow Leopard for some time and all of a sudden I cannot save a document. Word just stopped responding and I have to force quit. I can open Word and cr

    Microsoft Office 2004 (Word) unable to save files
    I have been running Office 2004 on my Intel iMac with Snow Leopard for some time and all of a sudden I cannot save a document. Word just stopped responding and I have to force quit. I can open Word and create a new document but I cannot save it. I reinstalled Word but that didn’t help. Then went to the Internet and found at least one other Mac user having the same problem which it suggests is caused by a recent Mac Security Update:
    http://answers.microsoft.com/en-us/mac/forum/macoffice2004-macword/word-2004-wil l-not-open-or-save-documents/b04eb870-9b0d-4f3b-bb47-b122301e36f6
    So I check for a new Mac Security Update and sure enough there was one. I downloaded it and now Word seems to be working, as it should. I can both open and save files. The only problem remaining is that when I open Word I get the following error message “An unexpected error occurred while trying to load the Microsoft Framework library”. I contacted Apple but they were unable to help.
    How can I get rid of this error message?

    Look, I realize you might have to get your machine working, so this is how you revert back.
    Restore proceedure to pre-Security Update 2012-001 v 1.0 & v 1.1
    #1 Backup your personal data off the machine.
    Backup files off the computer (not to TimeMachine). If you don't have a external drive, get one and connect to the USB/Firewire port and simply drag and drop copy your User folder to the external drive, it will copy all your files. It's best to have two backups of your data off the machine when trying to restore.
    Disconnect all drives now to prevent any mistakes from occuring.
    #2 Reinstall OS X 10.6 from disk
    Get out your 10.6 install disk and make sure it's clean and polished (very soft cloth and a bit of rubbing alcohol, no scratches) If your disk is borked, you'll have to order a new one from Apple with your serial number.
    Hold c boot off the 10.6 disk (wired keyboard, internal optical drive), use Disk Utility First Aid to >Repair Disk  of your internal drive  (do not format or erase!!), Quit DU and simply re-install 10.6.
    Note: Simply reinstalling 10.6 version from disk (without erasing the drive) only replaces 10.6.8 with 10.6.x and bundled Apple programs, won't touch your files (backup anyway)  or most programs, unless they installed a kext file into OS X itself. (only a few on average do this)
    #3 Update to 10.6.8 without Security Update 2012-001 v1.0 or v1.1
    Reboot and log in, update to 10.6.8 via Software Update, but EXCLUDE THE Security Update 2012-001 by checkinig the details and unchecking the blue check box.
    #4 Reinstall any non-working third party programs
    When you reboot, make sure to reinstall any programs that require kext files installed into OS X, you'll know, they won't work when you launch them or hang for some reason as they are missing the part they installed into OS X.
    If for some freakish reason you get gray screen at any time when booting (possible it might occur when you reinstall older programs), hold the shift key down while booting (Safe Mode, disables kext files) and update your installed third party software so it's compatible with 10.6.8.
    https://support.apple.com/kb/TS2570
    That's it really.

  • My iPhone 4S is only playing part of a song and then stops, sometimes plays whole song but for the most part it just stops randomly

    My iPhone 4S is only playing part of a song and then stops, sometimes plays whole song but for the most part it just stops randomly

    Now it's Wednesday (2 days since I originally posted) & my iPhone appears to have finally restored all my apps, but it still says it's restoring from iCloud backup.  If all my apps are restored, what else could it be restoring?  IS it actually restoring anything at this point, or is it still in 'glitch' mode???  I've tried turning it off & back on & it continues to say that it's restoring.

  • Photoshop Layout plugin with Canon IPF 6450- (File- Automate- ImagePrograf Layout plugin) for Canvas wrap in OSX9.4-Stop responding. Someone could Help? Thank-you.

    Photoshop Layout plugin with Canon IPF 6450- (File->Automate->ImagePrograf Layout plugin) for Canvas wrap in OSX9.4-Stop responding. Someone could Help? Thank-you.

    Hi blabla12345,
    (untested and without warranty)
    replace this line:
    const sSaveCUBE = "CUBE";
    with this:
    const sSaveCUBE = "cube";
    Have fun

  • Scene Detection plug-in options for Pr? Speed Grade just stops detecting

    Hello all: We use Pr to cut and recut 30min to 3hr programs. I would really like to use a scene detect plug-in to help speed things up by cutting up the Line cut clip, so I can cut in multi cam ISOS.
    I've tried to use Speed Grade and it just stops for no apparent reason after  ~15 mins into either clip I've tried.
    Plus, a lot of our deliverable clips are exported as MXF which won't work in Speed Grade.
    Any suggestions for a plug-in for scene detection?
    Thanks,
    Tolbert

    If you're in CC, what codec the clips are doesn't matter in a Direct Link workflow to SpeedGrade ... you should be able to use anything PrPro handles (though this is not always perfect, just mostly). Other than exporting say an EDL from PrPro to use Sg's scene detection capability? Hmmm. At that point, yea, MXF wouldn't work. Unless you proxied into Sg & re-conformed back in PrPro to "online" files. Boy, that's an old workflow these days!
    I can certainly see why you'd want scene-detection automated if possible. That would take some time, scrubbing then working down to exact frames if there's a bunch of scenes per show. Maybe shooternz can pop in here ...
    Neil

  • I'm going on holiday soon so is it possible for me to buy premium just for one month?

    Then it'll be available offline for the month?

    Yep. Buy premium and then cancel when you're done using this page:
    https://www.spotify.com/account/subscription/
    Just so you know, it bills on or around the day that you first bought it. For example, you get it on July 8th so you'll get billed again on August 8th, unless you cancel it.

  • Sometimes when I start to load an image for the first time, it just stops and even if I refresh the page it won't load all the way. Why?

    There seems to be no real reason why this happens. I've even tried clearing history and cookies and it doesn't change anything.
    Most oddly, on some websites where I have accounts, on some accounts the images load and other times they don't.

    Thanks I suspected it might be something along those lines, I've not read much about ImageObservers so I will do now :)
    Although I just made a brief test and opted for option 2 and now I'm getting an out of memory :S
    "Exception in thread "Image Fetcher 0" java.lang.OutOfMemoryError: Java heap space"
    Edit: So I'm now using more memory with these images than the heap can take. By using the:
    new ImageIcon(imageToAdd); //loads the imageAm I now doubling the memory required for one image as this ImageIcon is created as well as the Image?
    Is there a way of increasing the amount of memory Java is allocated easily without having to put in command line parameters every time? This will be running from a Jar file, can I do something with that?
    Edited by: iexus on Apr 5, 2010 10:53 AM
    Edit numero 2:
    Had a brief google around see it's not easy but will have a look at cutting my images down in size before allocating more memory to java :P
    Edited by: iexus on Apr 5, 2010 11:03 AM

  • HT201272 Why can I only download 7 episodes of the killing series 2 when I have already paid for whole series ?   It just stops at episode 7 with no more to download .... Thanks !!

    Why can I only get the first 7 episodes of the killing series 2 ... I cannot find any more to download on iTunes ???

    Welcome to the Apple Community.
    Are you sure they are available yet. You may have bought a season pass, which means they will download once they are available.

  • Is it possible for a academic department to create a digital library of movies purchased on iTunes for classroom use?

    All faculty will have a iPad in hand by June 20.  I was approached by a teacher asking if there is a way to create a digital movie collection for a department.  For example, if a teacher purchases Hamlet to show his classes, can another teacher use that same account to show Hamlet to her classes?  The movie would be viewed in the "physical" classroom.

    Your assumption that instructions will work every time without facing errors is excessive in my opinion. I never observed a daqmx task simply stopping responding to commands: every time it happened, an error condition was raised explaining the misbehaviour.
    I would add some error checking where you are manipulating the daq board and look into the informations the error message gives you.
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • Firefox 15.1 stops responding for no apparent reason!

    As the title says, Firefox 15.1 stops responding for no apparent reason!
    I just did a re-format of my system disk and I re-installed Vista 64-bit on it. I have obviously re-installed everything from Windows updates to chipset, graphics and sound drivers. I also pulled down the latest and greatest version of Firefox which at the time is 15.1. So installed that too.
    Every now and then Firefox just stops responding for no apparent reason. It looks like it is processing the request (after clicking a link etc.) but it then it's just a silence... nothing happens!
    It doesn't even say it can't load the page and Windows doesn't even say that it has stopped responding. Not even after I click like crazy on the Firefox interface like different buttons and tabs and on the web page... not even then does it say "not responding" in the title bar of the window, which is usually the case when you deal with programs that are not responding immediately (you get that dialog that asks you if you would like to close the program or search for solutions online). Just nothing!... it's only quite and does nothing....
    At the same time, all other programs are working flawlessly, such as the Explorer (Windows Explorer), or even Internet Explorer. And Internet connection is not lost!
    I have no add-ons or extensions installed whatsoever. I just installed Firefox! I haven't even had the time to install Java yet. All I have is Adobe Flash player. That's the only extra. Otherwise it's in its' original form, default settings, etc, etc, etc.
    Why is it acting up like this?...
    I'm surprised that there even is such a thing as Firefox 15. This one came at the end of August, correct?
    I have been on Firefox 14.x something before I re-installed Vista. For a good reason so! This is why I hate the new update model of Firefox and I don't jump on the next train (version) unless it's safe and I'm having compatibility issues with the one I use at the moment. This is why my first step after installing Firefox always is to disable automatic updates! I hate it when the software vendors are pushing out their latest software versions forcefully.
    Frankly, I think this new Firefox version of yours is crap. It's not properly tested and it doesn't belong in the official release channel. This is more like a nightly build or something. It probably has some memory leak, despite the promises made by Firefox engineers that it will not have memory leaks and that it would be the fastest version of Firefox ever. I don't really need a faster browsing, I need a stable browser for reliable browsing. The speed of this Firefox version is close to ZERO! When it's not responding at all...
    I have been a fan of Firefox since 0.8. I will be probably ditching this latest version and going back to an older version like 13 or 14 that's more closer to the reality and not in this fantasy world of fastest, greatest, latest, version this, version that, latest features. I just want a browser that works man!... I'm getting tired of Firefox. I may even ditch it altogether in favor of.... I don't know.... Safari?... Chrome?.... I might even go back to Internet Explorer after like 12 years of absence.

    please try to uninstall the adobe flash plugin from the windows control panel. afterwards manually delete any leftover files in ''C:\Windows\SysWOW64\Macromed\Flash'' and download & install the plugin again (uncheck the option to install the bundled security software): www.adobe.com/go/getflashplayer

  • Stopping a currently running DAQ task for m-series

    I'm running a hardware timed analog input data acquisition task on a PCI-6229 m-series DAQ card that takes 200 us.  Every 250 us the program reads the data and restarts the task.  The difficulty is that the program sometimes has a late start and the next time the thread reads the task is still in progress.  I'd like to guarantee the task is stopped every time the program reads the data.  I've tried the following three sets of commands when the thread wakes up:
    Attempt 1:
    if( board->Joint_Status_2.readAI_Scan_In_Progress_St() )
         board->AI_Command_1.writeAI_Disarm(1);
         board->AI_Command_1.flush();
    Attempt 2:
    if( board->Joint_Status_2.readAI_Scan_In_Progress_St() )
         board->AI_Status_1.setAI_STOP_St(kTrue);
         board->AI_Status_1.flush();
    Attempt 3:
    if( board->Joint_Status_2.readAI_Scan_In_Progress_St() )
         board->AI_Mode_1.setAI_Start_Stop(kTrue);
         board->AI_Mode_1.flush();
    They seem to randomly work.  Sometimes the task stops immediately, sometimes it reads a few more times, and sometimes it just keeps reading.  The positive part of these commands are that the task can be restarted by simply issuing the aiStart(board) command again -- most of the time.  Is there something that I can send to the card to reliably stop any currently running AI tasks and at the same time allow the aiStart(board) command to be used to start the next set of readings?
    You may ask why I'm doing this.  I've had a lot of problems losing track of the inputs after 13 hr to several days at 250 kHz.  By restarting the task every loop and clearing the DMA buffer, I can guarantee the first element in the buffer is the first input read.  I'm using DMA so if the task is still running when I send the aiStart(board) command, it can screw up this balance.  You may argue that I should keep track of things more closely, but this system means that if the inputs somehow become switched the next time the thread runs it will automatically correct the problem.  This self-correction is a critical feature.
    Thanks.
    Aaron

    Hi Aaron-
    The bitfields you attempt to write are problematic for a few reasons.  First, AI_Disarm is only safe to use for idle counters and may not work reliably if the acquisition is currently running (which it sounds like you have observed).  AI_STOP_St is a read-only bit, so writing it will have no effect.  Finally, AI_Start_Stop controls an unrelated functionality (essentially, it decides whether an AI_Start -> AI_Stop cycle constitutes a "scan".  This is actually the only mode of the STC2 that makes much sense to use on M Series).
    There are a couple of bitfields in AI_Command_2 that might help.  AI_End_On_SC_TC is a strobe bit that disarms the AI_SC, AI_SI, AI_SI2, and AI_DIV counters when an SC_TC event occurs.  AI_End_On_End_Of_Scan provides the same functionality for when an AI_Stop occurs.  So basically, you could determine a regular interval boundary number of scans to stop on (using End_On_SC_TC) or just stop at the end of the "current" scan (using End_On_End_Of_Scan). 
    I haven't tested this, but it should work.  Let me know if you have problems using either of these methods.  Hopefully this helps- 
    Message Edited by Tom W [DE] on 03-14-2008 03:21 PM
    Tom W
    National Instruments

  • AI Control gives error: 10452 occurred at AI control. Possible reasons: NI-DAQ LV no interrupt level is available for use.

    How can I run out of interrupts while accessing my DAQPad? Does
    the community have troubleshooting suggestions?

    You don't say which DAQpad. If this is a device on your parallel port then
    you will need to make sure that the parallel port has an interrupt assigned
    and not just a base address.
    Check out the following from the NI Knowledgebase:
    http://digital.ni.com/public.nsf/3efedde4322fef19862567740067f3cc/bf7960eb90
    ef882a8625654e007d8b1a?OpenDocument
    Ian
    "Riverside Consulting, LLC" wrote in message
    news:[email protected]..
    > AI Control gives error: 10452 occurred at AI control. Possible
    > reasons: NI-DAQ LV no interrupt level is available for use.
    >
    > How can I run out of interrupts while accessing my DAQPad? Does
    > the community have troubleshooting suggestions?

  • LV 8.21: strange behavior with DAQ tasks, parallel running VI's and shift registers

    Hello,
    I have made a VI using DAQmx vi's. The VI uses shift registers to store DAQ tasks and other (internal) information. I have implemented  several modes of operation (enum control with a case structure) like 'init', 'read AD', 'config AD' etc. If I use this multi mode VI in a single main VI everything work as expected. I have attached a jpg that shows one example where the DAQ VI is called from 2 parallel running while loops. One loop aquires the data (LOOP 1) while the other loop configures the aquisition task (LOOP 2). If I implement the same thing by putting LOOP2 in a different VI that runs seperately from the first VI I get an error message (200428):
    Possible reason(s):
    Measurements: Value passed to the Task/Channels In control is invalid.
    The value must refer to a valid task or valid virtual channels.
    Task Name: EasyDAQ_AD
    Of course, the second VI is started manually after the 1. VI has passed the initialization part. The error message is triggered from the 1. VI that executes the DAQ task. From my understanding of the LV execution system this seems like a bug to me. Does anyone have an idea what could go wrong here?
    klaus
    Attachments:
    problem.jpg ‏30 KB

    1. In general, this kind of technique is something I've been using successfully for years.  (Ben recently wrote up a very nice treatment of these "Action Engines" as a "Community Nugget.")  So I don't start by expecting this to be a bug in the LV execution system.
    2. Your description of the problem sounds almost backwards.  You say you manually start the 2nd vi ("Config AD") *after* running the 1st vi ("Read AD").  Seems like you'd need to do the Config 1st and then do the Read, right?   I kinda suspect you actually did it in the right order, but described it wrong.
    3. The next likely scenario is that the Config failed, but you didn't trap the error and were unaware of it.  Then it makes sense that the Read would also fail.
    4. A couple issues I regularly deal with in these DAQ Action Engines is internal error handling.  I often keep a shift register inside to store errors generated inside the Action Engine.  But it can get a little tricky doing sensible things with both the internal error and any other error being wired in as input.
    I said all that so I can say this: if you have complex nested case statements, or lots of different action cases to handle, double check that the task wire makes it from all the way from left shift register to right.  Sometimes they get lost if they go through a case statement, the output tunnel is set to "use default if unwired", and 1 or more of the cases don't wire the output.
    -Kevin P.

  • DAQ task update during running task

    Hi,
    I hope sombody can answer this question.
    Is it possible to update a running DAQ task without stopping the task?
    In my task I have an analog output and I want to change the amplitude and/or the duty cycle of the output waveform.
    Stopping the task and starting again with new parameters needs to much time.
    Thank you,
    Robert

    If you're just looking to write new data to the task then there shouldn't be any need to restart it (you can use AO with non-regeneration like DianeS mentioned).  I wanted to make sure to mention that we have an online example that does just this:
    Update Multiple Channels of Analog Output On-The-Fly
    Additionally, there are some properties that are settable while the task is still running (e.g. AO Sample Rate can actually be changed on-the-fly on many of our Multifunction Boards).  Other properties (e.g. AO Voltage Range) cannot be modified without first stopping the task.  If you need to stop the task and reconfigure, Ben's method is a good idea.  I am aware of an example that does this for Analog Input tasks but I don't think we have one for AO.  Here's the link to an AI version in case anybody is interested (unlike AO, the AI Sample Clock is not changeable on-the-fly):
    Switching Between Multiple Analog Input Tasks in DAQmx
    From what it sounds like, the first link should be exactly what you need and you shouldn't need to worry about restarting your task.  Just add Duty Cycle to the control cluster and wire it into the
    correspnding input of the Basic Function Generator.  If you have any questions about it or run into any issues don't hesitate to let us know!
    Best Regards,
    Message Edited by John P on 03-25-2010 06:35 PM
    Message Edited by John P on 03-25-2010 06:36 PM
    John Passiak

Maybe you are looking for

  • Need certain LED's to turn on when program is run

    Guys, Attached is an instrument .vi that I have been working on.  I was wondering if someone could open it and make the following changes.  I need the following things to turn on when the program is run: 2nd LED of the "Wheel" Button 3rd LED of the "

  • Someone pulled the CF out of my 4402. How to Restore?

    So one of our 4402's we had laying around that wouldn't boot and I found that the CF card got yanked.  I put a 32MB Cisco branded CF card just for kicks to see if the controller would recognize it, and it did.  However; I have no idea how to load the

  • When opening the Firefox the screen shows only a fragment of it

    When I open the browser instead of the complete home page I see a fraction of it and need to reload a couple of times to finally see the complete home page . This only happens with Firefox as browser. I also find it crashes often if I open a few site

  • Middle click on search suggestions in Search Bar does not switch to new tab

    I use profile option "When I open a link in a new tab, switch to it immediately" = yes (check marked) Middle clicking on a search suggestion in the Search Bar does open a new tab but Firefox does not switch to it. This feature used to work for many y

  • BW and oracle

    Hi everybody, I always use BW in his more simple functionnalities, like flat file sources or R/3 sources. SO I have e question, Can we connect BW directly to an Oracle Database system ? Is it able to query some oracles tables and filled a datasource