I/O Port Detail
This detailed information covers some I/O ports that are not detailed
elsewhere.
Note: All IN and OUT examples are for 8-bit I/O
(e.g., OUT 70H,0 really means MOV al,0; OUT 70H,al)
Port Description
▀▀▀▀▀ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
000H-
01fH DMA (Direct Memory Access) controller See DMA Ports
──── ──────────────────────────────────────────────────────────────────────
020H-
03fH Interrupt Controller. See Interrupt Controller Ports
──── ──────────────────────────────────────────────────────────────────────
040H-
043H 8253 Timer chip. See Timer Ports
──── ──────────────────────────────────────────────────────────────────────
060H PC/XT (Programmable Peripheral Interface) port A. Read keyboard:
IN al,60H ;fetches most recent scan code. See INT 09H
See Scan Code
AT keyboard data register. See AT Keyboard
061H-
063H PC/XT PPI Command/Mode Register. See PPI Ports.
──── ──────────────────────────────────────────────────────────────────────
064H AT keyboard command register. This port communicates with the 8042
which runs an on-chip control program for the keyboard. It accepts
command codes and data bytes.
For commands and programming details, See AT Keyboard
──── ──────────────────────────────────────────────────────────────────────
070H AT register address (write-only) for Real-Time Clock and CMOS RAM.
070H AT NMI mask. Use this port to mask the Non-maskable Interrupt.
An OUT with bit 7=0 enables the NMI; with bit 7=1 disables NMI:
OUT 70H,2dH ;enable NMI--2dH is a reserved addr in the CMOS Memory
OUT 70H,0adH ;disable NMI
──── ──────────────────────────────────────────────────────────────────────
080H AT page register used during POST to accumulate errors
──── ──────────────────────────────────────────────────────────────────────
081H-
08fH DMA page registers See DMA Ports
──── ──────────────────────────────────────────────────────────────────────
0a0H PC/XT NMI mask. Enable/disable Non-maskable Int (RAM parity err)
OUT 0a0H,80H ;enable NMI
OUT 0a0H,0 ;disable NMI
──── ──────────────────────────────────────────────────────────────────────
0c0H-
0dfH AT DMA controller access to 16-bit DMA See DMA Ports
──── ──────────────────────────────────────────────────────────────────────
0f0H AT 80287 latch clear. 'Busy' gets latched upon an unmasked 287 error.
OUT 0f0H,0 ;clears the latch
0f1H AT 80287 Reset. Coprocessor is reset from protected mode to real mode
OUT 0f1H,0 ;resets the 80287 to real mode
0f8H-
0fcH AT 80287 data. 286 sends opcodes & operands and receives results.
──── ──────────────────────────────────────────────────────────────────────
170H-
177H AT hard disk controller #2 See AT Hard Disk Ports
──── ──────────────────────────────────────────────────────────────────────
1f0H-
1f7H AT hard disk controller #1 See AT Hard Disk Ports
──── ──────────────────────────────────────────────────────────────────────
210H XT Expansion chassis control port
213H XT Expansion chassis enable
215H XT Expansion chassis data bus register
215H XT Expansion chassis address register (high byte)
216H XT (low byte)
──── ──────────────────────────────────────────────────────────────────────
278H-
27fH Parallel Printer Adapter #2 See Printer Ports
──── ──────────────────────────────────────────────────────────────────────
2e8H-
2efH Asynchronous Communications Adapter COM4. See Serial Ports
──── ──────────────────────────────────────────────────────────────────────
2f8H-
2ffH Asynchronous Communications Adapter COM2. See Serial Ports
──── ──────────────────────────────────────────────────────────────────────
320H-
32fH XT hard disk controller. See XT Hard Disk Ports
──── ──────────────────────────────────────────────────────────────────────
2c0H-
2cfH Enhanced Graphics Adapter (EGA) #2. See EGA I/O Ports
──── ──────────────────────────────────────────────────────────────────────
378H-
37fH Parallel Printer Adapter #1 See Printer Ports
──── ──────────────────────────────────────────────────────────────────────
3b4H- Monochrome Display Adapter (MDA) display control ports.
3baH See CGA I/O Ports for a summary of usage of the 6854 CRT controller.
The MDA has few capabilities beyond it's single standard display mode.
──── ──────────────────────────────────────────────────────────────────────
3bcH-
3bdH Parallel Printer on MDA See Printer Ports
──── ──────────────────────────────────────────────────────────────────────
3b0H-
3dfH Video Graphics Array (VGA) See VGA I/O Ports
3c0H-
3dfH Enhanced Graphics Adapter (EGA) See EGA I/O Ports
3d2H-
3dcH Color/Graphics Adapter (CGA) See CGA I/O Ports
──── ──────────────────────────────────────────────────────────────────────
3e8H- asynchronous communications adapter COM3.
3efH See Serial Ports
──── ──────────────────────────────────────────────────────────────────────
3f0H-
3f7H diskette drive controller (aka FDC) See FDC Ports
──── ──────────────────────────────────────────────────────────────────────
3f8H- asynchronous communications adapter COM1.
3ffH See Serial Ports
──── ──────────────────────────────────────────────────────────────────────
See Also: I/O Port Map
BIOS Data Area
Interrupts and BIOS Services
Cables and Pin Outs
-♦-