PCI-1800/1802

Visitor 506 Last updated Monday, 10-Mar-2003 12:16:41 CST

Supported Models
PCI-1002
PCI-1202
PCI-1602
PCI-1800/1802
PCI-P16R16/P16C16/P16POR16
PCI-P8R8
PCI-TMC12
Valid XHTML 1.0! Valid CSS!

Source Code Tour for IxPCI
Device ID
Device File
ioctl Commands
Data Structures
Registers
Examples

Device ID

PCI_1800  PCI_1802

Device File

/dev/ixpcin

The n is the IXPCI device number.

ioctl Commands

IXPCI_GET_INFO
Retrieve a device's information, and put it into the ixpci_devinfo (ixpci_devinfo_t) structure. Example: list.c.
IXPCI_READ_REG
Read a specified register's value, and put the value into the ixpci_reg (ixpci_reg_t) structure. Example: ixpci1800/dio.c
IXPCI_WRITE_REG
Write a given value to a specified register. Example: ixpci1800/dio.c
IXPCI_RESET
Reset device.Example: ixpci1800/reset.c.
IXPCI_TIME_SPAN    IXPCI_BLOCK    IXPCI_DELAY    IXPCI_WAIT
IXPCI_TIME_SPAN uses the 8254 counter-2 to be the machine-indepent-timer by the internal 8 MHz clock. Command will be blocked before the countering has finished. The maximum counter value is 8190 micro-seconds. IXPCI_TIME_SPAN, IXPCI_BLOCK, IXPCI_DELAY, and IXPCI_WAIT all are identical. Example: ixpci1800/time_span.c.

Data Structures

ixpci_devinfo_t
The data type of structure ixpci_devinfo which contains a device's id, base address, and so on. Example: list.c.
ixpci_reg_t
The data type of structure ixpci_reg which contains a register's id and value. Example: pci1800/port.c.

Registers

R=Readable  W=Writable

Available registers that can be used in structure ixpci_reg for PCI-1800.

IXPCI_8254C0 R W
8254 Counter 0. IXPCI_8254C0 is the short term of IXPCI_8254_COUNTER_0.
IXPCI_8254C1 R W
8254 Counter 0. IXPCI_8254C1 is the short term of IXPCI_8254_COUNTER_1.
IXPCI_8254C2 R W
8254 Counter 2. IXPCI_8254C2 is the short term of IXPCI_8254_COUNTER_2.
IXPCI_8254CR R W
8254 Control Register. IXPCI_8254CR is the short term of IXPCI_8254_CONTROL_REGISTER.
IXPCI_CR R W
Control Register. IXPCI_CR is the short term of IXPCI_CONTROL_REGISTER.
IXPCI_SR R W
Status Register. IXPCI_SR is the short term of IXPCI_STATUS_REGISTER.
IXPCI_ADST R W
AD Software Trigger Register. IXPCI_ADST is the short term of IXPCI_AD_SOFTWARE_TRIGGER_REGISTER.
IXPCI_DI R W
Digital Input. IXPCI_DI is the short term of IXPCI_DI_PORT.
IXPCI_DO R W
Digital Input Port. IXPCI_DO is the short term of IXPCI_DO_PORT.
IXPCI_AD R W
Analog to Digital Port. IXPCI_AD is ther short term of IXPCI_AD_PORT.
IXPCI_DA1 R W
Digital to Analog Channel 1. IXPCI_DA1 is the short term of IXPCI_DA_CHANNEL_1.
IXPCI_DA2 R W
Digital to Analog Channel 2. IXPCI_DA2 is the short term of IXPCI_DA_CHANNEL_2.

Examples

list.c
An example of ioctl command IXPCI_GET_INFO.
ixpci1800/dio.c
An example for reading and writing registers by ioctl commands IXPCI_READ_REG and IXPCI_WRITE_REG.
ixpci1800/reset.c
An example of ioctl command IXPCI_RESET.
ixpci1800/time_span.c
An example of ioctl command IXPCI_TIME_SPAN.

Emmy Tsai <emmy@omega.com> | Service from Omega <service@omega.com>