Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

[PXI-1042] MultiChannels Analog problems

Hi everyone, in advance sorry for the bad english.

 

I'm currently having problems with the acquisition of multiple chan in analog. I'm working in C :

 

 DAQmxCreateAIVoltageChan (tache, "Dev1/ai0,Dev1/ai1", "nomConvertion", DAQmx_Val_RSE, -10, 10, DAQmx_Val_Volts, "");

 

If i correctly understand, this function will configure the pxi to acquire 2 channels 0 and 1. Notice : That's perfectly working with only one channel.

 

I configure the clock :

 

DAQmxCfgSampClkTiming (tache, NULL, nbrEchantillons, DAQmx_Val_Rising, DAQmx_Val_ContSamps, tailleTab);

 

And i read :

 

DAQmxReadAnalogF64 (tache, tailleTab, 600, DAQmx_Val_GroupByChannel, temp, tailleTab, &sampleRead, NULL);

 

 and here comes the problem : 

 

 - With only one channel, the double tab returned (temp) is good and contains all values, but when there is two channels, he first value of the tab means nothing and all others are 0.

 

I tried many things before sending to all of you my problem but nothing changes. Maybe DAQmxReadAnalogF64 is not the good function to call, i don't know. If someone could help me i'll be extremly happy.

 

Thanks in advance.

 

DALIDO Jean-Baptiste

0 Kudos
Message 1 of 2
(2,880 Views)

Hi Jean Baptiste.

 

Do you find a solution about your issue?

First I advice to have a look at the NI examples. It should be helpful.

I investigate about your issue and I will give you a feedback.

Could you attach your code please too?

Thanks.

Best Regards,

 

EDIT : Which board do you use?

Message Edité par R_Duval le 02-10-2010 05:59 PM

Romain D.
National Instruments France

0 Kudos
Message 2 of 2
(2,839 Views)