User`s guide

Universal Library User's Guide Analog Input Boards
30
Pretrigger implementations
Pretrigger functionality may be implemented through software or hardware. These two methods have different
limitations and requirements. Most Measurement Computing products with pretrigger capability are
implemented in hardware.
When implemented in hardware, the buffer created using cbWinBufAlloc() must be large enough to hold 512
samples more than the requested TotalCount. The trigger location is tracked by a counter on the board. When
the trigger condition is met, data is acquired and the library functions return the actual number of pretrigger
points that were acquired. When run in BACKGROUND mode, the cbGetStatus() function will typically show
CurCount rise to the value of PretrigCount and remain there while CurIndex cycles from 0 to TotalCount
continuously until the trigger is received.
With the software implementation of pretrigger, the additional space in the buffer is not required. The trigger
location is tracked by software. Any triggers that occur before the number of samples defined by the
pretrigger count argument are ignored. When run in BACKGROUND mode, the cbGetStatus() function will
typically show CurCount at a value of 0 and CurIndex at a value of -1 until the trigger is received. They will
then rise from of PretrigCount to TotalCount.
Sampling rate using SINGLEIO
When using this mode of data transfer, the maximum analog sampling rate is dependent on the speed of the
computer in which the board is installed. In general, it is in the range of 5 to 50 kHz. If the requested speed
cannot be sustained, an overrun error will occur. Data will be returned, but likely there will be gaps. Some
boards, such as the CIO-DAS08, support this mode only, so the maximum rate attainable with these boards is
system-dependent.