Measurement Studio for .NET Languages

Showing results for 
Search instead for 
Did you mean: 

I wanna use createvoltagechannel in C#.NET .

Dear veterans,
I wanna create 3 voltage channels and set each channel differently.
For instance, the range of the first channel is -5~+5 and the sampling rate is 50kHz; the second channel is -10~+10 and 25kHz sampling rate; the third is 0~5 and 1kHz sampling rate.
In the example code,
myTask.AIChannels.CreateVoltageChannel(physicalChannelComboBox.Text, "", (AITerminalConfiguration)(-1), Convert.ToDouble(minimumValueNumeric.Value), Convert.ToDouble(maximumValueNumeric.Value), AIVoltageUnits.Volts);
pysical ChannelComboBox.Text = "Dev1/ai0:2";
I think it is right setting for the multi-channel DAQ.
After that, what will I have to do for my purpose?
Should I make each voltage channel?

메시지가 01-11-2006 02:00 AM에 James Choi에 의해 편집되었음

0 Kudos
Message 1 of 2
In general, if you want to acquire multiple channels where every channel has different parameters, you have to call CreateVoltageChannel multiple times, for every channel with different parameters. You can only group these channels together that have the same parameters (for example the same Range).
It is no problem to define a task with multiple channels, where every channel has different ranges, but it is not possible to define differnt sampling rates for these channels. Do use different sampling rates, you have to use different tasks. Take care that not all boards support different samplingrates at the same time. For example E-Series or M-Series boards do not support to acuire channels with different sampling rates at the same time.
Hope this helps!
0 Kudos
Message 2 of 2