Unformatted text preview:

Systems Design and Programming Basic I/O III CMPE 3101 (April 14, 2002)UMBCU M B CUNIVERSITY OF MARYLAND BALTIMORE COUNTY1 9 6 6Programmable Keyboard/Display Interface - 8279A programmable keyboard and display interfacing chip.Scans and encodes up to a 64-key keyboard.Controls up to a 16-digit numerical display.Keyboard has a built-in FIFO 8 character buffer.The display is controlled from an internal 16x8 RAM that stores the codeddisplay information.8279A0CSBDOUT A3OUT A2OUT A1OUT A0OUT B3OUT B2OUT B1OUT B0SL0SL1SL2SL3SHIFTCNTL/STBRL0RL1VCCVSSDB7DB6RESETRL7RL6RL5RL4IRQCLKRL3RL2DB0WRRDDB1DB2DB3DB4DB5Systems Design and Programming Basic I/O III CMPE 3102 (April 14, 2002)UMBCU M B CUNIVERSITY OF MARYLAND BALTIMORE COUNTY1 9 6 6Pinout Definition 8279• A0: Selects data (0) or control/status (1) for reads and writes betweenmicro and 8279.• BD: Output that blanks the displays.• CLK: Used internally for timing. Max is 3 MHz.• CN/ST: Control/strobe, connected to the control key on the keyboard.•CS: Chip select that enables programming, reading the keyboard, etc.• DB7-DB0: Consists of bidirectional pins that connect to data bus on micro.• IRQ: Interrupt request, becomes 1 when a key is pressed, data is available.• OUT A3-A0/B3-B0: Outputs that sends data to the most significant/leastsignificant nibble of display.•RD(WR): Connects to micro’s IORC or RD signal, reads data/status regis-ters.• RESET: Connects to system RESET.• RL7-RL0: Return lines are inputs used to sense key depression in the key-board matrix.• Shift: Shift connects to Shift key on keyboard.• SL3-SL0: Scan line outputs scan both the keyboard and displays.Systems Design and Programming Basic I/O III CMPE 3103 (April 14, 2002)UMBCU M B CUNIVERSITY OF MARYLAND BALTIMORE COUNTY1 9 6 68279 Interfaced to the 80888279A0CSBDOA3OA2OA1OA0OB3OB2OB1OB0SL0SL1SL2SL3SHIFTCN/STRL0RL1DB7DB6RESETRL7RL6RL5RL4IRQCLKRL3RL2DB0WRRDDB1DB2DB3DB4DB5D0-D7RDWRWait23.0 MHzRESETA0I1I2I3I4I5I6I7I8I9I1016L8O1O2O3O4O5O6O7O8A1A2A3A4A5A6A7IO/MDecoded at 10H (data) 11H (control)Introduces2 wait statesto work with8MHz 8088Systems Design and Programming Basic I/O III CMPE 3104 (April 14, 2002)UMBCU M B CUNIVERSITY OF MARYLAND BALTIMORE COUNTY1 9 6 6Keyboard Interface of 82798279A0CSBDOA3OA2OA1OA0OB3OB2OB1OB0SL3SL2SL1SL0SHIFTCN/STRL0RL1DB7DB6RESETRL7RL6RL5RL4IRQCLKRL3RL2DB0WRRDDB1DB2DB3DB4DB5D0-D7RDWRWait23.0 MHzRESETA0I1I2I3I4I5I6I7I8I9I1016L8O1O2O3O4O5O6O7O8A1A2A3A4A5A6A7IO/MG2AG2BG1ABC0123456710K64 Key Matrix(Normally open74ALS138switches)Systems Design and Programming Basic I/O III CMPE 3105 (April 14, 2002)UMBCU M B CUNIVERSITY OF MARYLAND BALTIMORE COUNTY1 9 6 6Keyboard Interface of 8279The keyboard matrix can be any size from 2x2 to 8x8.Pins SL2-SL0 sequentially scan each column through a counting operation.The 74LS138 drives 0’s on one line at a time.The 8279 scans RL pins synchronously with the scan.RL pins incorporate internal pull-ups, no need for external resistor pull-ups.Unlike the 82C55, the 8279 must be programmed fi rst.The fi rst 3 bits of # sent to control port selects one of 8 control words.D7D6D5Function Purpose0 0 0 Mode set Selects the number of display positions, type of key scan...0 0 1 Clock Programs internal clk, sets scan and debounce times.0 1 0 Read FIFO Selects type of FIFO read and address of the read.0 1 1 Read Display Selects type of display read and address of the read.1 0 0 Write Display Selects type of write and the address of the write.1 0 1 Display write inhibit Allows half-bytes to be blanked.1 1 0 Clear Clears the display or FIFO1 1 1 End interrupt Clears the IRQ signal to the microprocessor.Systems Design and Programming Basic I/O III CMPE 3106 (April 14, 2002)UMBCU M B CUNIVERSITY OF MARYLAND BALTIMORE COUNTY1 9 6 6Keyboard Interface of 8279First three bits given below select one of 8 control registers (opcode).000DDMMMMode set: Opcode 000.DD sets displays mode.MMM sets keyboard mode.DD fi eld selects either: 8- or 16-digit displayWhether new data are entered to the rightmost or leftmost display posi-tion.DD Function00 8-digit display with left entry01 16-digit display with left entry10 8-digit display with right entry11 16-digit display with right entrySystems Design and Programming Basic I/O III CMPE 3107 (April 14, 2002)UMBCU M B CUNIVERSITY OF MARYLAND BALTIMORE COUNTY1 9 6 6Keyboard Interface of 8279MMM fi eld:Encoded: Sl outputs are active-high, follow binary bit pattern 0-7 or 0-15.Decoded: SL outputs are active-low (only one low at any time).Pattern output: 1110, 1101, 1011, 0111.Strobed: An active high pulse on the CN/ST input pin strobes data fromthe RL pins into an internal FIFO for reading by micro later.2-key lockout/N-key rollover: Prevents 2 keys from being recognized ifpressed simultaneously/Accepts all keys pressed from 1st to last.DD Function000 Encoded keyboard with 2-key lockout001 Decoded keyboard with 2-key lockout010 Encoded keyboard with N-key rollover011 Decoded keyboard with N-key rollover100 Encoded sensor matrix101 Decoded sensor matrix110 Strobed keyboard, encoded display scan111 Strobed keyboard, decoded display scanSystems Design and Programming Basic I/O III CMPE 3108 (April 14, 2002)UMBCU M B CUNIVERSITY OF MARYLAND BALTIMORE COUNTY1 9 6 6Interface of 8279001PPPPPThe clock command word programs the internal clock driver.The code PPPPP divides the clock input pin (CLK) to achieve the desiredoperating frequency, e.g. 100KHz requires 01010 for a 1 MHz CLKinput.010Z0AAAThe read FIFO control word selects the address (AAA) of a keystroke fromthe FIFO buffer (000 to 111).Z selects auto-increment for the address.011ZAAAAThe display read control word selects the read address of one of the displayRAM positions for reading through the data port.100ZAAAASelects write address -- Z selects auto-increment so subsequent writes goto subsequent display positions.Systems Design and Programming Basic I/O III CMPE 3109 (April 14, 2002)UMBCU M B CUNIVERSITY OF MARYLAND BALTIMORE COUNTY1 9 6 6Interface of 82791010WWBBThe display write inhibit control word inhibits writing to either the leftmost4 bits of the display (left W) or rightmost 4 bits.BB works similarly except that they blank (turn off) half of the outputpins.1100CCFAThe clear control word clears the display, FIFO or bothBit F clears FIFO and the display RAM status, and sets address pointer to000.If CC are 00 or 01, all display RAM locations become


View Full Document

UNM CMPE 310 - CMPE 310 Basic I/O III

Download CMPE 310 Basic I/O III
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view CMPE 310 Basic I/O III and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view CMPE 310 Basic I/O III 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?