Embedded Solutions
Page 11 of 37
Programming
Programming the PMC-BiSerial-III RL1 requires only the ability to read and write data
from the host. The base address is determined during system configuration of the PCI
bus. The base address refers to the first user address for the slot in which the PMC is
installed.
Depending on the software environment it may be necessary to set-up the system
software with the PMC-BiSerial-III RL1 "registration" data. For example in WindowsNT
there is a system registry, which is used to identify the resident hardware.
Before I/O data can be sent or received, the PLL must be programmed to the desired
clock configuration. The PLL is connected to the Xilinx by an I
2
C serial bus. The PLL
internal registers are loaded with 40 bytes of data that are derived from a .jed file
generated by the CyberClock utility from Cypress semiconductor
http://www.dyneng.com/CyberClocks.zip
. Routines to program the PLL are included in
the driver and UserApp code provided in the engineering kit for the board.
The interrupt service routine should be loaded and the interrupt mask set. The interrupt
service routine can be configured to respond to the TX/RX interrupts. After an interrupt
is received, new TX data can be written or RX data retrieved. An efficient loop can then
be implemented to process the data. New messages can be sent or received even as
the current one is in progress.
If more than one interrupt is enabled, then the software needs to read the status to see
which source caused the interrupt. The status bits are latched, and are explicitly
cleared by writing a one to the corresponding bit. It is a good idea to read the status
register and write that value back to clear all the latched interrupt status bits before
starting a transfer. This will insure that the interrupt status values read by the interrupt
service routine came from the current transfer.
If DMA is to be used it will be necessary to acquire blocks of non-paged memory that
are accessible from the PCI bus in which to store the DMA chaining descriptor list
entries.
Refer to the Theory of Operation section above and the register definition section below
for more information regarding the exact sequencing and interrupt definitions.
The PMC-BiSerial-III RL1 VendorId = 0x10EE. The CardId = 0x0032. The device class
code is 0x0680 (PCI bridge – other)