Measurement Computing WaveBook rev.3.0 User Manual
Page 188
C-14 daqX API - Programming Models,
6-22-99
WaveBook User’s Manual
Set a complex trigger at channels 1 and 2:
ret& = VBdaqAdcSetTrigEnhanced&(handle&, rising&(1),gains&(0),ranges&(0),
DetsFallingEdge,levels(0)%,HYSTERESIS%(1), chan&(0))
VBdaqAdcSetTrigEnhanced()
is used in place of VBdaqAdcSetTrig(). It defines the complex
trigger event that will initiate the acquisition. Since it can configure independant trigger events on multiple
channels, arrays of the parameters are given as arguments with each index referring to a specific channel.
Start the transfer:
ret& = VBdaqAdcTransferStart()
Arm the acquisition; data transfer will begin upon detection of the trigger event defined by:
ret& = VBdaqAdcArm&(handle&)
Wait for the transfer to end:
ret& = VBdaqWaitForEvent(handle&, DteAdcDone&)
Results can now be displayed or otherwise manipulated:
Print "Results of BufferTransfer:"
For i& = 0 To channels& - 1
Print "Channel"; i& + 1; "Data:";
For j& = 0 To scans& - 1
Print Tab(j& * 7 + 17); buf%(j& * channels& + i&);
Next j&
Print
Next i&
Close the device when finished:
ret& = VBdaqClose(handle&)