LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Simultaneous use of DaqMx read vi

In my application i am creating two seperate task for acquiring analog datas from different cards. I am using DaqMx read vi to acquire the datas simultaneously from both the channels.  While acquiring the datas i am getting an error. The error is as follows.
 
 "Error -50103 occurred at DAQmx Read (Analog DBL 1Chan 1Samp).vi
Possible reason(s):
The specified resource is reserved. The operation could not be completed as specified.
Task Name: sample2"
 
I am using LabVIEW 7.1 and my DaqMx version is 7.4
 
Here i have enclosed my a sample vi.
i am using this in seperate location of my main program.
Is there any solution for this or can it be done using NI Daq 8 version
 
thanks in advance
 
 
0 Kudos
Message 1 of 7
(3,847 Views)
Hi Binoy,
 
Correct me if i am wrong.
 
in one loop, you are acquiring from a DAQ card channel 2
In other loop, you are acquiring from a SCXI channel.
Now tell me, is SCXI module multiplexed to the same DAQ card ????
 
Looks so, since this error wil come if  you are trying to read from a device that is already being used by another AI read.
 
If this is the case, then you cannot read from the same DAQ using 2 different AI reads.
 
Regards
Dev
 
 
0 Kudos
Message 2 of 7
(3,845 Views)

Here i am using PXI 6229 as communucating card and in my SCXI slot SCXI 1125 is used. I am trying to acquire channel zero of both PXI 6229 and SCXI 1125 simultaneously. If it is not possible,is there any option to do that.

0 Kudos
Message 3 of 7
(3,845 Views)
I am using Combo Chasis(PXI 1052) with PXI 8187 controller. PXI cards are PXI 6528 and PXI 6229. SCXI modules are SCXI 1125, SCXI 1169 and SCXI 1162.
PXI 6229 is my communicating card. So i want to know whether it is possible to acquire simutaneously from both PXI 6229 analog channel and SCXI 1125 channel.
 
regards
Binoy
0 Kudos
Message 4 of 7
(3,841 Views)
Hi Binoy,
 
To acquire from both, that's your communicating card PXI 6229 's DAQ channels as well as SCXI 1125's channels ( which are multiplexed to DAQ card PXI 6229 ) , all you have to do is to put them a single scan list and acquire.
 
Configure both channels in your physical channels list and you can acquire in form of 'n channel 1 sample' 1D arrray or or 'n channel n samples' 2D array.
 
Regards
Dev
 
 
 
 
0 Kudos
Message 5 of 7
(3,836 Views)
Hi Binoy and DevChander,

New labview programmer here, using LV 8.  I am interested in this thread because I am trying to write a control system using a pxi 1042 hcassis with 8336, 6704, 6224, 2 6528's, 2568, and 8422 cards installed.  My orginal idea was to have a main VI running the system with certain tasks defined by the instrumentation operated from sub VI's within this main VI.  For instance a user would be able to monitor the system on the main VI, but control valves on one sub-VI writing and reading to do/di card, control voltage inputs on another writing and reading on a ai/ao card,  and perhaps  monitoring pressure transducers using ai/ao.  However I am running into the same problems that Binoy is having with resources that already reserved - following the example, if one is monitoring a pressure transducer and wants to change a voltage input using the same ai/ao card but a different sub-VI, this error will appear and the task will not be completed. 

Does this error mean that I have to design the system around the cards, using a sub-VI for each different card no matter the physical task controlled/read through that card?  Am I just thinking about LV the wrong way?

Right now I have several individual VI's controlling several unique physical tasks, but these all conflict with one another.  Basically my question is how do I change my thinking to make these work in concert with one another?  Obviously I am missing some key points on how LV works to communicate through this PXI chassis...

Brad
0 Kudos
Message 6 of 7
(3,754 Views)

Hi Brad,

Your problem sounds very similar to the original issue posted in this forum. The reason that you are probably running into this error in the middle of your task is that you are trying to update settings that have already been configured without stopping and clearing the task first. Here is the link to a KB with more information about the error: Causes of NI-DAQmx Error 50103 "The Specified Resource is Reserved".

Also, you can have multiple tasks in the same program, as long as they are of different types. So you could have separate digital input and analog input tasks for the same card, but you cannot have separate analog input tasks unless they are configured for different DAQ devices. I hope that you find this information helpful.

Regards,
Hal L.

0 Kudos
Message 7 of 7
(3,726 Views)