|
| Input/Output Interfaces |
|
|
|
|
| Table |
|
| CPU Commands to the 8042 |
|
|
|
| Value | Command Description |
|
|
|
| A9h | Test the clock and data lines of the pointing device interface and place test results in the output |
|
| buffer. |
|
| 00h = No error detected |
|
| 01h = Clock line stuck low |
|
| 02h = Clock line stuck high |
|
| 03h = Data line stuck low |
|
| 04h = Data line stuck high |
|
|
|
| AAh | Initialization. This command causes the 8042 to inhibit the keyboard and pointing device and |
|
| places 55h into the output buffer. |
|
|
|
| ABh | Test the clock and data lines of the keyboard interface and place test results in the output buffer. |
|
| 00h = No error detected |
|
| 01h = Clock line stuck low |
|
| 02h = Clock line stuck high |
|
| 03h = Data line stuck low |
|
| 04h = Data line stuck high |
|
|
|
| ADh | Disable keyboard command (sets bit <4> of the 8042 command byte). |
|
|
|
| AEh | Enable keyboard command (clears bit <4> of the 8042 command byte). |
|
|
|
| C0h | Read input port of the 8042. This command directs the 8042 to transfer the contents of the input |
|
| port to the output buffer so that they can be read at port 60h. |
|
|
|
| C2h | Poll Input Port High. This command directs the 8042 to place bits <7..4> of the input port into the |
|
| upper half of the status byte on a continous basis until another command is received. |
|
|
|
| C3h | Poll Input Port Low. This command directs the 8042 to place bits <3..0> of the input port into the |
|
| lower half of the status byte on a continous basis until another command is received. |
|
|
|
| D0h | Read output port. This command directs the 8042 to transfer the contents of the output port to the |
|
| output buffer so that they can be read at port 60h. |
|
|
|
| D1h | Write output port. This command directs the 8042 to place the next byte written to port 60h into |
|
| the output port (only bit <1> can be changed). |
|
|
|
| D2h | Echo keyboard data. Directs the 8042 to send back to the CPU the next byte written to port 60h |
|
| as if it originated from the keyboard. No |
|
| (IRQ1) is generated if enabled. |
|
|
|
| D3h | Echo pointing device data. Directs the 8042 to send back to the CPU the next byte written to port |
|
| 60h as if it originated from the pointing device. An interrupt (IRQ12) is generated if enabled. |
|
|
|
| D4h | Write to pointing device. Directs the 8042 to send the next byte written to 60h to the pointing |
|
| device. |
|
|
|
| E0h | Read test inputs. Directs the 8042 to transfer the test bits 1 and 0 into bits <1,0> of the output |
|
| buffer. |
|
|
|
| Pulse output port. Controls the pulsing of bits <3..0> of the output port (0 = pulse, 1 = don’t | |
|
| pulse). Note that pulsing bit <0> will reset the system. |
|
|
|
Technical Reference Guide |