
SERIAL Digital I/O Series User Manual Eagle Technology - Data Acquisition
queried with number of samples available and other status issues as well. There are two
functions available to copy data, one for copying voltages, another to copy the raw data. The
raw data is significantly faster as for the data does not have to be converted to voltages
before copying it to the user buffer. The raw data also occupies less space than the micro
voltage buffer. There are also functions to write data to disk as the user buffer get copied.
Refer to the EDR Enhanced programming manual for a reference to these functions.
API-CALL
Long EDRE_ADGetData (ulng Sn, plong Buf, pulng BufSize)
ACTIVEX CALL
Long EDREADX.GetData (plong Buffer, plong Size)
To retrieve data from the driver buffer the serial number need to be supplied, a buffer to hold
the data and the size of the buffer or requested number of samples. The driver will only copy
the number of available samples in multiple of the channel list. For the ActiveX call only the
buffer and size need to be supplied.
Querying the ADC subsystem
The driver can be queried to check the status of the ADC subsystem. The number of unread
samples is one example. The appendix has a list of all possible query codes.
API-CALL
Long EDRE_Query (ulng Sn, ulng QueryCode, ulng Param)
A serial number, query code and parameter must be specified when doing a query.
ACTIVEX CALL
Long EDREADX.GetUnread ()
This function automatically queries the ADC driver buffer for the number of available samples.
Change Baud Rate
A single Query call is necessary to change the baud rate of the serial device.
The Query Code must be “SETBAUDRATE” (701) to change the baud rate. The Parameter
must specify the new baud rate. See Baud Rate Codes table.
API-CALL
Long EDRE_Query(ulng Sn, ulng code, ulng Param)
The serial number, Query Code and Parameter must be passed by the calling function.
ACTIVEX CALL
Long EDREUtlX.Query(long code, long Param)
The Query Code and Parameter must be passed by the calling function.
Eagle Technology © Copyright 2003 – www.eagledaq.com 26