LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Error -200288 on multiple analog ins/outs

Hi there,
I have modified the MultiFunction-Sync-In-Out to accept 4 analog ins and 1 analog out but as you can see I always get Error -200288. I have attached the vi along with this message. If this problem is solved, I would like to output a second analog channel with a pulse to mark signal out from the first analog out. Please advise. Cheers, Biswa
0 Kudos
Message 1 of 5
(3,824 Views)

Hi Biswa,

Odds are under DAQmx your not stopping the task after a read or write before re-enabling any triggers as noted in this KB:

http://digital.ni.com/public.nsf/allkb/BFCE83133C0ECAD786256E6000814B68?OpenDocument

All the best,

Applications Engineer
0 Kudos
Message 2 of 5
(3,804 Views)
Hi there, Thanks for the message. You are right that this is because of the task not getting stopped at every iteration of the while loop. It seems stopping a task at the end of each iteration only holds for software triggered DAQ and not otherwise.  have herewith attached the next version of the code. The query is if I am doing finite sample acq. and generation (the samples are set as fixed for AO and AI) then shouldn't my text file for data saved via AI/AO operation have equal number of points starting at set start time. It certainly doesn't seem to be the case and I reckon this is something to do with the buffer. Your advice on this would be highly appreciated. Cheers, Biswa
0 Kudos
Message 3 of 5
(3,794 Views)
Another query with regard to your solution is that if I need to stop task inside the loop how would I possibly be acquiring data (AI) continuously? It certainly doesn't give me a continuous time when I write the AI to a file. An example is attached. Also, the Multi-Function-Synch AI-AO vi that comes as an example in the DAQmx example folder works fine.
 
Biswa
0 Kudos
Message 4 of 5
(3,775 Views)

Hi Biswa,

I have a few remarks about the code as I cannot understand what you are trying to do.

1) You are creating two tasks on the left (namely Input_data, Output_data) and then you use a for loop to assign the channels.  You do not need to create 4 separate tasks for the AI channels and in fact it will not work correctly the way you have implemented it. You need to specify the channels as Dev1/ai0:1:2:3 . Have a look at the examples on NI DAQmx  on how to acquire data from multiple channels. It may be easier if you create the tasks in MAX ( by right-clicking on Data Neighbourhood). The benefit of creating the tasks in MAX is that you can specify the acquisition mode and triggering inside a configuration dialog box. I can't see where you specify how many samples to acquire in this VI. It is usually done in the DAQmx Timing VI.

2) I am trying to see if you are looking to do finite or continuous acquisition. If you are trying to do continuous acquisition, then you do not need to stop the task unless you want to terminate the program.

Regards,

KostasB

NIUK Applications Engineering

Message 5 of 5
(3,699 Views)