Справочник Пользователя для AMD Am188TMER

Скачать
Страница из 196
Asynchronous Serial Port
11-1
CHAPTER
11
ASYNCHRONOUS SERIAL PORT
11.1
OVERVIEW
The Am186ER and Am188ER microcontrollers provide an asynchronous serial port. The 
asynchronous serial port is a two-pin interface that permits full-duplex bidirectional data 
transfer. The asynchronous serial port supports the following features:
n
Full-duplex operation
n
7-bit or 8-bit data transfers
n
Odd parity, even parity, or no parity
n
1 or 2 stop bits
If additional RS-232 signals are required, they can be created with available PIO pins (see 
section 13.1 on page 13-1). The asynchronous serial port transmit and receive sections 
are double-buffered. Break character recognition, framing, parity, and overrun error 
detection are provided. Exception interrupt generation is programmed by the user.
The transmit/receive clock is based on the internal processor clock internally divided down 
to the serial port operating frequency. If power-save mode is in effect, the divide factor must 
be reprogrammed. The serial port permits 7-bit and 8-bit data transfers. DMA transfers 
through the serial port are not supported.
The serial port generates one interrupt for all serial port events (transmit complete, data 
received, or error). The Serial Port Status register contains the reason for the serial port 
interrupt. The interrupt type assigned to the serial port is 14h.
The serial port can be used in power-save mode, but the transfer rate must be adjusted to 
correctly reflect the new internal operating frequency and the serial port must not receive 
any information until the frequency is changed.
11.2
PROGRAMMABLE REGISTERS
The asynchronous serial port is programmed through the use of five, 16-bit peripheral 
registers. See Table 11-1.
Table 11-1
Asynchronous Serial Port Register Summary
Offset from 
PCB
Register 
Mnemonic
Register Name
80h
SPCT
Serial Port Control
82h
SPSTS
Serial Port Status
84h
SPTD
Serial Port Transmit Data
86h
SPRD
Serial Port Receive Data
88h
SPBAUD
Serial Port Baud Rate Divisor