04-04-2007 07:02 PM
So I decided I was going to use my AI to track my output and thus only my outputs need to be synched with each other, and only my inputs need to be synched with each other. I thought this was a good plan, but copy and pasting code didn't allow me to have multichannel input/output. Instead, DAQmx Write complains that it's reserved. I've saved my code down to 8 this time (sorry about the last). If you have any advice on multichannel input/output that would be great.
Thanks,
Kat
04-05-2007 10:06 AM
KMiu,
You can definitely setup multiple analog outputs and multiple analog inputs for
your card, but all the channels that you want to use will need to be grouped
into either the same analog input or output task. The reason for this is
that all of the inputs are multiplexed to the same analog to digital converter
and all the outputs are multiplexed from the same digital to analog converter.
When you create a task for multiple channels, the multiplexer actually switches
between the various channels in a specified order. Having separate tasks
would not only make enforcing this switch order impossible, but would require
windows to call into the same resource more than once, which Windows cannot do.
You can easily modify a written task to work for multiple channels with a few
minor adjustments. You can either add 'Create Channel' VIs to the
existing task for new physical channels, or you can change the specified
physical channel from say 'Dev0/ai0' to 'Dev0/ai0:5' This syntax
will actually read six channels (0,1,2,3,4, and 5).
Give this a go and see if it works.
04-06-2007 03:03 PM
Thanks Elijah,
What I want to do though is output different waveforms. Do I need to build an array of tasks and feed it to the sample clock? I'm slightly confused.
I'm also using 2 PCI 6221 cards for a total of 4 outputs. This seems to have something close to what I want, thought the output functions are all the same
http://zone.ni.com/devzone/cda/epd/p/id/5197
But when I run it I get this error: -89125 at DAQmx Write. No registered trigger lines could be found between the deices in route.
I'm too inexperienced with LABview to understand the logical steps of setting this up.
04-10-2007 08:55 PM