DNx-SL-514 Synchronous Serial Interface Board
Chapter 3
19
Programming with the Low-Level API
May 2018
www.ueidaq.com
508.921.4600
© Copyright 2018
United Electronic Industries, Inc.
Chapter 3
Programming with the Low-Level API
This chapter provides the following information about programming the SL-514
using the low-level API:
•
About the Low-level API (Section 3.1)
•
Low-level Functions (Section 3.2)
•
Low-level Programming Techniques (Section 3.3)
3.1
About the
Low-level API
The low-level API provides direct access to the DAQBIOS protocol structure and
registers in C. The low-level API is intended for speed-optimization, when
programming unconventional functionality, or when programming under Linux or
real-time operating systems.
When programming in Windows OS, however, we recommend that you use the
UeiDaq high-level Framework API (see
). The Framework extends the
low-level API with additional functionality that makes programming easier and
faster.
For additional information regarding low-level programming, refer to the
“PowerDNA API Reference Manual” located in the following directories:
•
On Linux systems:
<PowerDNA-x.y.z>/docs
•
On Windows systems:
Start » All Programs » UEI » PowerDNA » Documentation
3.2
Low-level
Functions
Table 3-1 provides a summary of SL-514-specific functions. All low-level
functions are described in detail in the PowerDNA API Reference Manual.
Table 3-1 Summary of Low-level API Functions for DNx-
SL-514
Function
Description
DqAdv514Config
Configures synchronous serial interface channels:
• enables master/slave ports
• sets clock source
• sets baud rate
• sets number of bits in transmission/reception word
• sets data delay time (tv)
• sets transfer timeout time (tm)
• sets time delay between transmissions (tp, pause time)
• sets trigger condition to read/fill FIFO
• enables debouncing
• enables termination resistors
DqAdv514SetPLL
Programs the PLL clock on the SL-514 board (for baud
rate programming), if the PLL source is selected.
The default clock source for baud rate programming is the
66 MHz clock, not the PLL.
DqAdv514Status
Reads error states/status states