Owner's manual

Chapter 4: PowerDAQ Software
4
6
Event-based streamed I/O
Event-based streamed I/O mode allows continuous pattern generation
and is not limited by the amount of data. Every time the DSP based
FIFO is 1/2 full an interrupt is fired to request additional data be sent
to the board. The PowerDAQ advanced buffering mechanism hides
those interrupts from the user and allows you to work with big output
arrays logically divided by frames. The end of each frame can generate
an event, which will request more data from the application. Complete
information on the PowerDAQ advanced circular buffer (ACB) can be
found at www.Omega Engineeringdaq.com
and in the PowerDAQ SDK
Software Manual.
Note If the on-board FIFO is empty or the last value is
outputted, the output registers will continue to hold
the last value.
Input/Output buffer is organized as an array of 16-bit words or 32-bit
words (output), divided in certain number of logic blocks called
frames. Frames are divided into the scans. Scan is a set of samples
one sample for every channel in the channel list. Number of frames
depends on the specific applications. Usually, four frames are a good
choice for most cases. A bigger number of smaller frames allows to
scan data more often but frame size should not be smaller, than 512
samples for the input and 1024 samples for the output. Also, there is
an option to read/write the whole buffer only once when driver will
stop acquisition automatically at the end of the buffer. Following
constants, combined together, are define the buffer behavior in
_PdAcquireBuffer API function:
AIB_DWORDVALUES – use 32-bit DWORD data where lower
16 bits represents the actual data and bits 16..18 represents the output
port number (0..7). Valid for output buffered mode only.
AIB_BUFFERWRAPPED – allow driver to use buffer more, than one
time. If this flag is not set the driver will stop acquisition at the end of
the buffer and will set the corresponding flags (
eBufferDone
and
eStopped
) in the application event.
AIB_BUFFERRECYCLED – overwrite the data in the buffer even if old
data has not been read/updated yet.