“PS2 Keyboard”的版本间差异

来自osdev
跳到导航 跳到搜索
(创建页面,内容为“== 概述 == PS/2键盘是一种使用 串行通信 与PS/2控制器对话的设备。 理想情况下,每种不同类型的PS/2控制器驱动程序都应提供某种标准/简单的 “发送字节/接收字节” 接口,PS/2键盘驱动程序将使用此接口,而无需关心较低级别的详细信息 (例如设备插入的PS/2控制器类型)。 PS/2键盘接受命令并发送对这些命令的响应,还发送指示何时按下或释…”)
 
(重定向页面至PS/2 Keyboard
标签新建重定向
 
(未显示同一用户的2个中间版本)
第1行: 第1行:
== 概述 ==
#REDIRECT [[PS/2 Keyboard]]
 
PS/2键盘是一种使用 [[PS/2 | 串行通信]] 与PS/2控制器对话的设备。 理想情况下,每种不同类型的PS/2控制器驱动程序都应提供某种标准/简单的 “发送字节/接收字节” 接口,PS/2键盘驱动程序将使用此接口,而无需关心较低级别的详细信息 (例如设备插入的PS/2控制器类型)。
 
PS/2键盘接受命令并发送对这些命令的响应,还发送指示何时按下或释放键的扫描代码。 请记住,这些扫描代码 (来自下表) 可以由PS/2控制器更改 (即翻译),具体取决于控制器的设置。
 
== 命令 ==
 
PS/2键盘接受许多类型的命令。 一个命令是一个字节。 某些命令具有多个数据byte,必须在命令byte之后发送。 键盘通常通过发送 “ACK” (确认命令) 或 “重新发送” (说上一个命令有问题) 来响应命令。 不要忘记在命令,数据和键盘响应之间等待。
 
PS/2键盘接受的命令是:
 
{| {{wikitable}}
|-
! 命令字节
! 多数据字节
! 含义
! 响应
|-
| 0xED
| LED状态:
    {| {{wikitable}}
    |-
    ! Bit
    ! Use
    |-
    | 0
    | ScrollLock
    |-
    | 1
    | NumberLock
    |-
    | 2
    | CapsLock
    |}
注意: 其他位可以在国际键盘中用于其他目的 (例如,日本键盘可能将位4用于 “假名模式” LED)。
| Set LEDs
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xEE
| None
| Echo (用于诊断目的,对于设备移除检测很有用)
| 0xEE (Echo) or 0xFE (Resend)
|-
| 0xF0
| Sub-command:
    {| {{wikitable}}
    |-
    ! Value
    ! Use
    |-
    | 0
    | Get current scan code set
    |-
    | 1
    | Set scan code set 1
    |-
    | 2
    | Set scan code set 2
    |-
    | 3
    | Set scan code set 3
    |}
| 获取/设置当前扫描代码集
| 0xFA (ACK) 或0xFE (Resend重新发送) (如果扫描代码已设置); 0xFA (ACK) 然后扫描代码设置编号,或者0xFE (重新发送) (如果你正在获取扫描代码)
|-
| 0xF2
| None
| 识别键盘
| 0xFA (ACK) 后跟零或多个ID字节 (参见 [["8042" PS/2 Controller#Detecting PS.2F2 Device Types | "检测设备类型"]])
|-
| 0xF3
| 类型字节:
    {| {{wikitable}}
    |-
    ! Bit/s
    ! 含义
    |-
    | 0 to 4
    | 返回频率 (00000b = 30Hz,...,11111b = 2Hz)
    |-
    | 5 to 6
    | 键重复之前的延迟 (00b = 250 ms,01b = 500 ms,10b = 750 ms,11b = 1000 ms)
    |-
    | 7
    | Must be zero
    |}
| 设置类型速率和延迟
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xF4
| None
| 启用扫描 (键盘会发送扫描码)
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xF5
| None
| 禁用扫描 (键盘不会发送扫描代码)
注意: 也可以恢复默认参数
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xF6
| None
| 设置默认参数
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xF7
| None
| 将所有键设置为仅typematic/autorepeat (仅scancode Set 3)
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xF8
| None
| 将所有键设置为make/release (仅scancode Set 3)
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xF9
| None
| 将所有键设置为仅make (仅scancode Set 3)
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xFA
| None
| 将所有键设置为 typeatic/autorepeat/mae/release (仅scancode Set 3)
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xFB
| 键扫描代码
| 将特定键设置为仅typematic/autorepeat (仅scancode Set 3)
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xFC
| 键扫描代码
| 设置要制作/释放的特定键 (仅scancode Set 3)
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xFD
| 键扫描代码
| 将特定键设置为仅使 (仅scancode Set 3)
| 0xFA (ACK) or 0xFE (Resend)
|-
| 0xFE
| None
| 重新发送最后一个字节
| 先前发送的字节或0xFE (重新发送)
|-
| 0xFF
| None
| 重置并开始自检
| 0xAA (self-test passed), 0xFC or 0xFD (self test failed), or 0xFE (Resend)
|}
 
== 特殊字节 ==
 
键盘向系统发送字节。 其中一些字节具有特殊含义 (例如,来自上述命令的响应)。 键盘可能发送的字节是:
 
{| {{wikitable}}
|-
! 响应字节
! 含义
|-
| 0x00
| 键检测错误或内部缓冲区溢出
|-
| 0xAA
| 自检通过 (在 “0xFF (reset)” 命令或键盘加电后发送)
|-
| 0xEE
| 对 “0xEE (echo)” 命令的响应
|-
| 0xFA
| 命令确认 (ACK)
|-
| 0xFC and 0xFD
| 自检失败 (在 “0xFF (reset)” 命令或键盘加电后发送)
|-
| 0xFE
| 重新发送 (键盘希望控制器重复它发送的最后一个命令)
|-
| 0xFF
| 键检测错误或内部缓冲区溢出
|}
 
键盘发送的所有其他字节都是扫描码,其中解释取决于当前选择的扫描代码集。
 
== 驱动程序模型 ==
 
=== 命令队列和状态机 ===
 
命令必须一次发送一个 (例如,如果你的驱动程序是中断驱动的,则无法在IRQ处理程序中开始发送命令,因为IRQ处理程序之外的代码可能正在发送命令的中间)。 直到你收到确认后,该命令才完成。 例如,如果你发送命令,并且键盘以 “0xFE (重新发送)” 作为响应,那么你必须再次发送命令 (可能在你放弃之前限制为3次重试,并假设键盘不支持你正在发送的命令或出现硬件故障)。最后,有时你想一次发送几个命令。 例如,你可能有一个 “reinitialise()” 函数,该函数设置扫描代码集,设置typematic字节,设置led并启用扫描。
 
实现这一目标的最简单方法是驱动程序维护命令队列。 将命令添加到队列时,如果队列为空,则开始发送命令; 否则,将命令附加到队列。 当你从键盘收到 “0xFA (ACK)” 时,你会丢弃队列头部的命令,并开始发送队列中的下一个命令 (如果有)。 如果你从键盘收到 “0xFE (重新发送)”,则可以在队列的头部重新发送命令。
 
驱动程序的剩余部分应该是一种状态机。 当一些命令成功完成时,以及当从键盘接收到各种字节时,状态机进入不同的状态。 例如,驱动程序可能处于默认状态,并且接收到中断代码,该中断代码将其置于 “接收到中断代码后等待扫描代码” 状态。 然后,它可能会接收多字节扫描代码的第一个字节,并切换到 “在接收中断代码后等待第二个字节扫描代码” 状态。 最后,它可能会接收扫描代码的第二个/最后一个字节,然后切换回默认状态。
 
 
=== 扫码集、扫码和键码 ===
 
扫描代码集是一组代码,用于确定何时按下或重复或释放某个键。 有3组不同的扫描码。 最老的是 “扫码集1”,默认是 “扫码集2”,还有更新的 (更复杂的) “扫码集3”。 ''注意: 通常在PC兼容系统上,键盘本身使用扫描代码集2,并且键盘控制器将其转换为扫描代码集1以实现兼容性。 有关此翻译的更多信息,请参阅 [["8042"_PS/2_Controller#Translation| "8042" _ PS/2 _ 控制器]]。''
 
现代键盘应该支持所有三个扫描代码集,但是有些则不支持。 扫描代码集2 (默认值) 是唯一保证支持的扫描代码集。 从理论上讲 (我还没有尝试过),应该可以尝试设置扫描代码集1或扫描代码集3,然后询问键盘当前正在使用哪个扫描代码,看看它是否实际上正在使用请求的扫描代码集。 以这种方式,可以确定键盘确实支持哪个扫描代码集。
 
扫描码本身是一个或多个字节的序列。 在某些情况下,序列可以多达6个字节 (例如,扫描代码集1中的暂停/中断键
按下时生成序列0xE1,0x1D,0x45,0xE1,0x9D,0xC5)。 这种情况并不理想。 通常 (用于以后的处理),你希望将这些 “一个或多个字节序列” 转换为唯一标识特定键的单个整数,可以在诸如查找表之类的事情中有效使用 (无需稀疏使用 “许多GiB” 查找表)。
 
“关键代码” 没有标准 - 这是你必须为操作系统弥补或发明的东西。 我个人喜欢有一个8位键代码的想法,其中最高的3位确定键盘上的哪一行,最低的5位确定哪一列 (本质上,键盘被视为最多8行和最多32列键的网格)。 无论你选择使用什么键代码,它都应该是所有键盘驱动程序 (包括USB键盘) 使用的东西,也可能用于其他输入设备 (例如,鼠标左键可能被视为 “键代码0xF1”)。
 
基本上,当键盘驱动程序的状态机知道它已经收到完整的扫描代码时,下一步就是将 “一个或多个字节” 的扫描代码转换为键代码。
 
=== 键代码、键状态和键映射 ===
 
一旦有了键代码,下一步就是跟踪当前正在按下的键。 想象一个使用 “WASD” 键进行玩家移动的计算机游戏-按下 “a” 键时,玩家会顺时针旋转。 游戏如何知道当前是否正在按下 “a” 键?为此,你需要一个标志数组,其中每个标志对应于一个关键代码。 这里有一个隐藏的奖励-键盘驱动程序本身可以使用相同的 “标志数组” 来确定shift键,控制键,alt键等是否关闭,这在尝试将键代码转换为实际的ASCII字符或Unicode代码点时非常有用。 例如,如果用户按下 “a” 键,则它可能对应于 “a” 或 “a” (取决于capslock状态以及当时是否按住shift键),或者可能根本不对应于有效字符 (例如 “control-a” 或 “alt-a” “)。
 
还要注意 (例如) “WASD” 游戏不在乎键是否为 'W','A','S' 和 'D'。 游戏希望了解键盘左侧特定 “t形” 图案的按键。 如果键盘恰好是不同的东西,那么在同一位置的键可能是完全不同的 (例如,它们将是德沃夏克键盘上的 '<' 、 'a' 、 'o' 和 'e' 键)。 这有助于解释我的偏好有一个8位键代码,其中最高的3位决定键盘上的哪一行,最低的5位决定哪一列 (这很容易让游戏询问第三行左边的第三个键的状态)。
 
一旦能够跟踪当前正在按下的键,下一步就是 (尝试) 将键转换为ASCII字符或Unicode代码点。 在这一点上,你需要知道用户拥有哪种类型的键盘-是 “US QWERTY” 还是 “French AZERTY”,某种形式的Dvorak,还是阿拉伯语。 要处理许多不同的键盘布局,键盘驱动程序需要使用表格将键代码转换为ASCII字符或Unicode代码点; 因此,你只需要加载不同的 “键映射” 表即可支持不同的键盘布局。
 
然而,事情并不是那么简单。 不同的键盘布局可以有不同的元键、不同的状态发光二极管等。 键映射表也必须对这些差异进行排序。 这就是为什么你不想检测键盘发光二极管是否更早发生了变化,而是希望在你在键映射表中找到键代码的条目后发送 “设置发光二极管” 命令 (如有必要)。
 
处理的最后一步是将所有相关信息组合成某种 “keypress数据包” 结构,并将其发送给任何人 (例如GUI)。 整个 “keypress数据包” 可能包括以下内容:
* Unicode码点 (如适用)
* 关键代码
* 按下/释放标志
* 各种其他关键状态 (移位、alt、控制等)
* 各种 “切换” 状态 (CapsLock、ScrollLock、NumberLock等)
 
== 扫描代码集 ==
 
由于有3个不同的扫描代码集,因此有3个不同的表 (每个扫描代码集一个)。 一些扫描代码对应于随着时间的推移而添加的额外键,并且变得 “相对标准”。 为了帮助保持跟踪,扫描代码已在下表中进行了分类和标记。 使用的标签是:
 
{| {{wikitable}}
|-
! 标签
! 含义
|-
| (keypad)
| 数字键盘上的键 (通常在键盘的右侧找到)。
|-
| (ACPI)
| 是 “ACPI” 键组的一部分的键 (通常在键盘顶部附近找到)。 许多现代键盘实际上没有这些键 (如果我没记错的话,它们在20世纪90年代末很流行,但此后变得不那么普遍了)。
注意: 不要让这个名字愚弄你-这些键与ACPI完全无关,并且表现得像任何其他普通键 (但对于支持电源管理的操作系统可能有用)。
|-
| (多媒体)
| 是多媒体键组的一部分的键 (通常在键盘顶部附近找到)。 许多现代键盘确实至少有一些这样的键。 这些键中的一些用于媒体播放器 (音量控制、播放/暂停、下一首曲目、上一首曲目等),一些用于网络浏览 (上一个网页、下一个网页、刷新、收藏夹/书签等),和一些用于启动应用程序 (例如,启动电子邮件客户端,启动计算器,打开 “我的电脑” 等)。
|}
 
 
=== 扫描代码集1 ===
 
下表显示了使用扫描代码集1 (仅适用于 “US QWERTY” 键盘) 时,哪些扫描代码对应于哪些键:
 
{| {{wikitable}}
|-
! Scan code
! Key
! style="background: #E8E8E8" | Scan code
! style="background: #E8E8E8" | Key
! Scan code
! Key
! style="background: #E8E8E8" | Scan code
! style="background: #E8E8E8" | Key
|-
|
|
| style="background: #E8E8E8" align="right" | 0x01
| style="background: #E8E8E8" | escape pressed
| align="right" | 0x02
| 1 pressed
| style="background: #E8E8E8" align="right" | 0x03
| style="background: #E8E8E8" | 2 pressed
|-
| align="right" | 0x04
| 3 pressed
| style="background: #E8E8E8" align="right" | 0x05
| style="background: #E8E8E8" | 4 pressed
| align="right" | 0x06
| 5 pressed
| style="background: #E8E8E8" align="right" | 0x07
| style="background: #E8E8E8" | 6 pressed
|-
| align="right" | 0x08
| 7 pressed
| style="background: #E8E8E8" align="right" | 0x09
| style="background: #E8E8E8" | 8 pressed
| align="right" | 0x0A
| 9 pressed
| style="background: #E8E8E8" align="right" | 0x0B
| style="background: #E8E8E8" | 0 (zero) pressed
|-
| align="right" | 0x0C
| - pressed
| style="background: #E8E8E8" align="right" | 0x0D
| style="background: #E8E8E8" | = pressed
| align="right" | 0x0E
| backspace pressed
| style="background: #E8E8E8" align="right" | 0x0F
| style="background: #E8E8E8" | tab pressed
|-
| align="right" | 0x10
| Q pressed
| style="background: #E8E8E8" align="right" | 0x11
| style="background: #E8E8E8" | W pressed
| align="right" | 0x12
| E pressed
| style="background: #E8E8E8" align="right" | 0x13
| style="background: #E8E8E8" | R pressed
|-
| align="right" | 0x14
| T pressed
| style="background: #E8E8E8" align="right" | 0x15
| style="background: #E8E8E8" | Y pressed
| align="right" | 0x16
| U pressed
| style="background: #E8E8E8" align="right" | 0x17
| style="background: #E8E8E8" | I pressed
|-
| align="right" | 0x18
| O pressed
| style="background: #E8E8E8" align="right" | 0x19
| style="background: #E8E8E8" | P pressed
| align="right" | 0x1A
| [ pressed
| style="background: #E8E8E8" align="right" | 0x1B
| style="background: #E8E8E8" | ] pressed
|-
| align="right" | 0x1C
| enter pressed
| style="background: #E8E8E8" align="right" | 0x1D
| style="background: #E8E8E8" | left control pressed
| align="right" | 0x1E
| A pressed
| style="background: #E8E8E8" align="right" | 0x1F
| style="background: #E8E8E8" | S pressed
|-
| align="right" | 0x20
| D pressed
| style="background: #E8E8E8" align="right" | 0x21
| style="background: #E8E8E8" | F pressed
| align="right" | 0x22
| G pressed
| style="background: #E8E8E8" align="right" | 0x23
| style="background: #E8E8E8" | H pressed
|-
| align="right" | 0x24
| J pressed
| style="background: #E8E8E8" align="right" | 0x25
| style="background: #E8E8E8" | K pressed
| align="right" | 0x26
| L pressed
| style="background: #E8E8E8" align="right" | 0x27
| style="background: #E8E8E8" | ; pressed
|-
| align="right" | 0x28
| ' (single quote) pressed
| style="background: #E8E8E8" align="right" | 0x29
| style="background: #E8E8E8" | ` (back tick) pressed
| align="right" | 0x2A
| left shift pressed
| style="background: #E8E8E8" align="right" | 0x2B
| style="background: #E8E8E8" | \ pressed
|-
| align="right" | 0x2C
| Z pressed
| style="background: #E8E8E8" align="right" | 0x2D
| style="background: #E8E8E8" | X pressed
| align="right" | 0x2E
| C pressed
| style="background: #E8E8E8" align="right" | 0x2F
| style="background: #E8E8E8" | V pressed
|-
| align="right" | 0x30
| B pressed
| style="background: #E8E8E8" align="right" | 0x31
| style="background: #E8E8E8" | N pressed
| align="right" | 0x32
| M pressed
| style="background: #E8E8E8" align="right" | 0x33
| style="background: #E8E8E8" | , pressed
|-
| align="right" | 0x34
| . pressed
| style="background: #E8E8E8" align="right" | 0x35
| style="background: #E8E8E8" | / pressed
| align="right" | 0x36
| right shift pressed
| style="background: #E8E8E8" align="right" | 0x37
| style="background: #E8E8E8" | (keypad) * pressed
|-
| align="right" | 0x38
| left alt pressed
| style="background: #E8E8E8" align="right" | 0x39
| style="background: #E8E8E8" | space pressed
| align="right" | 0x3A
| CapsLock pressed
| style="background: #E8E8E8" align="right" | 0x3B
| style="background: #E8E8E8" | F1 pressed
|-
| align="right" | 0x3C
| F2 pressed
| style="background: #E8E8E8" align="right" | 0x3D
| style="background: #E8E8E8" | F3 pressed
| align="right" | 0x3E
| F4 pressed
| style="background: #E8E8E8" align="right" | 0x3F
| style="background: #E8E8E8" | F5 pressed
|-
| align="right" | 0x40
| F6 pressed
| style="background: #E8E8E8" align="right" | 0x41
| style="background: #E8E8E8" | F7 pressed
| align="right" | 0x42
| F8 pressed
| style="background: #E8E8E8" align="right" | 0x43
| style="background: #E8E8E8" | F9 pressed
|-
| align="right" | 0x44
| F10 pressed
| style="background: #E8E8E8" align="right" | 0x45
| style="background: #E8E8E8" | NumberLock pressed
| align="right" | 0x46
| ScrollLock pressed
| style="background: #E8E8E8" align="right" | 0x47
| style="background: #E8E8E8" | (keypad) 7 pressed
|-
| align="right" | 0x48
| (keypad) 8 pressed
| style="background: #E8E8E8" align="right" | 0x49
| style="background: #E8E8E8" | (keypad) 9 pressed
| align="right" | 0x4A
| (keypad) - pressed
| style="background: #E8E8E8" align="right" | 0x4B
| style="background: #E8E8E8" | (keypad) 4 pressed
|-
| align="right" | 0x4C
| (keypad) 5 pressed
| style="background: #E8E8E8" align="right" | 0x4D
| style="background: #E8E8E8" | (keypad) 6 pressed
| align="right" | 0x4E
| (keypad) + pressed
| style="background: #E8E8E8" align="right" | 0x4F
| style="background: #E8E8E8" | (keypad) 1 pressed
|-
| align="right" | 0x50
| (keypad) 2 pressed
| style="background: #E8E8E8" align="right" | 0x51
| style="background: #E8E8E8" | (keypad) 3 pressed
| align="right" | 0x52
| (keypad) 0 pressed
| style="background: #E8E8E8" align="right" | 0x53
| style="background: #E8E8E8" | (keypad) . pressed
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0x57
| style="background: #E8E8E8" | F11 pressed
|-
| align="right" | 0x58
| F12 pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0x81
| style="background: #E8E8E8" | escape released
| align="right" | 0x82
| 1 released
| style="background: #E8E8E8" align="right" | 0x83
| style="background: #E8E8E8" | 2 released
|-
| align="right" | 0x84
| 3 released
| style="background: #E8E8E8" align="right" | 0x85
| style="background: #E8E8E8" | 4 released
| align="right" | 0x86
| 5 released
| style="background: #E8E8E8" align="right" | 0x87
| style="background: #E8E8E8" | 6 released
|-
| align="right" | 0x88
| 7 released
| style="background: #E8E8E8" align="right" | 0x89
| style="background: #E8E8E8" | 8 released
| align="right" | 0x8A
| 9 released
| style="background: #E8E8E8" align="right" | 0x8B
| style="background: #E8E8E8" | 0 (zero) released
|-
| align="right" | 0x8C
| - released
| style="background: #E8E8E8" align="right" | 0x8D
| style="background: #E8E8E8" | = released
| align="right" | 0x8E
| backspace released
| style="background: #E8E8E8" align="right" | 0x8F
| style="background: #E8E8E8" | tab released
|-
| align="right" | 0x90
| Q released
| style="background: #E8E8E8" align="right" | 0x91
| style="background: #E8E8E8" | W released
| align="right" | 0x92
| E released
| style="background: #E8E8E8" align="right" | 0x93
| style="background: #E8E8E8" | R released
|-
| align="right" | 0x94
| T released
| style="background: #E8E8E8" align="right" | 0x95
| style="background: #E8E8E8" | Y released
| align="right" | 0x96
| U released
| style="background: #E8E8E8" align="right" | 0x97
| style="background: #E8E8E8" | I released
|-
| align="right" | 0x98
| O released
| style="background: #E8E8E8" align="right" | 0x99
| style="background: #E8E8E8" | P released
| align="right" | 0x9A
| [ released
| style="background: #E8E8E8" align="right" | 0x9B
| style="background: #E8E8E8" | ] released
|-
| align="right" | 0x9C
| enter released
| style="background: #E8E8E8" align="right" | 0x9D
| style="background: #E8E8E8" | left control released
| align="right" | 0x9E
| A released
| style="background: #E8E8E8" align="right" | 0x9F
| style="background: #E8E8E8" | S released
|-
| align="right" | 0xA0
| D released
| style="background: #E8E8E8" align="right" | 0xA1
| style="background: #E8E8E8" | F released
| align="right" | 0xA2
| G released
| style="background: #E8E8E8" align="right" | 0xA3
| style="background: #E8E8E8" | H released
|-
| align="right" | 0xA4
| J released
| style="background: #E8E8E8" align="right" | 0xA5
| style="background: #E8E8E8" | K released
| align="right" | 0xA6
| L released
| style="background: #E8E8E8" align="right" | 0xA7
| style="background: #E8E8E8" | ; released
|-
| align="right" | 0xA8
| ' (single quote) released
| style="background: #E8E8E8" align="right" | 0xA9
| style="background: #E8E8E8" | ` (back tick) released
| align="right" | 0xAA
| left shift released
| style="background: #E8E8E8" align="right" | 0xAB
| style="background: #E8E8E8" | \ released
|-
| align="right" | 0xAC
| Z released
| style="background: #E8E8E8" align="right" | 0xAD
| style="background: #E8E8E8" | X released
| align="right" | 0xAE
| C released
| style="background: #E8E8E8" align="right" | 0xAF
| style="background: #E8E8E8" | V released
|-
| align="right" | 0xB0
| B released
| style="background: #E8E8E8" align="right" | 0xB1
| style="background: #E8E8E8" | N released
| align="right" | 0xB2
| M released
| style="background: #E8E8E8" align="right" | 0xB3
| style="background: #E8E8E8" | , released
|-
| align="right" | 0xB4
| . released
| style="background: #E8E8E8" align="right" | 0xB5
| style="background: #E8E8E8" | / released
| align="right" | 0xB6
| right shift released
| style="background: #E8E8E8" align="right" | 0xB7
| style="background: #E8E8E8" | (keypad) * released
|-
| align="right" | 0xB8
| left alt released
| style="background: #E8E8E8" align="right" | 0xB9
| style="background: #E8E8E8" | space released
| align="right" | 0xBA
| CapsLock released
| style="background: #E8E8E8" align="right" | 0xBB
| style="background: #E8E8E8" | F1 released
|-
| align="right" | 0xBC
| F2 released
| style="background: #E8E8E8" align="right" | 0xBD
| style="background: #E8E8E8" | F3 released
| align="right" | 0xBE
| F4 released
| style="background: #E8E8E8" align="right" | 0xBF
| style="background: #E8E8E8" | F5 released
|-
| align="right" | 0xC0
| F6 released
| style="background: #E8E8E8" align="right" | 0xC1
| style="background: #E8E8E8" | F7 released
| align="right" | 0xC2
| F8 released
| style="background: #E8E8E8" align="right" | 0xC3
| style="background: #E8E8E8" | F9 released
|-
| align="right" | 0xC4
| F10 released
| style="background: #E8E8E8" align="right" | 0xC5
| style="background: #E8E8E8" | NumberLock released
| align="right" | 0xC6
| ScrollLock released
| style="background: #E8E8E8" align="right" | 0xC7
| style="background: #E8E8E8" | (keypad) 7 released
|-
| align="right" | 0xC8
| (keypad) 8 released
| style="background: #E8E8E8" align="right" | 0xC9
| style="background: #E8E8E8" | (keypad) 9 released
| align="right" | 0xCA
| (keypad) - released
| style="background: #E8E8E8" align="right" | 0xCB
| style="background: #E8E8E8" | (keypad) 4 released
|-
| align="right" | 0xCC
| (keypad) 5 released
| style="background: #E8E8E8" align="right" | 0xCD
| style="background: #E8E8E8" | (keypad) 6 released
| align="right" | 0xCE
| (keypad) + released
| style="background: #E8E8E8" align="right" | 0xCF
| style="background: #E8E8E8" | (keypad) 1 released
|-
| align="right" | 0xD0
| (keypad) 2 released
| style="background: #E8E8E8" align="right" | 0xD1
| style="background: #E8E8E8" | (keypad) 3 released
| align="right" | 0xD2
| (keypad) 0 released
| style="background: #E8E8E8" align="right" | 0xD3
| style="background: #E8E8E8" | (keypad) . released
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xD7
| style="background: #E8E8E8" | F11 released
|-
| align="right" | 0xD8
| F12 released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x10
| (multimedia) previous track pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x19
| style="background: #E8E8E8" | (multimedia) next track pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x1C
| (keypad) enter pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x1D
| style="background: #E8E8E8" | right control pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x20
| (multimedia) mute pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x21
| style="background: #E8E8E8" | (multimedia) calculator pressed
| align="right" | 0xE0, 0x22
| (multimedia) play pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x24
| (multimedia) stop pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0x2E
| (multimedia) volume down pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x30
| (multimedia) volume up pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0x32
| (multimedia) WWW home pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x35
| style="background: #E8E8E8" | (keypad) / pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x38
| right alt (or altGr) pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x47
| style="background: #E8E8E8" | home pressed
|-
| align="right" | 0xE0, 0x48
| cursor up pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x49
| style="background: #E8E8E8" | page up pressed
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x4B
| style="background: #E8E8E8" | cursor left pressed
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x4D
| style="background: #E8E8E8" | cursor right pressed
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x4F
| style="background: #E8E8E8" | end pressed
|-
| align="right" | 0xE0, 0x50
| cursor down pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x51
| style="background: #E8E8E8" | page down pressed
| align="right" | 0xE0, 0x52
| insert pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x53
| style="background: #E8E8E8" | delete pressed
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x5B
| style="background: #E8E8E8" | left GUI pressed
|-
| align="right" | 0xE0, 0x5C
| right GUI pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x5D
| style="background: #E8E8E8" | "apps" pressed
| align="right" | 0xE0, 0x5E
| (ACPI) power pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x5F
| style="background: #E8E8E8" | (ACPI) sleep pressed
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x63
| style="background: #E8E8E8" | (ACPI) wake pressed
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x65
| style="background: #E8E8E8" | (multimedia) WWW search pressed
| align="right" | 0xE0, 0x66
| (multimedia) WWW favorites pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x67
| style="background: #E8E8E8" | (multimedia) WWW refresh pressed
|-
| align="right" | 0xE0, 0x68
| (multimedia) WWW stop pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x69
| style="background: #E8E8E8" | (multimedia) WWW forward pressed
| align="right" | 0xE0, 0x6A
| (multimedia) WWW back pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x6B
| style="background: #E8E8E8" | (multimedia) my computer pressed
|-
| align="right" | 0xE0, 0x6C
| (multimedia) email pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x6D
| style="background: #E8E8E8" | (multimedia) media select pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x90
| (multimedia) previous track released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x99
| style="background: #E8E8E8" | (multimedia) next track released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x9C
| (keypad) enter released
| style="background: #E8E8E8" align="right" | 0xE0, 0x9D
| style="background: #E8E8E8" | right control released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xA0
| (multimedia) mute released
| style="background: #E8E8E8" align="right" | 0xE0, 0xA1
| style="background: #E8E8E8" | (multimedia) calculator released
| align="right" | 0xE0, 0xA2
| (multimedia) play released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xA4
| (multimedia) stop released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0xAE
| (multimedia) volume down released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xB0
| (multimedia) volume up released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0xB2
| (multimedia) WWW home released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xB5
| style="background: #E8E8E8" | (keypad) / released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xB8
| right alt (or altGr) released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xC7
| style="background: #E8E8E8" | home released
|-
| align="right" | 0xE0, 0xC8
| cursor up released
| style="background: #E8E8E8" align="right" | 0xE0, 0xC9
| style="background: #E8E8E8" | page up released
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xCB
| style="background: #E8E8E8" | cursor left released
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xCD
| style="background: #E8E8E8" | cursor right released
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xCF
| style="background: #E8E8E8" | end released
|-
| align="right" | 0xE0, 0xD0
| cursor down released
| style="background: #E8E8E8" align="right" | 0xE0, 0xD1
| style="background: #E8E8E8" | page down released
| align="right" | 0xE0, 0xD2
| insert released
| style="background: #E8E8E8" align="right" | 0xE0, 0xD3
| style="background: #E8E8E8" | delete released
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xDB
| style="background: #E8E8E8" | left GUI released
|-
| align="right" | 0xE0, 0xDC
| right GUI released
| style="background: #E8E8E8" align="right" | 0xE0, 0xDD
| style="background: #E8E8E8" | "apps" released
| align="right" | 0xE0, 0xDE
| (ACPI) power released
| style="background: #E8E8E8" align="right" | 0xE0, 0xDF
| style="background: #E8E8E8" | (ACPI) sleep released
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xE3
| style="background: #E8E8E8" | (ACPI) wake released
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xE5
| style="background: #E8E8E8" | (multimedia) WWW search released
| align="right" | 0xE0, 0xE6
| (multimedia) WWW favorites released
| style="background: #E8E8E8" align="right" | 0xE0, 0xE7
| style="background: #E8E8E8" | (multimedia) WWW refresh released
|-
| align="right" | 0xE0, 0xE8
| (multimedia) WWW stop released
| style="background: #E8E8E8" align="right" | 0xE0, 0xE9
| style="background: #E8E8E8" | (multimedia) WWW forward released
| align="right" | 0xE0, 0xEA
| (multimedia) WWW back released
| style="background: #E8E8E8" align="right" | 0xE0, 0xEB
| style="background: #E8E8E8" | (multimedia) my computer released
|-
| align="right" | 0xE0, 0xEC
| (multimedia) email released
| style="background: #E8E8E8" align="right" | 0xE0, 0xED
| style="background: #E8E8E8" | (multimedia) media select released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x2A, 0xE0, 0x37
| style="background: #E8E8E8" | print screen pressed
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xB7, 0xE0, 0xAA
| style="background: #E8E8E8" | print screen released
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE1, 0x1D, 0x45, 0xE1, 0x9D, 0xC5
| style="background: #E8E8E8" | pause pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|}
 
 
Note: There is no scan code for "pause key released" (it behaves as if it is released as soon as it's pressed)
 
=== Scan Code Set 2 ===
 
The following table shows which "make" scan codes correspond to which keys when using scan code set 2 (for a "US QWERTY" keyboard only):
 
{| {{wikitable}}
|-
! Scan code
! Key
! style="background: #E8E8E8" | Scan code
! style="background: #E8E8E8" | Key
! Scan code
! Key
! style="background: #E8E8E8" | Scan code
! style="background: #E8E8E8" | Key
|-
|
|
| style="background: #E8E8E8" align="right" | 0x01
| style="background: #E8E8E8" | F9 pressed
|
|
| style="background: #E8E8E8" align="right" | 0x03
| style="background: #E8E8E8" | F5 pressed
|-
| align="right" | 0x04
| F3 pressed
| style="background: #E8E8E8" align="right" | 0x05
| style="background: #E8E8E8" | F1 pressed
| align="right" | 0x06
| F2 pressed
| style="background: #E8E8E8" align="right" | 0x07
| style="background: #E8E8E8" | F12 pressed
|-
|
|
| style="background: #E8E8E8" align="right" | 0x09
| style="background: #E8E8E8" | F10 pressed
| align="right" | 0x0A
| F8 pressed
| style="background: #E8E8E8" align="right" | 0x0B
| style="background: #E8E8E8" | F6 pressed
|-
| align="right" | 0x0C
| F4 pressed
| style="background: #E8E8E8" align="right" | 0x0D
| style="background: #E8E8E8" | tab pressed
| align="right" | 0x0E
| ` (back tick) pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0x11
| style="background: #E8E8E8" | left alt pressed
| align="right" | 0x12
| left shift pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0x14
| left control pressed
| style="background: #E8E8E8" align="right" | 0x15
| style="background: #E8E8E8" | Q pressed
| align="right" | 0x16
| 1 pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0x1A
| Z pressed
| style="background: #E8E8E8" align="right" | 0x1B
| style="background: #E8E8E8" | S pressed
|-
| align="right" | 0x1C
| A pressed
| style="background: #E8E8E8" align="right" | 0x1D
| style="background: #E8E8E8" | W pressed
| align="right" | 0x1E
| 2 pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0x21
| style="background: #E8E8E8" | C pressed
| align="right" | 0x22
| X pressed
| style="background: #E8E8E8" align="right" | 0x23
| style="background: #E8E8E8" | D pressed
|-
| align="right" | 0x24
| E pressed
| style="background: #E8E8E8" align="right" | 0x25
| style="background: #E8E8E8" | 4 pressed
| align="right" | 0x26
| 3 pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0x29
| style="background: #E8E8E8" | space pressed
| align="right" | 0x2A
| V pressed
| style="background: #E8E8E8" align="right" | 0x2B
| style="background: #E8E8E8" | F pressed
|-
| align="right" | 0x2C
| T pressed
| style="background: #E8E8E8" align="right" | 0x2D
| style="background: #E8E8E8" | R pressed
| align="right" | 0x2E
| 5 pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0x31
| style="background: #E8E8E8" | N pressed
| align="right" | 0x32
| B pressed
| style="background: #E8E8E8" align="right" | 0x33
| style="background: #E8E8E8" | H pressed
|-
| align="right" | 0x34
| G pressed
| style="background: #E8E8E8" align="right" | 0x35
| style="background: #E8E8E8" | Y pressed
| align="right" | 0x36
| 6 pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0x3A
| M pressed
| style="background: #E8E8E8" align="right" | 0x3B
| style="background: #E8E8E8" | J pressed
|-
| align="right" | 0x3C
| U pressed
| style="background: #E8E8E8" align="right" | 0x3D
| style="background: #E8E8E8" | 7 pressed
| align="right" | 0x3E
| 8 pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0x41
| style="background: #E8E8E8" | , pressed
| align="right" | 0x42
| K pressed
| style="background: #E8E8E8" align="right" | 0x43
| style="background: #E8E8E8" | I pressed
|-
| align="right" | 0x44
| O pressed
| style="background: #E8E8E8" align="right" | 0x45
| style="background: #E8E8E8" | 0 (zero) pressed
| align="right" | 0x46
| 9 pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0x49
| style="background: #E8E8E8" | . pressed
| align="right" | 0x4A
| / pressed
| style="background: #E8E8E8" align="right" | 0x4B
| style="background: #E8E8E8" | L pressed
|-
| align="right" | 0x4C
| ; pressed
| style="background: #E8E8E8" align="right" | 0x4D
| style="background: #E8E8E8" | P pressed
| align="right" | 0x4E
| - pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0x52
| ' pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0x54
| [ pressed
| style="background: #E8E8E8" align="right" | 0x55
| style="background: #E8E8E8" | = pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0x58
| CapsLock pressed
| style="background: #E8E8E8" align="right" | 0x59
| style="background: #E8E8E8" | right shift pressed
| align="right" | 0x5A
| enter pressed
| style="background: #E8E8E8" align="right" | 0x5B
| style="background: #E8E8E8" | ] pressed
|-
|
|
| style="background: #E8E8E8" align="right" | 0x5D
| style="background: #E8E8E8" | \ pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" | &nbsp;
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0x66
| backspace pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0x69
| style="background: #E8E8E8" | (keypad) 1 pressed
|
|
| style="background: #E8E8E8" align="right" | 0x6B
| style="background: #E8E8E8" | (keypad) 4 pressed
|-
| align="right" | 0x6C
| (keypad) 7 pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0x70
| (keypad) 0 pressed
| style="background: #E8E8E8" align="right" | 0x71
| style="background: #E8E8E8" | (keypad) . pressed
| align="right" | 0x72
| (keypad) 2 pressed
| style="background: #E8E8E8" align="right" | 0x73
| style="background: #E8E8E8" | (keypad) 5 pressed
|-
| align="right" | 0x74
| (keypad) 6 pressed
| style="background: #E8E8E8" align="right" | 0x75
| style="background: #E8E8E8" | (keypad) 8 pressed
| align="right" | 0x76
| escape pressed
| style="background: #E8E8E8" align="right" | 0x77
| style="background: #E8E8E8" | NumberLock pressed
|-
| align="right" | 0x78
| F11 pressed
| style="background: #E8E8E8" align="right" | 0x79
| style="background: #E8E8E8" | (keypad) + pressed
| align="right" | 0x7A
| (keypad) 3 pressed
| style="background: #E8E8E8" align="right" | 0x7B
| style="background: #E8E8E8" | (keypad) - pressed
|-
| align="right" | 0x7C
| (keypad) * pressed
| style="background: #E8E8E8" align="right" | 0x7D
| style="background: #E8E8E8" | (keypad) 9 pressed
| align="right" | 0x7E
| ScrollLock pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0x83
| style="background: #E8E8E8" | F7 pressed
|-
| align="right" | 0xE0, 0x10
| (multimedia) WWW search pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x11
| style="background: #E8E8E8" | right alt pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x14
| right control pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x15
| style="background: #E8E8E8" | (multimedia) previous track pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x18
| (multimedia) WWW favourites pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x1F
| style="background: #E8E8E8" | left GUI pressed
|-
| align="right" | 0xE0, 0x20
| (multimedia) WWW refresh pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x21
| style="background: #E8E8E8" | (multimedia) volume down pressed
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x23
| style="background: #E8E8E8" | (multimedia) mute pressed
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x27
| style="background: #E8E8E8" | right GUI pressed
|-
| align="right" | 0xE0, 0x28
| (multimedia) WWW stop pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x2B
| style="background: #E8E8E8" | (multimedia) calculator pressed
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x2F
| style="background: #E8E8E8" | apps pressed
|-
| align="right" | 0xE0, 0x30
| (multimedia) WWW forward pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0x32
| (multimedia) volume up pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x34
| (multimedia) play/pause pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x37
| style="background: #E8E8E8" | (ACPI) power pressed
|-
| align="right" | 0xE0, 0x38
| (multimedia) WWW back pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0x3A
| (multimedia) WWW home pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x3B
| style="background: #E8E8E8" | (multimedia) stop pressed
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x3F
| style="background: #E8E8E8" | (ACPI) sleep pressed
|-
| align="right" | 0xE0, 0x40
| (multimedia) my computer pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x48
| (multimedia) email pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0x4A
| (keypad) / pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x4D
| style="background: #E8E8E8" | (multimedia) next track pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x50
| (multimedia) media select pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0x5A
| (keypad) enter pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0x5E
| (ACPI) wake pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x69
| style="background: #E8E8E8" | end pressed
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x6B
| style="background: #E8E8E8" | cursor left pressed
|-
| align="right" | 0xE0, 0x6C
| home pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x70
| insert pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x71
| style="background: #E8E8E8" | delete pressed
| align="right" | 0xE0, 0x72
| cursor down pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0x74
| cursor right pressed
| style="background: #E8E8E8" align="right" | 0xE0, 0x75
| style="background: #E8E8E8" | cursor up pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0x7A
| page down pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0x7D
| style="background: #E8E8E8" | page up pressed
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x01
| style="background: #E8E8E8" | F9 released
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x03
| style="background: #E8E8E8" | F5 released
|-
| align="right" | 0xF0, 0x04
| F3 released
| style="background: #E8E8E8" align="right" | 0xF0, 0x05
| style="background: #E8E8E8" | F1 released
| align="right" | 0xF0, 0x06
| F2 released
| style="background: #E8E8E8" align="right" | 0xF0, 0x07
| style="background: #E8E8E8" | F12 released
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x09
| style="background: #E8E8E8" | F10 released
| align="right" | 0xF0, 0x0A
| F8 released
| style="background: #E8E8E8" align="right" | 0xF0, 0x0B
| style="background: #E8E8E8" | F6 released
|-
| align="right" | 0xF0, 0x0C
| F4 released
| style="background: #E8E8E8" align="right" | 0xF0, 0x0D
| style="background: #E8E8E8" | tab released
| align="right" | 0xF0, 0x0E
| ` (back tick) released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x11
| style="background: #E8E8E8" | left alt released
| align="right" | 0xF0, 0x12
| left shift released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xF0, 0x14
| left control released
| style="background: #E8E8E8" align="right" | 0xF0, 0x15
| style="background: #E8E8E8" | Q released
| align="right" | 0xF0, 0x16
| 1 released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xF0, 0x1A
| Z released
| style="background: #E8E8E8" align="right" | 0xF0, 0x1B
| style="background: #E8E8E8" | S released
|-
| align="right" | 0xF0, 0x1C
| A released
| style="background: #E8E8E8" align="right" | 0xF0, 0x1D
| style="background: #E8E8E8" | W released
| align="right" | 0xF0, 0x1E
| 2 released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x21
| style="background: #E8E8E8" | C released
| align="right" | 0xF0, 0x22
| X released
| style="background: #E8E8E8" align="right" | 0xF0, 0x23
| style="background: #E8E8E8" | D released
|-
| align="right" | 0xF0, 0x24
| E released
| style="background: #E8E8E8" align="right" | 0xF0, 0x25
| style="background: #E8E8E8" | 4 released
| align="right" | 0xF0, 0x26
| 3 released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x29
| style="background: #E8E8E8" | space released
| align="right" | 0xF0, 0x2A
| V released
| style="background: #E8E8E8" align="right" | 0xF0, 0x2B
| style="background: #E8E8E8" | F released
|-
| align="right" | 0xF0, 0x2C
| T released
| style="background: #E8E8E8" align="right" | 0xF0, 0x2D
| style="background: #E8E8E8" | R released
| align="right" | 0xF0, 0x2E
| 5 released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x31
| style="background: #E8E8E8" | N released
| align="right" | 0xF0, 0x32
| B released
| style="background: #E8E8E8" align="right" | 0xF0, 0x33
| style="background: #E8E8E8" | H released
|-
| align="right" | 0xF0, 0x34
| G released
| style="background: #E8E8E8" align="right" | 0xF0, 0x35
| style="background: #E8E8E8" | Y released
| align="right" | 0xF0, 0x36
| 6 released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xF0, 0x3A
| M released
| style="background: #E8E8E8" align="right" | 0xF0, 0x3B
| style="background: #E8E8E8" | J released
|-
| align="right" | 0xF0, 0x3C
| U released
| style="background: #E8E8E8" align="right" | 0xF0, 0x3D
| style="background: #E8E8E8" | 7 released
| align="right" | 0xF0, 0x3E
| 8 released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x41
| style="background: #E8E8E8" | , released
| align="right" | 0xF0, 0x42
| K released
| style="background: #E8E8E8" align="right" | 0xF0, 0x43
| style="background: #E8E8E8" | I released
|-
| align="right" | 0xF0, 0x44
| O released
| style="background: #E8E8E8" align="right" | 0xF0, 0x45
| style="background: #E8E8E8" | 0 (zero) released
| align="right" | 0xF0, 0x46
| 9 released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x49
| style="background: #E8E8E8" | . released
| align="right" | 0xF0, 0x4A
| / released
| style="background: #E8E8E8" align="right" | 0xF0, 0x4B
| style="background: #E8E8E8" | L released
|-
| align="right" | 0xF0, 0x4C
| ; released
| style="background: #E8E8E8" align="right" | 0xF0, 0x4D
| style="background: #E8E8E8" | P released
| align="right" | 0xF0, 0x4E
| - released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xF0, 0x52
| ' released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xF0, 0x54
| [ released
| style="background: #E8E8E8" align="right" | 0xF0, 0x55
| style="background: #E8E8E8" | = released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xF0, 0x58
| CapsLock released
| style="background: #E8E8E8" align="right" | 0xF0, 0x59
| style="background: #E8E8E8" | right shift released
| align="right" | 0xF0, 0x5A
| enter released
| style="background: #E8E8E8" align="right" | 0xF0, 0x5B
| style="background: #E8E8E8" | ] released
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x5D
| style="background: #E8E8E8" | \ released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" | &nbsp;
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xF0, 0x66
| backspace released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x69
| style="background: #E8E8E8" | (keypad) 1 released
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x6B
| style="background: #E8E8E8" | (keypad) 4 released
|-
| align="right" | 0xF0, 0x6C
| (keypad) 7 released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xF0, 0x70
| (keypad) 0 released
| style="background: #E8E8E8" align="right" | 0xF0, 0x71
| style="background: #E8E8E8" | (keypad) . released
| align="right" | 0xF0, 0x72
| (keypad) 2 released
| style="background: #E8E8E8" align="right" | 0xF0, 0x73
| style="background: #E8E8E8" | (keypad) 5 released
|-
| align="right" | 0xF0, 0x74
| (keypad) 6 released
| style="background: #E8E8E8" align="right" | 0xF0, 0x75
| style="background: #E8E8E8" | (keypad) 8 released
| align="right" | 0xF0, 0x76
| escape released
| style="background: #E8E8E8" align="right" | 0xF0, 0x77
| style="background: #E8E8E8" | NumberLock released
|-
| align="right" | 0xF0, 0x78
| F11 released
| style="background: #E8E8E8" align="right" | 0xF0, 0x79
| style="background: #E8E8E8" | (keypad) + released
| align="right" | 0xF0, 0x7A
| (keypad) 3 released
| style="background: #E8E8E8" align="right" | 0xF0, 0x7B
| style="background: #E8E8E8" | (keypad) - released
|-
| align="right" | 0xF0, 0x7C
| (keypad) * released
| style="background: #E8E8E8" align="right" | 0xF0, 0x7D
| style="background: #E8E8E8" | (keypad) 9 released
| align="right" | 0xF0, 0x7E
| ScrollLock released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xF0, 0x83
| style="background: #E8E8E8" | F7 released
|-
| align="right" | 0xE0, 0x12, 0xE0, 0x7C
| print screen pressed
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xF0, 0x10
| (multimedia) WWW search released
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x11
| style="background: #E8E8E8" | right alt released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xF0, 0x14
| right control released
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x15
| style="background: #E8E8E8" | (multimedia) previous track released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xF0, 0x18
| (multimedia) WWW favourites released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x1F
| style="background: #E8E8E8" | left GUI released
|-
| align="right" | 0xE0, 0xF0, 0x20
| (multimedia) WWW refresh released
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x21
| style="background: #E8E8E8" | (multimedia) volume down released
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x23
| style="background: #E8E8E8" | (multimedia) mute released
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x27
| style="background: #E8E8E8" | right GUI released
|-
| align="right" | 0xE0, 0xF0, 0x28
| (multimedia) WWW stop released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x2B
| style="background: #E8E8E8" | (multimedia) calculator released
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x2F
| style="background: #E8E8E8" | apps released
|-
| align="right" | 0xE0, 0xF0, 0x30
| (multimedia) WWW forward released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0xF0, 0x32
| (multimedia) volume up released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xF0, 0x34
| (multimedia) play/pause released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x37
| style="background: #E8E8E8" | (ACPI) power released
|-
| align="right" | 0xE0, 0xF0, 0x38
| (multimedia) WWW back released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0xF0, 0x3A
| (multimedia) WWW home released
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x3B
| style="background: #E8E8E8" | (multimedia) stop released
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x3F
| style="background: #E8E8E8" | (ACPI) sleep released
|-
| align="right" | 0xE0, 0xF0, 0x40
| (multimedia) my computer released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xF0, 0x48
| (multimedia) email released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0xF0, 0x4A
| (keypad) / released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x4D
| style="background: #E8E8E8" | (multimedia) next track released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xF0, 0x50
| (multimedia) media select released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0xF0, 0x5A
| (keypad) enter released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0xF0, 0x5E
| (ACPI) wake released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x69
| style="background: #E8E8E8" | end released
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x6B
| style="background: #E8E8E8" | cursor left released
|-
| align="right" | 0xE0, 0xF0, 0x6C
| home released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xF0, 0x70
| insert released
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x71
| style="background: #E8E8E8" | delete released
| align="right" | 0xE0, 0xF0, 0x72
| cursor down released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
| align="right" | 0xE0, 0xF0, 0x74
| cursor right released
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x75
| style="background: #E8E8E8" | cursor up released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0xF0, 0x7A
| page down released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" align="right" | 0xE0, 0xF0, 0x7D
| style="background: #E8E8E8" | page up released
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
| align="right" | 0xE0, 0xF0, 0x7C, 0xE0, 0xF0, 0x12
| print screen released
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|-
|
|
| style="background: #E8E8E8" |
| style="background: #E8E8E8" |
|
|
| style="background: #E8E8E8" align="right" | 0xE1, 0x14, 0x77, 0xE1, 0xF0, 0x14, 0xF0, 0x77
| style="background: #E8E8E8" | pause pressed
|}
 
Note: There is no scan code for "pause key released" (it behaves as if it is released as soon as it's pressed)
 
=== Scan Code Set 3 ===
 
下表显示了使用扫描代码集3 (仅适用于 “US QWERTY” 键盘) 时,哪些扫描代码对应于哪些键:
 
{| {{wikitable}}
|-
!Key
! 扫码码集3
|-
|A || 1C
|-
|B || 32
|-
|C || 21
|-
|D || 23
|-
|E || 24
|-
|F || 2B
|-
|G || 34
|-
|H || 33
|-
|I || 43
|-
|J || 3B
|-
|K || 42
|-
|L || 4B
|-
|M || 3A
|-
|N || 31
|-
|O || 44
|-
|P || 4D
|-
|Q || 15
|-
|R || 2D
|-
|S || 1B
|-
|T || 2C
|-
|U || 3C
|-
|V || 2A
|-
|W || 1D
|-
|X || 22
|-
|Y || 35
|-
|Z || 1A
|-
 
[https://web.archive.org/web/20170108131104/http://www.computer-engineering.org/ps2keyboard/scancodes3.html Scan code]
 
== 另见 ==
*[[PS/2]]
*[["8042" PS/2 Controller]]
*[[PL050 PS/2 Controller | PL050 PS/2 Controller (ARM)]]
*[[PS/2 Mouse]]
=== 论坛主题 ===
*[[Topic:9746|Keyboard input]]
*[[Topic:9761|Up or down press?]]
*[[Topic:9711|Change typerate]]
*[[Topic:9648|Converting the scancodes]]
*[[Topic:9448|Discussion about keyboard input in a GUI]]
*[[Topic:9590|Scroll-lock LED]]
*[[Topic:10153|Keyboard LEDs (asm source)]]
*[[Topic:10053|Keyboard LEDs (C source)]]
 
=== 外部链接 ===
*[http://www.win.tue.nl/~aeb/linux/kbd/scancodes.html Keyboard scancodes] - 关于你可能遇到的所有扫描代码的完整引用。
*[https://web.archive.org/web/20030621203107/http://www.microsoft.com/whdc/hwdev/tech/input/Scancode.mspx USB HID to PS/2 Translation Table] - 微软的scancodes和USB等效表
*[https://web.archive.org/web/20190301075756/http://download.microsoft.com/download/1/6/1/161ba512-40e2-4cc9-843a-923143f3456c/scancode.doc Keyboard Scan Code Specification] - 微软的scancodes规范
*[https://www.youtube.com/playlist?list=PLUZozxlhse-NUto5JeJ0EDXEUFloWBdAj PS/2 keyboard interface playlist] - Ben Eater在面包板上构建PS/2键盘接口的视频播放列表。
 
==== 实现 ====
* [http://lxr.linux.no/#linux+v3.5.4/drivers/input/keyboard/atkbd.c Linux] (C,GPL)
* [https://github.com/Stichting-MINIX-Research-Foundation/minix/blob/master/minix/drivers/hid/pckbd/pckbd.c Minix]
 
[[Category:Human Interface Device]]
[[Category:Common Devices]]
[[de:Keyboard Controller]]

2022年3月8日 (二) 12:56的最新版本

重定向到: