Error -200279 with simultaneous analog input (different devices) and digital output.

Hi guys,
I am a beginner in Labview and have been dealing with this problem for a couple of weeks now and just can't seem to get it completely right, I have a feeling there are a few small bugs in my code/hardware setup.
I am running an scxi-1000 chassis with a 1600 module and 1302C along with a 1303 accesory for temperature measurements, this is connected to four thermoucouples. Unfortunately I have a limited number of modules available so I am also using a PCI-6221 DAQ card with an scb-68 breakout box used for a digital output and analog input voltage channel. Attached is my labview program. When I run the code at a 50 Hz sampling rate it runs with no errors but the data file comes out extremely wrong, this is also attached. When I run the code at 100 Hz I get error-200279 after a few loops. I used to have 2 daqmx timing VIs (one for each input), but the same error would eventually happen, I have also tried increasing the buffer size on said timing VI. I am also using an old computer (Pentium IV) could this effect the program?
I have learned a lot going through forms for similar problems to mine but I just can't get it to for an extended period of time, I have posted my simplest code.
Thanks in advance,
Luca
Attachments:
tc_2.txt ‏1102 KB
FinalCombined_2.vi ‏128 KB

Ok this makes sense. I have made the suggested modifications but still getting the same error with sampling rates of 100 Hz or higher. Could you check that I have implemented the queue VIs properly (new file attached)? Also when running at 50 Hz in debug mode it does not look like the second while loop (with the dequeue element) comes into play until I hit the stop button, once I hit the stop button I get the following error:
Error 1 occurred at Dequeue Element in FinalCombined_2.vi
Possible reason(s):
LabVIEW: An input parameter is invalid. For example if the input is a path, the path might contain a character not allowed by the OS such as ? or @.
=========================
NI-488: Command requires GPIB Controller to be Controller-In-Charge.
This leads me to believe I have programmed the queue elements incorrectly.
Thanks for your help, any suggestions are greatly appreciated.
Luca
Attachments:
FinalCombined_2.vi ‏102 KB

Similar Messages

  • Synchroniz​ing two counter frequency inputs with multiple analog inputs

    Hello all,
    I'm fairly new to LabVIEW and I'm trying to collec​t data from multiple sources with synchronized tim​ing on the acquisition but I'm having trouble figu​ring it out. My problem is that I've got two count​er frequency inputs, one optical tachometer readin​g one pulse per revolution, and a max machinery fl​ow meter with a k factor of 12000. I can't seem to​ figure out how to sync the timing with my multiple analog inputs. I've be​en attempting to get the tachometer  to sync with ​the analog inputs first by following the example l​inked here. (https://decibel.ni.com/content/docs/DOC-10785) So far each time I run it I either get a timeout e​rror on the DAQmx read or a "Multiple sample clock​ pulses were detected" error (see attached image).  It seems if I slow the sampling rate way down to ​say 10 hz and ensure that the tachometer signal is​ over 800-1000 RPM (13-17 Hz) before starting the VI then the program will run without errors until ​the RPM drops below that threshold then the "Multi​ple sample clock pulses" error occurs.  The code is attached below.
    Does anyone know of a more effective way of syncin​g counter frequency inputs with analog inputs?  I'd like to have a VI that can show 0 RPM (and ev​entually 0 flow as well, but I think I need to fig​ure out the timing of one counter before I add ano​ther as it seems I can't have two counters in the ​same task). Any help on this would be greatly appr​eciated.
    LabVIEW version 13.0
    cDAQ-9178 Chassis with NI 9401 for the two counter inputs and NI 9205 for the analog inputs.
    Thanks!
    Richard
    Solved!
    Go to Solution.
    Attachments:
    SimpleDAQ.vi ‏44 KB
    LV_Error.JPG ‏31 KB

    Maybe third times the charm? 
    So I've finally got a good handle on why the VI is having problems at low RPM though I'm somewhat embarassed how long it took me to do that
    Because I have the counter time synced to my Analog input task if it doesn't see at least two pulses between the two clock pulses set by the analog input task I get the -201314 "Multiple sample clock pulses" error. This seems fine at first as it just sets a minimum RPM that I can measure and it's well below the area I'm interested in so no problems there.  I tried a simple error handler that would clear the error when it happend assuming the loop would keep iterating until the RPM went above that minimum at which point I would get a signal again. This is not the case, the read function just continues to spit out the -201314 error even after the RPM is back in the readable range. So then I tried adding two case structures so that when the error occured it would stop the task, clear the error, and then start the task again on the next loop iteration (Code Attached). This also doesn't work as the error shows up again on the stop task and then AGAIN on the start task on the next loop iteration. It seems this error is not actually being cleared and once it happens it stays with the task regardless of what the error cluster is carrying. 
    Anyone have any ideas?  The only solution I can think of is to just clear all tasks and recreate them each loop iteration until the RPM is readable again but that strikes me as a horribly clunky solution.
    Richard 
    Attachments:
    SimpleDAQ_1_Start Stop.vi ‏48 KB

  • I have an airport express and want to know how to set up two different wireless networks. One with 5GHZ and one with 2.4GHZ so different devices can connect to either.

    I have an airport express and want to know how to set up two different wireless networks. One with 5GHZ and one with 2.4GHZ so different devices can connect to either. I have an iphone 4 that will not connect to 5ghz.
    thank you!

    Your AirPort Express is already providing two separate 2.4 GHz and 5 GHz bands, but each band is using the same wireless network name.
    This is the default setup for the AirPort Express, which is recommended for most users. The theory here is that devices will automatically connect to the best quality signal based on their capabilities and distance in relation to the AirPort Express.
    It is possible to assign a different name to the 5 GHz band, and then "point" devices at that network to connect. Some users swear by this option.....(I am not one of them).... but you might want to give it a try to see how it works for you.
    Open Macintosh HD > Applications > Utilities > AirPort Utility
    Click on the AirPort Express
    Click Edit in the smaller window that appears
    Click the Wireless tab at the top of the next window
    Click Wireless Options near the bottom of the next window
    Enter a check mark next to 5 GHz Name.....which will automatically add "5 GHz" to the network name....so you can identify it
    Click Save, then click Update and wait a full minute for the Express to restart
    Now you will need to "point" your 5 GHz capable devices at the 5 GHz network name.  2.4 GHz devices will connect to your "other" network name.

  • Digital input and digital output at the same time

    Hi all
    I have a PCI-6503 board. I have done 2 task that run simultaneously: the first one is port0_16 output and the second one is port2 input.
    I get sometimes (not every times...this is strange...) error-200587 saying:
    'Requested operation could not be performed, because the specified digital lines are either reserved or the device is not present in NI-DAQmx.
    It is possible that these lines are reserved by another task, the device is being used through the Traditional NI-DAQ interface, or the device is being reset. You might also get the error if the specified resource is currently in use by LabVIEW network variables bound to the DAQ Channel, or if the DAQ Channel is being used in any OPC Client software.
    If you are using these lines with another task, wait for the task to complete.  If you are using the device through the Traditional NI-DAQ interface, and you want to use it with NI-DAQmx, reset (initialize) the device using the Traditional NI-DAQ interface. If you are resetting the device, wait for the reset to finish.'
    In the attached VI i have recreated the basic structure of my real VI (the error is present even here of course...).
    How can i do?
    I want to have both digital input and digital output with the same PCI-6503 every single cycle... Is it possible?
    Please help me!!!
    Kind regards.
    I love the smell of napalm in the morning
    Attachments:
    DIO simultaneously error.vi ‏31 KB

    Hello Maverick,
    Did you have any luck with the example Raven sent you?
    In Raven's example, it properly passes the DAQmx task from one SubVI to another to avoid having to open the task again. These errors are likely to occur when you have multiple DAQmx calls in a VI that call the same task again without clearing the previously opened task. If at any given time you try to open a task that already is being used, you might receive an error "resource is reserved"... similar to your original example.
    If you are interested, here is an awesome link that gives a detailed explanation of the LabVIEW dataflow paradigm
    Learn 10 Functions in NI-DAQmx and Handle 80 Percent of Your Data Acquisition Applications
    Thanks and good luck!
    Jordan Randall
    National Instruments Italy

  • Need help with waveform and digital output

    Hey everyone,
    I am driving a rotational motor with an example waveform output VI and an example digital output VI. I am able to successfully send a square wave with the desired properties to rotate the motor and I am also able to successfully send a digital output (1 or 0) to change its direction (clockwise/couter-clockwise.
    However I need some advices to write a setup such that after the motor runs as desired, I can return the motor back to its original position. I think the simplest way is timing how long it takes to finish its task, and just change the digital output, keep the same wave properties and run for the same amount of time.
    So how can I time how long the program runs and with some kind of button, change the digital output and run the program again?

    As more of a program architecture tip, this sounds like a great time to be using a State Machine.  I say this because you mention resetting the motor (one state) then running it again (another state) repeatedly.  As a design tip, I would check out this article, along with the Design Pattern Template that comes with LabVIEW.  You can find this by going to File >> New... then expanding the tree to VI >> From Template >> Frameworks >> Design Patterns >> Standard State Machine.
    Cheers, 
    Brian A.
    National Instruments
    Applications Engineer

  • Error 10800 while testing analog input PCI-4451

    I'm testing the PCI 4451 device under Windows 2000 and with NI-DAQ 6.9.2 (with Max 2.2 french version)
    The analog output work properly but the input doesn't seem to work. I have tested with a GBF. I have also tested by connecting directly the analog output on the analog input and generating a 50KHz signal at 5V but it doesn't work. It always return an error 10800 (timeOutError). I haven't select any trigger. It display a graph with 1 or 2 peak an the beginning but all others samples have the value 0 in the graph. So the graph seems like a constant value of zero exepts the 1 or 2 peak.
    I've tried a lot of combinaison and nothing work. :-(
    configuration of the NI PCI-4451 :
    IRQ : 19
    DMA : 0, 1 and 2
    AI : +/- 10V
    differential
    AO : bipolar
    Accessory : BNC-2140
    PS : I've translated from french so there could have some mistakes.
    Is there anyone who have an idea ? (or others tests I can do ?)
    pcb

    Vous adoptez la bonne demarche - Si la carte ne "repond" pas dans MAX, ce n'est pas la peine d'aller plus loin.
    Ce que je vous conseillerais de faire :
    1- Aller dans le panneau "proprietes" et choisissez "tester les ressources" - cela vous permettra de savoir si la carte repond aux commandes du driver.
    2-Si oui, lancer les panneaux de tests et generer un signal de 1 khz avec un GBF (en gardant la frequence d'echantilloonnage par defaut de 51200S/s)
    Si vous obtenez un warning "10800", essayez de fermer le panneau de test (cela va envoyer une commande de "reset" a la carte puis relancer le panneau de test immediatemment apres)
    Le seul cas de figure ou j'ai pu rencontre ce comportement etait apres avoir synchronise plusieurs car
    tes 4451 - Les lignes des cartes "esclaves" n'ayant pas ete remises a zero apres coup.
    Je doute toutefois que vous soyez dans ce cas de figure.
    2bis- Si le panneau "tester les ressources" vous renvoie une erreur, cela signifie que la carte ne recoit pas les commandes du driver.
    Le plus simple dans ce cas etant probablement d'eteindre votre PC et de placer la carte dans un emplacement PCI different. Au redemarrage, de nouvelles ressources seront affectees a la carte et cela permettra eventuellement d'eliminer les conflits potentiels.
    Si aucune de ces deux methodes ne vous apporte un resultat, je crains que vous ne deviez contacter votre agence National Instruments pour proceder a un remplacement de cette carte.
    J'espere que ces informations vous seront utiles.
    Gerald

  • 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

  • Synchroniz​e hardware timed buffered counter acquisitio​n with buffered analog input acquisitio​n

    LV7.1
    DAQmx
    PCI-6036E
    SC-2345
    Windows 2000
    Greetings.
    I am simply trying to synchronize AI readings with readings from one Counter.
    I am trying to perform buffered analog input synchronized with buffered counter acquisition.
    I'd like the AI acquistion to trigger the Counter acquistion.
    I'm currently setting the Sample Clock Source for the CI Cnt Edges Task to "Dev1/ai/SampleClock" but when I try and set the source for the "DAQmx Trigger" I can't seem to select one that works. I assumed that the source should be the "Dev1/ai/StartTrigger" but that produces and error as does selecting any of the PFI's.
    I'm new to DAQmx and didn't have any luck with the examples or what's been previously posted.
    Thanks for your help.
    Attachments:
    Initialization.jpg ‏84 KB

    Gentlemen-
    All of your initial help was great. I had some noise on my counter lines so switched from an E-Series card to a PCI-6259 M-series card in order to use the counter digital filters.
    Now I can't get a corellated buffered counter and buffered analog input acquistion to work. This same code worked fine on an E-series card but it doesn't on the M-series.
    I verified that the source and gate of the counter are working properly using the test panel and a external function generator.
    But when I run the attached code I get no data out of the "Counter 1D U32 NSamples", only an error saying that the timeout of the function was reached and no count data became available. Am I missing the specification of a another clock or something?
    The counters also work fine using the M-series example code "Count Digital Events (M-Series DAQmx) but this is not a buffered acquisition.
    Any help would be greatly appreciated.
    Steve
    Attachments:
    Sample_Code.jpg ‏136 KB

  • How to trigger a TTL output with an analog input

    Hello,
    I have an apparatus for measuring the flame speed of various hydrocarbon/air mixtures.  The chamber uses central ignition as the means for igniting the mixture.  My goal is to film the ignition process with a high speed Phantom video camera.  I control the ignition with an analog output signal from a SCC-68 DAQ.  I would like to trigger the camera with the same signal that triggers the ignition sequence.  The camera is triggered with one TTL pulse so ideally I would connect the output analog voltage signal to an input analog voltage port that would be used to trigger a counter output that generates one pulse.
    I have a sample VI that triggers a digital pulse each time the analog trigger level is met and it works for what I am trying to do but I do not understand how the two channels are connected. I also can't figure out how to make the VI end after just one pulse.  In the VI the digital counter is supposedly triggered using the /Dev1/ai/StartTrigger slot on the DAQ but nothing is connected to this slot.
    I need to first figure out how to make the output_pulses_on_sine_wave.vi terminate after a single pulse is generated. Then I can try to incorporate it into the VI that I use to control the ignition and measure the temperature and pressure once the mixture is ignited.
    John
    Attachments:
    output_pulses_on_sine_wave.vi ‏27 KB

    I am using the USB-6259, sorry for the confusion.  I would be nice if I could trigger with an analog signal to the ignition system but it is controlled with a high voltage relay that operates when 12 volts are supplied to it. It really isn't a trigger as much as powering on the high voltage relay. To control it, I have a 12 V supply line that is switched closed using a SCC-RLY module.  Could I somehow connect the 12 V supply to one of the buses and use a digital trigger to supply the 12V on command to the high voltage relay?
    Thanks for the quick response. 

  • Problem with the analog input acquisition in labview fpga 8.5.1 and CRIO

     Hello all,
       I am using NI CRIO 9104 RT controller with 9014 FPGA chassis.I am using an Analog input module 9205.My problem is with the acquisition.I am using a
    function generator which generates some sine wave of -1 to 1 ,5hz to125khz sine signal and i have connected to 9205 in rse mode.In FPGA vi i had placed the I/O node and placed an indicator(data type FXP).If i connect the i/o node to a chart or graph,i am not able to see the output.?How this problem can bbe solved
    Next i had placed a FIFO in DMA transfer mode of depth 1023 which will accept the U32 datatype,so i did some manipulation as mentioned in a tutorial.
    Now in RT VI i am reading the same data from the buffer in U32 and doing the reverse manipulation i am able to view the data.Now the problem is ..if i am
    increasing the frequency of the input signal,the data is completly lost ?How can i overcome this problem...
    thanks in advance,
    srikrishna.J
    Analysis Engineer,
    Neurofocus

    Difficult to see where is the problem ....
    Be sure you are doing a good RT system by grabing reference design examples
    Don't forget to specify the DMA FIFO size in the RT code
    Doesn't matter the size of the DMA size under the FPGA project explorer.
    Upload your code, You will get answers...
    Mathieu

  • NI daq 6008 simultaneously analog input

    Hello;
    For the NI 6008 card sampling frequency equal to 10 kS / s and it has 8 analog inputs, but if I will use the 8 analog inputs simultaneously, what is the value of the new sample rate for each input analog obtained during an acquisition in labview?
    best regards.

    Duplicate post - http://forums.ni.com/t5/Multifunction-DAQ/NI-Daq-6008-and-Labview/m-p/3095362

  • Error-200279 when reading Analog Wfm Nsample

    I'm calling the attached VI at least 10x in the main VI and works fine but sometimes it's giving me an error-200279. Can someone please tell me why?
    Thank you in advance.
    KowdTek
    LabVIEW 2009
    One Step At A Time, Maybe Two...
    Solved!
    Go to Solution.
    Attachments:
    Detect Frequency.vi ‏25 KB

    Your buffer isn't big enough.
    You are collecting 20,000 samples per second, but only set it for 2000 samples per channel.  So that is 1/10 second worth of data.  You are reading 1000 samples at a time, so about 1/20th second.  If the loop is running fast enough, you can keep up and won't get an error.
    If there is a small delay (perhaps Windows goes off and does something else for 50 or 100 msec.) your buffer will overflow.
    I'd suggest eliminating the 2000 constant where you set the samples/channel and try again.  See if it behaves better.

  • About virtual channel in different device and/or different type channel

    Hi all,
      I am looking for a way to write to several analog channels at the same time. In my code, I didnt' pay much attention to that, I just have them placed in the the same frame in the flat sequence such that they might be started to write simultaneously. However, sometimes they might not working perfectly. I am reading something on DAQmx and I found that there is something call virtual channel so I have put more than 1 channel into a unit (called virtual cahnnel), so I can write something to it at the same time. Here are my question
    1) what's the different between virtual channel and channel group? If I write a array of 3 elements to a channel group (consists of dev1/ao1, dev1/ao2 and dev1/ao5),  am I writing to channel group or virtual channel?
    2) can I bind different channels from different devices to form a virtual channel, e.g. dev0/ao0 dev1/ao0 dev2/ao0?
    3) can I bind different type of channel to form a virtual channel, e.g. dev0/ao0, dev0/port0/line0?
    4) last question is about synchronization on writing to a virtual channel (or channel group?) Last say I have a pulse train each pulse is separated in time by 1.2ms and total time is 122.4ms. The pulse train will be sent to dev0/ao3, and at 12ms after start send very first pulse of the train, I need to write two analog signal to dev1/ao1 and dev1/ao5. In my current code, create a flat sequence, start the task for sending the train in the first frame, put delay in second frame and delay for 12ms, write dev1/ao1 and dev1/ao5 in the third frame. For some times, this gives me acceptable timing but not always. I wonder how does it help to use virtual channel?
    In the similar situtation, what about if instead of writing to two analog channel, I write to one analog channel and one digital channel?
    Thanks.

    1) virtual channel is created per task and contains a collection of settings such as a name, a physical channel, input terminal connections, the type of measurement or generation, and can include scaling information.. A virtual group is specific to digital IO and has to deal with the way you read/write data off/to the port
    2) yes you can create a task with physical channels from multiple devices assuming they are comparable writes (ie all analog or all analog read, or all digital) but they will have the same channel characteristics (see answer above)
    3) no you cannot create a task that handle an AO and a DO from with in the same task
    4) if you created a task you are using a virtual channel. The only way to ensure timing is to use hardware timing (ie onboard sample clock of you DAQ card) otherwise the reads/writes are basically interrupts and you are at the mercy of the OS to service the interrupt request
    if you need more information please repost with more questions, include your DAQ hardware, and any code pictures to give us a better idea of what you are trying to accomplish and how you are going about it
    Applications/Systems/Test
    National Instruments | AWR Group

  • Sharing apps on different devices and computers

    Hi - I am not sure if this is the right place for this question, but maybe someone can help me out.  My school district purchased an app that can be loaded on up to 5 devices. The district does not have their own Itunes account, so it was loaded on to someones personal Itunes account (with all of her personal purchases as well).  I am trying to figure out how to get just this app onto my device, and then not have to use her account for anything else? My question then is, once she loads it onto my IPad, how do I go and sync to a different ITunes account - is that even possible?  Hope this makes sense to someone....! Any help would be appreciated.

    Hi jacyjflorin,
    Having multiple iTunes accounts can cause confusion.
    Would Restrictions on the iPads work for you?
    iOS: Understanding Restrictions (parental controls) - Apple Support
    Check out the options you can set, including Installing Apps.
    Thank you for visiting Apple Support Communities.
    Nubz

  • HT3406 when using my old iphone as a itouch how do i get itunes to recognize as a different device and not the new phone?

    When using my old iphone4 as an itouch - how do i get itunes to recognize as a new and seperate device

    You don't need to do anything. iTunes will automatically recognise different devices as different devices. Just plug it in.
    You can rename the device by clicking the name in the side panel in iTunes for your own identification purposes, but this name does not matter to iTunes.

Maybe you are looking for