Data Acquisition (DAQ) and Control from Microstar Laboratories

Sample Fast and Slow Channels Simultaneously

data acquisition filtering data acquisition software channel architecture enclosures services

In DAPL you can set only one time parameter, Time in microseconds, between items in the Input Definition. However, if you list the same hardware channel more then once, you can independently control the sample rate for individual channels.

The following code demonstrates how to sample one channel, S0, at twice the rate of the other two, S1 and S2.

Idefine A 4
  Set Ipipe0 S0  // Read S0 once
  Set Ipipe1 S1
  Set Ipipe2 S0  // Read S0 again
  Set Ipipe3 S2
  Time 25
End

Thus S0 is sampled every 50 microseconds while S1 and S2 are each sampled every 100 microseconds. Data from S0 then exists in two pipes, but use an Input Pipe Channel List, to multiplex the pipes together to be read by one task. An example for a Fast Fourier Transfer (FFT) follows.

Pdefine B
  FFT( Mode, Size, WindowType,   Ipipe(0,2),  OutputPipe)
End

 

Go back to the Technical Support Center.