Error-200284 with DAQmx

Hello,
I am trying to make a continuous reading of analogvoltage signal with DAQPad-6015/6016 using sampling rate of 1000 and number of sample=1000 but the DAQmx is showing 
Error-200284 saying that the some or all samples requested have not yet been acquired.
The vi is attached and the images showing the settings of the DAQmx,error mesaage are also attached.
Can I know to solve this error.
Thanks.
Solved!
Go to Solution.
Attachments:
DAQmx_settings.JPG ‏113 KB
DAQ_method2_error.JPG ‏101 KB
DAQ_method2.vi ‏22 KB

John_P1 thanks for your suggestion.
I will explain a bit clearly of what I am trying to do
I am trying to use an example vi for adaptive filtering using least mean square but I am confused in modifying the example as per my requirements of
1)for the first 1 sec acquired samples I want to filter this signal and want to feed this filtered signal as reference signal d(n) and acquired signal as x(n) to adaptive filtering block
2)After first 1 sec the adaptive filtering vi produces two outputs e(n) and d'(n) .In which the e(n) should be feeded back as input d(n) to the adaptive filtering block and d'(n) is my filtered(required) signal
This feeding of acquired signal for 1 sec interval as x(n) and the previous noise reference=e(n) as other input as d(n) to the adaptive filtering block should be a continuous process.
can you help me out in modifying the example vi of filtering as per my requirements.
Attachments:
LMS block by block (example).zip ‏76 KB

Similar Messages

  • What is error 200284 with counting ticks?

    Hi,
    I am trying to write a VI that will count ticks of a rotating encoder wheel. I was able to run the test panel in MAX and count total ticks during rotation with no problem.
    Next, I tried writing a VI that would do the same, but, I am getting errors that I do not understand, especially,  " 200284, Some or all of the samples requested have not yet been acquired."  It also tells me to supply an external clock...how do you do that, and how do you know which external clock is the correct one?  I tried many clock options, but, continue to get this error...
    Ultimately, I would like to have a VI that counts ticks per unit time, e.g. ticks/100ms etc.  For now, I am trying just to get it to count total ticks, and I am stuck here.  Really stuck.
    I am using cDAQ 9174 and NI 9401.
    Thanks!!!  Please help!!!
    Dave
    Attachments:
    forum_april_11.vi ‏21 KB

    Hi dav2010,
    An explanation of error -200284 can be found here. Furthermore, I would recommend starting from a shipping example, when developing your counter measurement task. Lastly, the NI cDAQ-917x User Manual contains information about the various counter input applications, starting on page 5-3.
    The default sample mode for the DAQmx Timing.vi is Finite. The sample clock for the counter task(s) may be set to Continuous but if the sample clock is not set to Continuous it is set to the default value (Finite). When the sample clock is set to finite without the samples per channel wired, it will set a default buffer size based on the rate. Once the buffer is full the sample clock stops and the counter task stops latching the counts because the clock source has stopped. The counter task(s) which are set to continuous will continue expecting more clock edges but will timeout giving error 200284 when it doesn't receive any more. Setting the sample clock source to Continuous will allow the clock to continue providing clock edges for the buffered counting task(s).
    Tunde S.
    Applications Engineer
    National Instruments

  • Error 200220 with DAQmx

    I am trying to use a NI USB 6210 device with NI-DAQmx.  My application gets:
    Error -200220 occurred at DAQmx Create Channel (CO-Pulse Generation-Frequency).vi:1
    Possible reason(s):
    Device identifier is invalid.
    Device Specified: Dev2
    Task Name: _unnamedTask<1>
    How can I fix this?
    P.S.:I have not that much experience with this platform.
    Best regards,
    Ana Almeida
    Solved!
    Go to Solution.

    KA007 wrote:
    Error -200220 occurred at DAQmx Create Channel (AI-Voltage-Custom with Excitation).vi:2
    Possible reason(s):
    Device identifier is invalid.
    Device Specified: SCC1Mod1
    Task Name: _unnamedTask<1>
    Have changed the device name to "SCC1MOD1" but when tried to run the program again after changing the name it gave this error message (
    Error -200478 occurred at DAQmx Read (Analog 1D DBL NChan 1Samp).vi:2
    Possible reason(s):
    Device identifier is invalid.
    Device Specified: SCC1Mod2
    Task Name: _unnamedTask<3>
    Please help.
    Are you sure about the error message as error code -200478 says "Specified operation cannot be performed when there are no channels in the task."
    If you're getting the above error message (error source), then:
    Have you changed the name to "SCC1Mod2" but you are refering to other device named "SCC1Mod1"??
    I am not allergic to Kudos, in fact I love Kudos.
     Make your LabVIEW experience more CONVENIENT.

  • Error 200278 and error 200279 with DAQmx read

    Good day everyone,
    I have been trying to write a code which generates a sine wave and a trigger signal and send them out to two different devices. I am trying to phase lock device-1 on a certain phase angle of the operating signal  (sine wave) of the device-2.
    The device-1 which receives the trigger signal also generates a trigger signal at the same time it receives the trigger. It also can not work with trigger signal with a frequency which is greater than 4 Hz.
    I got that part to work and then I realized that I need to make sure that the responses of the devices have the same phase difference. So I added another part to the code which reads the trigger signal generated from the device-1 and the sine wave generated by the code (which basically goes to the device-2).
    I did not have any loop in the code at the beginning, and I just set the sampling frequency and sample rate and I though that it would work at the rate which I want. Unfortunately it did not. So I added a while loop to control the speed of the writing and reading process, and slow it down to 4Hz which is the limit of device-1.
    I have tried the reading process with finite sample and continuous sample on the sample clock and I got Error 200278 and Error 200279 correspondingly. Attached please see the main VI and subVIs. There are some subVis for writing data to the file which are not attached.
    I really appreciate it if you can help me to solve this problem and get the code to work in a way that the whole process works at 4 Hz frequency.
    I am not sure if my code is completely optimized. Any suggestion to optimize the speed of the code and the way it acquires data is also highly appreciated.
    Regards,
    Pooya
    Attachments:
    Trigger_Seq_R1.vi ‏115 KB
    time.vi ‏23 KB
    wavegen.vi ‏33 KB

    Hello Pooya,
    You need to add some wait delay in your while loop. Try adding a Wait Until Next Millisecond Multiple to your while loop with a constant wired in.
    You are acquiring data too quickly. Here is a link that discusses this in general.
    Regards,
    Jeff L.
    Applications Engineer | National Instruments

  • LV7.1 executeable built on Daqmx8 does not run on target PC with daqmx 7.2/7.4

    I have recently upgraded my development PC to Labview 8, RT and FPGA. This comes with DAQmx 8.0.0f0.
    I needed to make a new release of an application still running  LV7.1 and either DAQmx 7.2 or 7.4. The new build works fine on my PC but running the executeable on the target machine  there are many errors associated with DAQmx library files not being compatible. I have checked the file paths in the 7.1 and they all point to the standard labview 7.1\vi.lib\daqmx librarys, and I don't think the vi names have changed.
    I don't think it is the application builder as it seems to be the same as always. (7.1)
    The target PCs are in factories around Europe and are upgraded by modem link.  I have always found it very difficult to upgrade DAQmx remotely and don't try it unless on site.
    Quick solution is to build on a 7.1 workstation and run time then works, so the code is OK.
    Are there any settings in the application builder or elsewhere that would help?
    Has anybody else found problems upgrading to 8? Generally its good, especially with RT and FPGA toolkits.
    Lucy

    Hi Lucy
    As you are now using LabVIEW 8 any executable which includes NI-DAQmx 8 will require LV 8 runtime engine and DAQmx 8. What you can do is build an installer that goes with the executable witch contains the LabVIEW 8 runtime engine (default) and DAQmx 8 selected under additional installers. If you run this before your exe it will update the DAQmx drivers to version 8 and MAX to version 4. You will then be able to run your exe files.
    I built an exe and an installer using LabVIEW 8 and ran it on a machine with LabVIEW 7.1. The installer updated every thing easily. The only problem is that as the installer contains DAQmx 8 it is about 460meg which might be a problem as you are doing this remotely the only thing I can suggest is using an FTP server or getting your customers to down load DAQmx 8 of our website
    This is the link for NI-DAQmx Version 8.0 for Windows 2000/NT/XP
    http://digital.ni.com/softlib.nsf/websearch/4C9E45F6EE5C29F98625708900712CBC?opendocument&node=13206...
    Hope this helps
    Tim
    NI UK AE

  • Error 200284 keep showing up with DAQmx/USB6259

    This error of 200284 has been persistantly showing up in my high speed data acqusition using DAQmx Read with USB6259 running LV8.5.1 and DAQmx 8.7.1.  I tried most of the approaches discussed on this forrum regarding this error such as increasing time out and sample rate, but still getting it. I stripped down the application that I recently took over and attached the basic vi..please voice any suggestions, thoughts, solutions, and comments, I really would like to see this code work out as it is our basic stuff.  many thanks in advance. 
    A little more detail...the original code (and this striped down version) would run for a minute or so with the loop index getting to over 20k, or 40k..but most likely stop before 60k with unpredictable numbers...thanks again for taking a look at the vi.
    Bryan 
    Message Edited by BryanL on 02-15-2009 02:26 PM
    Attachments:
    SampleVI.vi ‏75 KB

    Hi Doug,
    First thank you so much for the help and support.  I went to restart the NI variable engine and disabled the ZoneAlarm and firmwall, the variable engin now runs and not stopped, but the VI still stopps with the error 200284. Anythings else you think might be the issue here?  I really need to get this thing working as I have been on it for a few days now...please help.  Thanks again.  I have also copy and paste my post and that of Dansch here to give more background info:
    Hi Dansch,
    Thank you for looking into this issue!  I have compiled a reply to your comments and questions in the following quoted message: 
    dansch wrote:
    Hi Bryan,
    I
    took a look at your code, and after modifying the analog output
    channel, I was able to run it fine for a very long time on a PCI-6251
    board without any errors.
    Our
    original code also runs ok with our PCI boards, only after we switch to
    USB then we have this problem of error 200284 stopping the acquisition.
    The code also runs ok on one laptop with older USB (XP service pack 1),
    the two laptops with newer USB2.0 always have problems with error
    200284 on one and 200279 on the other(XP Service Pack 3).  I am trying
    to get the one with 200284 to work.
    One
    thing that I am interested in is the analog output task that you are
    referencing, since I am unable to see what type of setup you have
    configured for this channel. I am interested in knowing why the analog
    input task is using the ao/sampleclock as the source for its sample
    clock rather than the other way around (ao channel using the
    ai/sampleclock).
    The
    was not clear about the logic of the triggering setup of the
    initialization step, however, the analog output task used the task
    input setup from MAX, this also triggers the timing on the analog
    input.  The output chain is for running a light source with a wave form
    generated by a separated VI using the waveform parameters as shown on
    the front panel of my attached SampleVI.  This source runs
    continuesouly with the same waveform  function.  The input chain reads
    a detector contineously as DAQmx Read was put into the while loop. The
    start of the output waveform was triggered by the input chain so that
    the light source and data acquisition are synchronized.   We never had
    problem to start the data acquisition as we always read the correct
    waveform back.  The error seem to alway came from the DAQmx Read
    function in the while loop as the code on the left side of the while
    loop onlys runs once, while the while loop will keeping running, until
    it stops a minute or so later by the error 200284.
    Usually,
    when this type of -200284 error occurs, it is due to a problem with not
    receiving a trigger or sample clock edges. Perhaps something is
    happening to the analog output task that is affecting the analog input
    channel since it is using the ao/sampleclock.
    I will check further on the output task setup in MAX..if this is the issue, what is the recommended setup for the output task? 
    A
    couple of other things I would like to know more about are why you are
    reading just a single sample each loop iteration and also what your
    application involves since I noticed the program samples numerous times
    on the first channel for each single sample on the others. What overall
    rate are you trying to accomplish as well? Please let me know if you
    have any additional insight into your application. Regards,
    I
    was only reading a single sample for the demo purpose as it generates
    similar error as in the original application where we read all
    channels. The first channel is where the detector response are read and
    are accessed at the highest frequency.  That is why we build 992
    instances for this channel and leave the other 8 channels to read some
    other environmental parameters which happens at a less frequent time.
    This allows us to keep data acquisition going without restart other
    tasks. This was recommended by an NI engineer earlier to another
    enginer here and was work fine. 
    The following are some of our input parameters:
    On
    the Outuput side:  Waveform Scan Rate or Frequency (Hz): 1000    Number
    of Points in Waveform is 1000,  Waveform Update Rate is: 1000000/s,
    this final rate goes to output timing VI 
    On
    the Input side:      Number of Sample Spectrum (total numb. of
    channels) 1000.  Number slow channels: 8.   Input sample rate:
    1000000(Hz). This rate/1000=1000/s goes to the input timing VI 
    Please
    let me know if you need more info, if you do not mind, could you please
    send me a number and best time to call?  Many thanks.
    Bryan

  • DAQmx error 200452 with PCI6024E

    I successfully tested my Application with DAQmx and the PCI 6221 (LV 7.1, WinXP). I tried the same Appllication with the (legacy) PCI6024E which should be compatible to DAQmx regarding the NI compatibility list. After starting the App. the following error message appears: 200452 occured at DAQmx Channel(arg1).Possible reason: specified property is not supported by the device or is not applicable to the task. Property CI.DupCountPrevention. ChannelNameDev1/ctr0. When I delete this property all seems to be fine.
    Jörn HeitlandMessage Edited by JoernHeitland on 04-20-2005 07:24 AM

    Duplicate count prevention is not supported by E Series devices. You should not need this property when running on an E Series device.
    I hope this helps!
    gus....

  • How to solve the error "The specified resource is reserved" when running with DAQmx And LabVIEW?

    How to solve the error "The specified resource is reserved" when running with DAQmx And LabVIEW?

    I hate "J term"
    OK I love the learning the students get.   And, I like helping them out!  But, as a former man who's got the varicose viens to prove he's spent time "behind the podium" (yeah, "behind the podium" puts 'em to sleep- songs and dances for the young'uns) come on! USE the tools you teach!
    Instructors invited to engage in the forums
    Jeff

  • Error when starting an analog read task with DAQmx 8.5 while 8.0 works

    I am programing a measurement application with Borland C++ Builder 6.
    Problem: Every time when I try to start an analog input task with the DAQmxStartTask() command of DAQmx 8.5 the program execution is interrupted and the error message "Invalid floating point operation" is given out. This problem does not occur with DAQmx 8.0 !

    Hello Johannes,
    the error occurs every time, when I try to start an analog voltage input task either with a simulated or a real device (PXI-4472). Changing any of the measurement parameters did not have any effect. I also tried one of the C-source code examples, which came with the original NI-documentation of the DAQmx 8.5 driver, resulting also in the same error.
    However, starting a counter task with a simulated PXI-6601 device worked without any problems !
    Do you have any ideas ?
    Regards,
    Thomas

  • Error -200141 when doing buffered events with DAQmx and PCI-6602

    When doing buffered events with DAQmx and PCI-6602 I get error 200141 - Data was overwritten before it could be read by the system.
    This error is generated ONLY with random inputs >200/sec.
    My setup is :
    DAQmxCreateCIVCountEdges(taskhandle,"Dev1/ctr3"....
    DAQmxCG+FGSampClkTiming(taskhandle,"/Dev1/FPI35",...
    DAQmxSetCICountEgdesChan(taskhandlem,"", "/Dev1/80MHZTimeBase")
    DAQmxSetChanAttribute(taskhandlw,",",DAQmx_CI_DataXferMech,DAQmx_Val_DMA,0);
    Can somebody help ?

    i'm getting the same Error-200141, while reading semiperiods. (Meas_Buffered semiperiod continous)
    while loop ex.rate seems to be pulsewidth*no.Samples to read. in my case PW=60ms
    Input buffer size measured with Property node= 10000
    why this error happens?? i cant use any mode other than implicit timing for semi-period measurement right??
    more info: all the ai channels are used ~ 16 differencial.
    i found one solution which is _ reinitializing the whole task if an error occur. is this the right way??
    Kudos always welcome for helpful posts
    Attachments:
    Counter_1_Meas Buffered Semi-Period-Continuous_main_lv09.vi ‏34 KB
    SemiPeriod_Reconnect Counter on Error.vi ‏35 KB

  • An issue with DAQmx Error messages

    Greetings,
    I'm using a 6602 counter board with DAQmx 7.4, ANSI C API.  A strange issue concerning the errors due to faulty attribute values keeps occuring, that being no error is reported when the (faulty) attribute value is set but only when it is read back afterwards.  Shouldn't the faulty value be reported by the Set function?
    To be specific, I'm creating a period measurement counter input channel with implicit timing, sample mode = finite, then setting the number of samples per channel to 0 (bear with me, I know the 0 value makes no sense here, the point is how the errors are being reported so that they can be handled in a reliable and consistent way).  While DAQmxSetSampQuantSampPerChan(taskHandle, 0) does not produce an error, calling DAQmxGetSampQuantSampPerChan(taskHandle, &SampPerChan) for verification on the very next line returns Error -200077 : "Requested value is not a supported value for this property".  So, my question is why the error is reported by the Getter instead of the Setter?  Is this normal behavior (if so why?) or is something amiss here?
    Jeff

    This is the expected behavior. Validating attributes is tricky when attributes are dependent upon other attributes. There are two main approaches that can be taken by NI-DAQmx.
    One, when every attribute is set, NI-DAQmx could verify the value of that attribute in the context of the task (i.e., in the context of all other attributes). This is problematic for at least a couple of reasons. One, validating the task after every attribute is set is time consuming and not efficient. Two, validating the task after every attribute is set requires that customers set attributes in a specific order such that dependent attributes are set after their dependencies. This would dramatically decrease the usability of NI-DAQmx. In fact, if attributes are mutually dependent, this approach is impossible.
    The second approach is that NI-DAQmx doesn't verify the task until it is forced to do so. Starting a task forces it to be validated. Querying an attribute also forces the task to be verified since the value of an attribute may be dependent upon the value of another attribute.
    As you've noticed, we've taken the second approach with NI-DAQmx. This approach leads to a more efficient execution as well as allow customers to set attributes in an arbitrary order. If you want to force the task to be verified in order to check for errors, you can do so explicitly at the desired time. However, the need to check attributes for errors is most often needed when the application is under development and the NI-DAQmx error reporting features makes it easy to determine which attribute has been set to an invalid value even when that error is not reported immediately.
    Now, in reality, the way NI-DAQmx handles attributes is a bit more complicated than what I just described. Since some attributes are not dependent on other attributes or, since some attribute values can never be valid regardless of the values of other attributes, these attributes are verified when they are set and errors are returned immediately. We refer to this as coarse attribute verification. For example, if you set the sample rate to 100 MHz on an E-Series device you will immediately get an error.
    Hope this helps clarify the behavior.
    geoff
    Geoffrey Schmit
    Fermi National Accelerator Laborary

  • I got Internal Software Error -223044 with my PXI-4472, PXI-1033 and NI expresscar​d-8360 DaqMx 8.8

    When i running the self test of the board in MAX i got error -223044, anyone that has some ideas?? 
    STALT

    Hey Stalt,
    This particular internal error begs me ask a few questions.
    1) Has this 4472 ever been used with DAQmx?
    2) How old is this 4472?  When was it bought from NI?  Can you give me the revision letter of the board?  That is found by looking for a number printed on the board that usually begins with "ASSY", then there are several other numbers/letters, but the one letter I care about is the letter right before the "-"  So it would look like ASSY11111111E-01 so the revision would be "E"
    3) Do you have another PXI system (with DAQmx) that you can initialize this 4472 in? 
    Let me know
    -gaving
    Software Engineer
    National Instruments 

  • Error -200284, Behaviour in Execution Highlighting and Runtime Speed

    Hi
    I am having trouble with the attached VI.
    This VI reads a voltage on ai26 and it works fine if
    1) the wait in the flat sequence is 2000 milliseconds or more and execution highlighting is turned off
    or
    2) the wait in the flat sequence is zero or more and execution highlighting is turned on.
    LV reports error -200284 if I try executing 2) at runtime speed (execution highlighting turned off, wait=0). Is there a solution to change the VI in a way that the use of a wait is not necessary?
    I already checked the LV examples and it seems that the examples (on my hardware) suffer the same problem.
    Description of my task:
    I need to sample the voltage at 2000 Samples/sec. Signal observation must be 5 sec, that makes 10000 Samples in the end. No trigger needed. The USB-6259 has a buffer of length 4095 but this is not my problem since I will be doing the acquisition (with 2000 sample chunks) in the producer- and the analysis in the consumer-loop.
    My Hardware:
    I am using USB-6259, LV 8.2 and DAQmx 8.6 on a Windows 2000 Machine.
    Best regards
    Thomas
    Attachments:
    Read Analog Wfm.vi ‏34 KB

    In the attachment is the corrected VI without a wait.
    If I run this corrected VI at runtime speed, I get error -200284.
    If I place a breakpoint between the DAQmx Start and Read Task and run this VI (I will have to push the Continue-Button for the VI to finish), there will be no error.
    Why that behaviour?
    Thomas
    Attachments:
    Read Analog Wfm Correct.vi ‏32 KB

  • Please help me on error -200284 for usb6008 data A/D

    Hi,
    I am working on the A/D using usb6008, I program in visual c++.  I create a dialog to test the function of sample program: contAcquireNChan.c               in  NI-DAQmx Base.  I just changed the mode to DAQmx_Val_FiniteSamps and each time I just want to get several data. I used a button to start the a/d. The following is the code. The problem is very strange that while I click the start button for the sixth time, this error -200284 will occur when calling this function:
     DAQmxErrChk (DAQmxBaseReadAnalogF64taskHandle,pointsToRead,timeout,DAQmx_Val_GroupByScanNumber,data,2,&pointsRead,NULL));
    The discription of this error is:
    "Some or all of the samples requested have not yet been acquired.
    To wait for the samples to become available use a longer read timeout or read later in your program. To make the samples available sooner, increase the sample rate."
    I do not know what happened. And how to solve this problem. Please help me.
    The following is the code:
    void CBTTest001Dlg:nStart()
       // Task parameters
        int32       error = 0;
        TaskHandle  taskHandle = 0;
        char        errBuff[2048]={'\0'};
        time_t      startTime;
        bool32      done=0;
        // Channel parameters
        char        chan[] = "Dev1/ai0";
        float64     min = -10.0;
        float64     max = 10.0;
        // Timing parameters
        char        clockSource[] = "OnboardClock";
        uInt64      samplesPerChan = 2;
        float64     sampleRate = 2000.0;
        // Data read parameters
        #define     bufferSize (uInt32)1000
        float64     data[bufferSize * 5];
        int32       pointsToRead = bufferSize;
        int32       pointsRead;
        float64     timeout = 10.0;
        int32       totalRead = 0;
     index++;
     if(index==6)
        int a =0;
     m_bWorkFlag = true; 
      double a1= data[0];
      double a2= data[1];
      double a3= data[2];
      double a4= data[3];
      DAQmxErrChk (DAQmxBaseCreateTask("",&taskHandle));
      DAQmxErrChk (DAQmxBaseCreateAIVoltageChan(taskHandle,chan,"",DAQmx_Val_RSE,min,max,DAQmx_Val_Volts,NULL));
      DAQmxErrChk (DAQmxBaseCfgSampClkTiming(taskHandle,clockSource,sampleRate,DAQmx_Val_Rising,DAQmx_Val_FiniteSamps,samplesPerChan));
      DAQmxErrChk (DAQmxBaseCfgInputBuffer(taskHandle,2000)); //use a 100,000 sample DMA buffer
      DAQmxErrChk (DAQmxBaseStartTask(taskHandle));
      DAQmxErrChk (DAQmxBaseReadAnalogF64(taskHandle,pointsToRead,timeout,DAQmx_Val_GroupByScanNumber,data,2,&pointsRead,NULL));
     //    printf("\nAcquired %d total samples.\n",totalRead);
      m_fAnalog1 = data[0];
      m_fAnalog2 = data[1];
      m_fAnalog3 = data[2];
      m_fAnalog4 = data[3];
      m_fAnalog5 = data[4];
      UpdateData(false);
      if(taskHandle != 0) {
    //   DAQmxBaseStopTask (taskHandle);
       DAQmxBaseClearTask (taskHandle);
     return;
    Error:
        if( DAQmxFailed(error) )
            DAQmxBaseGetExtendedErrorInfo(errBuff,2048);
        if( DAQmxFailed(error) )
            printf("DAQmxBase Error: %s\n",errBuff);

    Dear Neal,
    Thank you so much !!
    "DAQmx Base was designed for use on operating systems other than Windows". Maybe that's the reason why I always met problems.  I am using windows now !! The only reason for me to use DAQmx Base is that it comes with the USB6008 device so that I think NI recommend to use it ! I also downloaded DAQmx from NI but I did not tried it (in fact it took me several hours to switch the firmware back to DAQmx Base ). I will try It now and tell you the result.
    "You say that you thought you solved the issue but did you not?"
    Yes.
    " Did you add the stop task function before and that is what you thought solved the issue? "
    Yes.
    I started from the example and do some modifications. First I met -200284 error and I found it is the caused by wrong number of data to be read. I changed to finite namber data read.
    Then I met sixth reading problem, at that time I use a button clicking to read the data.when I read for the sixth time, It will occur (I forgot the phenomena). I added a  stop task function and I thoought I solved the problem. I knew for a finite number data reading, stop function is not needed, but I do not have any other method so I tried it. "sixth reading problem" solved, but When I move the data reading function to ontimer function recently. The program will halt -- take 99% of CPU time after 30 second of reading (sometime several minutes, sometimes several seconds). If I move the start task back to OnInitialUpdate() function and cancel stop function, halt error will not occur but the data I read in not correct. That is the whole thing. The following is the code relative to the data read.
    Initialization;
    void Ctest2Dlg:nInitialUpdate()
       DAQmxErrChk (DAQmxBaseCreateTask("",&taskHandle));
      DAQmxErrChk (DAQmxBaseCreateAIVoltageChan(taskHandle,chan,"",DAQmx_Val_RSE,min,max,DAQmx_Val_Volts,NULL));
      DAQmxErrChk (DAQmxBaseCfgSampClkTiming(taskHandle,clockSource,sampleRate,DAQmx_Val_Rising,DAQmx_Val_ContSamps ,samplesPerChan));
    Data read
    void Ctest2Dlg:nTimer(UINT nIDEvent)
      if(taskHandle != 0)
         DAQmxErrChk (DAQmxBaseStartTask(taskHandle));
       DAQmxErrChk (DAQmxBaseReadAnalogF64(taskHandle,pointsToRead,timeout,DAQmx_Val_GroupByScanNumber,data,100,&pointsRead,NULL));
       DAQmxBaseStopTask (taskHandle);

  • Can read TEDS in MAX but not with DAQmx VIs

    Hi,
    I have a cdaq 9181 with a 9234 accelerometer module.  I have 3 teds equipped accelerometers connected to ai0, ai1, and ai2 repectively.  In MAX, when I reserve the chassis I can read all three teds, no errors.  When I do the same thing in labview (ie reserve the chassis, create a daqmx task, associate teds data with each physical channel, all with daqmx VIs) I can only read two out of three teds.  The third one throws a "no teds sensor detected" error.  This code has been in use for about four months now, though I just rewrote the calling VIs, and hasn't displayed this problem.  I've attached a snippet of the task building VI for reference.
    Any ideas what's going on?
    Thanks.
    Using LV2012 and MAX 5.3.1 running on Windows 7 32 bit.
    CLAD
    Attachments:
    Build Daq Task Snippet.png ‏58 KB

    Nope.  That's a delete from array, length 1, index 3.
    In any case, I eliminated that block since the string array wired to the for loop controls how many devices the VI attempts to configure.  Same result, verified it was trying to configure ai2.  Here's the updated snippet:
    CLAD
    Attachments:
    Build Daq Task Snippet v2.png ‏54 KB

Maybe you are looking for