LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Write array of samples to output port/line of NI-USB-6008

Solved!
Go to solution

Hi,

I am trying write an array of samples to digital and analog line of NI USB 6008. Writing one sample is working fine but I am confused about how to write more samples to the port.

In the function:

 

int32 DAQmxWriteDigitalLines (TaskHandle taskHandle, int32 numSampsPerChan, bool32 autoStart, float64 timeout, bool32 dataLayout, uInt8 writeArray[], int32 *sampsPerChanWritten, bool32 *reserved);

 

Q1: it seems possible to write more samples to the line, but how is the timing controlled?

For example if my writeArray is {1, 0, 1, 0} then how is the sample rate (samples per second) decided by the user?

 

Q2: Same is my question for analog line

int32 DAQmxReadAnalogF64 (TaskHandle taskHandle, int32 numSampsPerChan, float64 timeout, bool32 fillMode, float64 readArray[], uInt32 arraySizeInSamps, int32 *sampsPerChanRead, bool32 *reserved);

 

Q3: The fastest possible sample rate as per datasheet for analog output is 150 Hz. What is the fastest possible sample rate for digital output?

 

Thanks in advance.

 

Regards,

RB

 

 

0 Kudos
Message 1 of 2
(2,797 Views)
Solution
Accepted by topic author dotNet_to_LabW

Hi RB,

 

AO and DIO on the USB 6008 are static, you can't give a number for the timing. You can only have a look at how fast your PC do this, therefore you have to benchmark it.

 

regards

Tobias

Message 2 of 2
(2,768 Views)