10-25-2005 08:55 AM
03-12-2007 04:26 PM
Hi.
I have the USB-6008/6009 device.
I want to connect a rotational encoder with two chanels (main one and one with phase shift to set direction).
I keep getting the same message :"Error -50103 occurred at DAQmx Read (Analog 1D DBL 1Chan NSamp).v"
I looked at the notes earlier on this thread and tried the base_2AI example. Then I modified it a bit but with no results.
My phisical connection is RSE to AI0 and AI1.
What can I do?
Thanks
Assaf
Student at the Technion, Israel .
03-13-2007 03:12 PM
03-14-2007 12:44 AM
03-14-2007 03:16 PM - edited 03-14-2007 03:16 PM
Message Edited by Matt A on 03-14-2007 03:21 PM
04-06-2013 01:43 AM
Dear Tom,
I have the same Project and want to acquire multiple channels synchronously but in C++. First of all I tried to use multi threading but thanks your post I've got that I was wrong. In order to obtain and save these data I have written "Dev1/ai0:1" as 5th parameter of the function "DAQmxReadAnalog64" and I've changed the definition of the parameter, in which data will be saved to a 2-D Array as "float64 data[2000][2]".But I face the error:
cannot convert parameter 5 from float64[2000][2] to float64[]
Sure it is due to the definition of the function "DAQmxReadAnalog64" which gets 1-D Array as 5th parameter. Whould you Plz explain me how can I get acquiered data from multi channels and save them for example in a 2-D Array?
best regards,
Mohamamd
04-08-2013 07:27 AM
Hi Mohamamd-
You mention the DAQmxReadAnalog64 function (whose name seems slightly malformed, but I get the point), but this is a thread with questions about NI-DAQmx Base. Which O/S and driver API are you using?
Regardless, it sounds like you could benefit from viewing a shipping example that shows the use of the "C" APIs for your driver package. For example, the DAQmx/DAQmx Base device names are not used as parameters for any Read functions. You have to create tasks and virtual channels before you can Start and Read from those tasks and channels, and the create virtual channel function is where you specify the physical channels to use.
The relevant examples can be found either under the start menu (in Windows) or in folders alongside the driver configuration applications and support files on other platforms. Please try to locate those examples and use them for guidance. If you have other questions about using those examples, please create a new discussion forum thread.
Hopefully this helps-