HW5soln-3750

HW5soln-3750 - EE 3750 HW 5 solutions 1 EE 3750 Homework 5...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
EE 3750 — HW 5 solutions 1 EE 3750 — Homework 5 solutions Spring 2004 1. Write an 8086 instruction sequence to enable interrupts when Port A of an 82C55 (parallel interface) is ready for output and when Port B is ready for input where Groups A and B are in Mode 1. Assume that the modes and input/output directions of the 82C55 have already been initialized. Let 78H be the lowest port address for this 82C55. MOV AL, 1101B ; low 4 bits are1101, setting PC6 to 1 OUT 7BH, AL ; output to command register MOV AL, 5 ; low 4 bits are 0101, setting PC2 to 1 OUT 7BH, AL ; output to command register 2. Write an 8086 instruction sequence to initialize a 16550 UART. Set data length to 8 bits, use 1 stop bit, use odd parity, use a baud rate divisor of 60, enable and clear the FIFO queues, set the receiver trigger level to 1 byte in FIFO, and enable receiver interrupts. Let the low port address of the 16550 be 80H. Clearly state any additional assumptions that you make. Note: In addition to Brey §11-6 on the 16550, pp. 487-494 in §12-4 deal with interrupts and the 16550. The two “memory FIFOs” in the Brey text example are part of the example only and are not part of the problems on this homework. DLL EQU 80H ; divisor latch low DLH EQU 81H ; divisor latch high LINEC EQU 83H ; line control FIFOC EQU 82H ; FIFO control INTEN EQU 81H ; interrupt enable MOV AL, 10000000B ; set up access to divisor latch OUT LINEC, AL MOV AL, 60 ; divisor value OUT DLL, AL ; lower divisor latch MOV AL, 0 ; upper byte of divisor is 0 since 60 fits in lower byte OUT DLH, AL ; upper divisor latch MOV AL, 00001011B ; odd parity, 8 bits data, 1 stop bit OUT LINEC, AL MOV AL, 1111B ; enable FIFO, clear queues, receiver trigger level = 1 OUT FIFOC, AL MOV AL, 1 ; enable receiver interrupts OUT INTEN, AL
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 01/25/2012 for the course EE 3750 taught by Professor Desouza during the Fall '08 term at LSU.

Page1 / 4

HW5soln-3750 - EE 3750 HW 5 solutions 1 EE 3750 Homework 5...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online