EasyManuals Logo

Texas Instruments TMS320 User Manual

Texas Instruments TMS320
288 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #264 background imageLoading...
Page #264 background image
Opening Devices
7-34
7.12 Opening Devices
Dxx_open opens a Dxx device and returns its status seen in Example 7-23:
Example 7-23. Opening a Device with Dxx_open
SIO_create calls Dxx_open to open a Dxx device as seen in Example 7-24.
Example 7-24. Opening an Input Terminating Device
This sequence of steps illustrates the opening process for an input-
terminating device:
1) Find string matching a prefix of /adc16 in DEV_devtab device table. The
associated DEV_Device structure contains driver function, device ID,
and device parameters.
2) Allocate DEV_Obj device object.
3) Assign bufsize, nbufs, segid, etc. fields in DEV_Obj from parameters and
SIO_Attrs passed to SIO_create.
4) Create todevice and fromdevice queues.
5) If opened for DEV_STANDARD streaming model, allocate attrs.nbufs
buffers of size BUFSIZE and put them on todevice queue.
6) Call Dxx_open with pointer to new DEV_Obj and remaining name string
using syntax as shown:
status - Dxx_open (device, "16")
7) Validate fields in DEV_Obj pointed to by device.
8) Parse string for additional parameters (for example, 16 kHz).
9) Allocate and initialize device-specific object.
10) Assign device-specific object to device
object.
The arguments to Dxx_open are shown in Example 7-25.
Example 7-25. Arguments to Dxx_open
status = Dxx_open(device, name);
input = SIO_create("/adc16", SIO_INPUT, BUFSIZE, NULL)
DEV_Handle device; /* driver handle */
String name; /* device name */

Table of Contents

Other manuals for Texas Instruments TMS320

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Texas Instruments TMS320 and is the answer not in the manual?

Texas Instruments TMS320 Specifications

General IconGeneral
BrandTexas Instruments
ModelTMS320
CategoryComputer Hardware
LanguageEnglish

Related product manuals