8 Interrupts
The
When using interrupts with the
1.If the external FIFOs are enabled, read the Interrupt Status Register (see page 43) to determine whether the interrupt was caused by a FIFO event or by theSCC.
2.If the TX_FIFO bit is set, at least 512 bytes can be written to the Tx FIFO. If the
RX_FIFO bit is set, at least 512 bytes can be read from the Rx FIFO. I/O block move instructions may be useful. Check the FIFO Status Register (see page 44) after servicing the FIFO(s) to see if further FIFO service is required.
3.If the SCC bit is set, do an SCC software interrupt acknowledge by reading Read Register 2 in channel B of the SCC. The value read can also be used to vector to the appropriate part of the ISR.
4.Service the SCC interrupt by reading the receiver buffer, writing to the transmit buffer, issuing commands to the SCC, etc.
5.Write a Reset Highest Interrupt Under Service (IUS) command to the SCC by writing 0x38 to Write Register 0.
6.Check for other interrupts pending in the SCC by reading Read Register 3. Perform further interrupt servicing if necessary.
7.For applications running under DOS, a nonspecific End of Interrupt must be submitted to the interrupt controller. For Interrupts
For further information on these subjects or any others involving the SCC contact Zilog for a complete technical manual.