www.vtiinstruments.com
APPENDIX B
49
Record N
Record
N+1
Record
N+2
Trig N
Trig N+1
Trig N+2
From ADC
FIFO Overflow Limit
Overwritable
Unused Space
New Data
Figure 4-12: Circular FIFO
The EMX-4250/4350/4380 implements three different FIFO modes of operation in order to meet
varieties of application needs. The FIFO mode defines the behavior when the FIFO buffer is full
and there is no more space to write new data records.
Stop FIFO Mode
In
stop
FIFO mode, the instrument stops writing new data to the FIFO. The measurement is aborted
after the last data record in the FIFO is read, and FIFO overflow error will be issued.
Overwrite FIFO Mode
In
overwrite
FIFO mode, the oldest data record is overwritten by the last data record. The
overwritten data record will be permanently lost, but the measurement will not be aborted.
Wait FIFO Mode
In
wait
FIFO mode, the instrument will not write new data until oldest data record is read and enough
data space becomes available. In this mode, all cards will stop accepting triggers until they are able
to save their data without overwriting unread records. The measurement will not be aborted.
As a result of this circular buffer, when in FIFO
stop
mode, a FIFO overflow doesn’t happen when
enough records have been collected to fill the buffer, but when enough time has passed since the
oldest unread record in the FIFO was saved. This amount of time is the size of the channel’s circular
buffer divided by its
SampleRate
. Each card can store 30 MSamples (31,457,280 samples) split
among all enabled channels. If the sample rates the same on all channels, this time is
([31,457,280 Samples / number of channels] /
SampleRate
) seconds.
D
ATA
S
TREAMING
The digitizer and DSA driver comes with an optimized data-reading interface for high speed and/or
low-latency acquisitions. This interface relies on a separate thread which receives data
asynchronously from the instrument as soon as it is available and acts on it immediately based on
user-set preferences. There are two streaming modes, both can be enabled at the same time.
Memory Streaming
Memory streaming is the default mode for these instruments. When the user enables Streaming
without any configuration, the data is streamed into a dynamically allocated buffer on the host PC
and then retrieved via a Read-like interface. This is the fastest streaming interface, since memory is
the fastest storage device on the PC. However, this mode is unsuited for long acquisitions because
it can grow beyond the memory limits of the device and start paging to disk. The internal buffer
grows as needed but does not shrink until streaming is disabled.
Additionally, this mode can be set to watch only select channels of interest. If the
MemoryChannelsList
property is set, the data for only the selected channels will be streamed to
memory.