419 lines
19 KiB
HTML
419 lines
19 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
|
|
<HTML>
|
|
<HEAD>
|
|
<META NAME="GENERATOR" CONTENT="SGML-Tools 1.0.9">
|
|
<TITLE>Keyboard scancodes: Keyboard scancodes</TITLE>
|
|
<LINK HREF="scancodes-2.html" REL=next>
|
|
|
|
<LINK HREF="scancodes.html#toc1" REL=contents>
|
|
</HEAD>
|
|
<BODY>
|
|
<A HREF="scancodes-2.html">Next</A>
|
|
Previous
|
|
<A HREF="scancodes.html#toc1">Contents</A>
|
|
<HR>
|
|
<H2><A NAME="s1">1. Keyboard scancodes</A></H2>
|
|
|
|
<P>The data from a keyboard comes mainly in the form of scancodes,
|
|
produced by key presses or used in the protocol with the computer.
|
|
(
|
|
<A HREF="scancodes-9.html#scancodesets">Different codes</A> are used by the keyboard
|
|
firmware internally, and there also exist several
|
|
<A HREF="scancodes-9.html#scancodesets">sets of scancodes</A>.
|
|
Here in this section we only talk about the default codes - those from
|
|
translated scancode set 2. Less common modes are discussed
|
|
<A HREF="scancodes-9.html#scancodesets">below</A>.)
|
|
Each key press and key release produces between 0 and 6 scancodes.
|
|
<P>
|
|
<H2><A NAME="ss1.1">1.1 Key release</A>
|
|
</H2>
|
|
|
|
<P>Below I'll only mention the scancode for key press (`make').
|
|
The scancode for key release (`break') is obtained from it
|
|
by setting the high order bit (adding 0x80 = 128).
|
|
Thus, Esc press produces scancode <B>01</B>, Esc release
|
|
scancode <B>81</B> (hex).
|
|
For sequences things are similar: Keypad-/ gives <B>e0</B> <B>35</B>
|
|
when pressed, <B>e0</B> <B>b5</B> when released. Most keyboards will
|
|
repeat the make code (key down code) when the key repeats. Some will also
|
|
fake Shift down and Shift up events during the repeat.
|
|
<P>The keys PrtSc/SysRq and Pause/Break are special.
|
|
The former produces scancode <B>e0</B> <B>2a</B> <B>e0</B> <B>37</B>
|
|
when no modifier key is pressed simultaneously, <B>e0</B> <B>37</B>
|
|
together with Shift or Ctrl, but <B>54</B> together with (left or right) Alt.
|
|
(And one gets the expected sequences upon release. But see
|
|
<A HREF="scancodes-5.html#mtek">below</A>.)
|
|
The latter produces scancode sequence
|
|
<B>e1</B> <B>1d</B> <B>45</B> <B>e1</B> <B>9d</B> <B>c5</B>
|
|
when pressed (without modifier) and nothing at all upon release.
|
|
However, together with (left or right) Ctrl, one gets
|
|
<B>e0</B> <B>46</B> <B>e0</B> <B>c6</B>,
|
|
and again nothing at release. It does not repeat.
|
|
<P>See
|
|
<A HREF="#dellnoup">below</A> for a report on keys
|
|
with a different behaviour.
|
|
<P>There are many reports of laptops with badly debounced key-up events.
|
|
Thus, unexpected key-up events should probably be regarded as not
|
|
unusual, and be ignored. Another source of key-up events without
|
|
preceding key-down can be the
|
|
<A HREF="#fakeshifts">fake shift</A>.
|
|
<P>
|
|
<H2><A NAME="ss1.2">1.2 Protocol scancodes</A>
|
|
</H2>
|
|
|
|
<P>Most scancodes indicate a key press or release.
|
|
Some are used in the communication protocol.
|
|
<P>
|
|
<P>
|
|
<CENTER><TABLE BORDER><TR><TD>
|
|
<B>00</B> </TD><TD> Keyboard error - see <B>ff</B> </TD></TR><TR><TD>
|
|
<B>aa</B> </TD><TD> BAT (Basic Assurance Test) OK </TD></TR><TR><TD>
|
|
<B>ee</B> </TD><TD> Result of echo command </TD></TR><TR><TD>
|
|
<B>f1</B> </TD><TD> Some keyboards, as reply to command <B>a4</B>:Password not installed </TD></TR><TR><TD>
|
|
<B>fa</B> </TD><TD> Acknowledge from kbd </TD></TR><TR><TD>
|
|
<B>fc</B> </TD><TD> BAT error or Mouse transmit error </TD></TR><TR><TD>
|
|
<B>fd</B> </TD><TD> Internal failure </TD></TR><TR><TD>
|
|
<B>fe</B> </TD><TD> Keyboard fails to ack, please resend </TD></TR><TR><TD>
|
|
<B>ff</B> </TD><TD> Keyboard error </TD></TR><TR><TD>
|
|
|
|
</TD></TR></TABLE></CENTER>
|
|
<P>Three common causes for keyboard error are:
|
|
(i) several keys pressed simultaneously,
|
|
(ii) keyboard buffer overflow,
|
|
(iii) parity error on the serial line used by keyboard
|
|
and keyboard controller for communication.
|
|
The error reported is <B>ff</B> in
|
|
<A HREF="scancodes-9.html#scancodesets">scancode mode</A> 1,
|
|
and <B>00</B> in scancode modes 2 and 3.
|
|
If translation is on, both <B>00</B> and <B>ff</B>
|
|
are translated as <B>ff</B>.
|
|
<P>Usually these codes have the protocol meaning. However,
|
|
they also occur as actual scancodes, especially when
|
|
prefixed by <B>e0</B>.
|
|
<P>
|
|
<H2><A NAME="ss1.3">1.3 Escape scancodes</A>
|
|
</H2>
|
|
|
|
<P>The codes <B>e0</B> and <B>e1</B> introduce scancode sequences,
|
|
and are not usually used as isolated scancodes themselves
|
|
(but see
|
|
<A HREF="scancodes-6.html#e0_as_key">below</A>).
|
|
<P>(The prefix <B>e0</B> was originally used for the grey duplicates
|
|
of keys on the original PC/XT keyboard. These days <B>e0</B> is
|
|
just used to expand code space. The prefix <B>e1</B> used for
|
|
Pause/Break indicated that this key sends the make/break sequence
|
|
at make time, and does nothing upon release.)
|
|
<P>This, and the above, means that the values
|
|
<B>00</B>, <B>60</B>, <B>61</B>, <B>6e</B>, <B>71</B>,
|
|
<B>7a</B>, <B>7c</B>, <B>7e</B>, <B>7f</B>
|
|
are unavailable to signify key presses (on a default keyboard).
|
|
Nevertheless they also occur as scancodes, see for example the
|
|
<A HREF="scancodes-2.html#telerate">Telerate</A> and
|
|
<A HREF="scancodes-5.html#safeway23">Safeway SW23</A> keyboards below.
|
|
<P>Also other prefixes occur, see
|
|
<A HREF="scancodes-5.html#prefix_80">below</A>.
|
|
<P>
|
|
<A HREF="scancodes-9.html#logiteche2">Logitech</A> uses an <B>e2</B> prefix
|
|
for the codes sent by a pointing device integrated on the keyboard.
|
|
<P>
|
|
<P>
|
|
<H2><A NAME="ss1.4">1.4 Ordinary scancodes</A>
|
|
</H2>
|
|
|
|
<P>The scancodes in translated scancode set 2 are given in hex.
|
|
Between parentheses the keycap on a US keyboard.
|
|
The scancodes are given in order, grouped according
|
|
to groups of keys that are usually found next to each other.
|
|
<P><B>00</B> is normally an error code
|
|
<P><B>01</B> (Esc)
|
|
<P><B>02</B> (1!), <B>03</B> (2@), <B>04</B> (3#), <B>05</B> (4$),
|
|
<B>06</B> (5%E), <B>07</B> (6^), <B>08</B> (7&),
|
|
<B>09</B> (8*), <B>0a</B> (9(), <B>0b</B> (0)), <B>0c</B> (-_),
|
|
<B>0d</B> (=+), <B>0e</B> (Backspace)
|
|
<P><B>0f</B> (Tab), <B>10</B> (Q), <B>11</B> (W), <B>12</B> (E),
|
|
<B>13</B> (R), <B>14</B> (T), <B>15</B> (Y),
|
|
<B>16</B> (U), <B>17</B> (I), <B>18</B> (O),
|
|
<B>19</B> (P), <B>1a</B> ([{), <B>1b</B> (]})
|
|
<P><B>1c</B> (Enter)
|
|
<P><B>1d</B> (LCtrl)
|
|
<P><B>1e</B> (A), <B>1f</B> (S), <B>20</B> (D), <B>21</B> (F),
|
|
<B>22</B> (G), <B>23</B> (H), <B>24</B> (J), <B>25</B> (K),
|
|
<B>26</B> (L), <B>27</B> (;:), <B>28</B> ('")
|
|
<P><B>29</B> (`~)
|
|
<P><B>2a</B> (LShift)
|
|
<P><B>2b</B> (\|), on a 102-key keyboard
|
|
<P><B>2c</B> (Z), <B>2d</B> (X), <B>2e</B> (C), <B>2f</B> (V),
|
|
<B>30</B> (B), <B>31</B> (N), <B>32</B> (M), <B>33</B> (,<),
|
|
<B>34</B> (.>), <B>35</B> (/?), <B>36</B> (RShift)
|
|
<P><B>37</B> (Keypad-*) or (*/PrtScn) on a 83/84-key keyboard
|
|
<P><B>38</B> (LAlt), <B>39</B> (Space bar),
|
|
<P><B>3a</B> (CapsLock)
|
|
<P><B>3b</B> (F1), <B>3c</B> (F2), <B>3d</B> (F3), <B>3e</B> (F4),
|
|
<B>3f</B> (F5), <B>40</B> (F6), <B>41</B> (F7),
|
|
<B>42</B> (F8), <B>43</B> (F9), <B>44</B> (F10)
|
|
<P><B>45</B> (NumLock)
|
|
<P><B>46</B> (ScrollLock)
|
|
<P><B>47</B> (Keypad-7/Home), <B>48</B> (Keypad-8/Up),
|
|
<B>49</B> (Keypad-9/PgUp)
|
|
<P><B>4a</B> (Keypad--)
|
|
<P><B>4b</B> (Keypad-4/Left), <B>4c</B> (Keypad-5),
|
|
<B>4d</B> (Keypad-6/Right), <B>4e</B> (Keypad-+)
|
|
<P><B>4f</B> (Keypad-1/End), <B>50</B> (Keypad-2/Down),
|
|
<B>51</B> (Keypad-3/PgDn)
|
|
<P><B>52</B> (Keypad-0/Ins), <B>53</B> (Keypad-./Del)
|
|
<P><B>54</B> (Alt-SysRq) on a 84+ key keyboard
|
|
<P><B>55</B> is less common; occurs e.g. as F11 on a Cherry G80-0777 keyboard,
|
|
as F12 on a Telerate keyboard,
|
|
as PF1 on a Focus 9000 keyboard, and as FN on an IBM ThinkPad.
|
|
<P><B>56</B> mostly on non-US keyboards. It is often an unlabelled key
|
|
<A HREF="laser.jpg">to the left</A>
|
|
or
|
|
<A HREF="toshiba.jpg">to the right</A>
|
|
of the left Alt key.<BR>
|
|
<FIGURE>
|
|
<EPS FILE="absent">
|
|
<IMG SRC="laser-s.jpg">
|
|
</FIGURE>
|
|
|
|
<FIGURE>
|
|
<EPS FILE="absent">
|
|
<IMG SRC="toshiba-s.jpg">
|
|
</FIGURE>
|
|
<P><B>57</B> (F11), <B>58</B> (F12) both on a 101+ key keyboard
|
|
<P><B>59</B>-<B>5a</B>-...-<B>7f</B> are less common.
|
|
Assignment is essentially random.
|
|
Scancodes <B>55</B>-<B>59</B> occur as F11-F15 on the
|
|
<A HREF="scancodes-2.html#cherry80">Cherry G80-0777</A> keyboard.
|
|
Scancodes <B>59</B>-<B>5c</B> occur on the
|
|
<A HREF="scancodes-5.html#RC930">RC930</A> keyboard.
|
|
X calls <B>5d</B> `KEY_Begin'.
|
|
Scancodes <B>61</B>-<B>64</B> occur on a
|
|
<A HREF="scancodes-2.html#telerate">Telerate</A> keyboard.
|
|
Scancodes <B>55</B>, <B>6d</B>, <B>6f</B>, <B>73</B>, <B>74</B>,
|
|
<B>77</B>, <B>78</B>, <B>79</B>, <B>7a</B>, <B>7b</B>,
|
|
<B>7c</B>, <B>7e</B> occur on the
|
|
<A HREF="scancodes-5.html#focus">Focus 9000</A> keyboard.
|
|
Scancodes <B>65</B>, <B>67</B>, <B>69</B>, <B>6b</B>
|
|
occur on a
|
|
<A HREF="scancodes-5.html#armada">Compaq Armada</A> keyboard.
|
|
Scancodes <B>66</B>-<B>68</B>, <B>73</B> occur on the
|
|
<A HREF="scancodes-5.html#cherry81">Cherry G81-3000</A> keyboard.
|
|
Scancodes <B>70</B>, <B>73</B>, <B>79</B>, <B>7b</B>, <B>7d</B>
|
|
occur on a
|
|
<A HREF="scancodes-7.html#japanese">Japanese 86/106 keyboard</A>.
|
|
<P>Scancodes <B>f1</B> and <B>f2</B> occur on
|
|
<A HREF="scancodes-8.html#korean">Korean keyboards</A>.
|
|
<P>
|
|
<H2><A NAME="ss1.5">1.5 Escaped scancodes</A>
|
|
</H2>
|
|
|
|
<P>Apart from the Pause/Break key, that has an escaped sequence starting
|
|
with <B>e1</B>, the escape used is <B>e0</B>. Often, the codes
|
|
are chosen in such a way that something meaningful happens when
|
|
the receiver just discards the <B>e0</B>.
|
|
<P>
|
|
<CENTER><TABLE BORDER><TR><TD>
|
|
<B>e0</B> <B>1c</B> (Keypad Enter) </TD><TD></TD><TD> <B>1c</B> (Enter) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>1d</B> (RCtrl) </TD><TD></TD><TD> <B>1d</B> (LCtrl) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>2a</B> (fake LShift) </TD><TD></TD><TD> <B>2a</B> (LShift) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>35</B> (Keypad-/) </TD><TD></TD><TD> <B>35</B> (/?) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>36</B> (fake RShift) </TD><TD></TD><TD> <B>36</B> (RShift) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>37</B> (Ctrl-PrtScn) </TD><TD></TD><TD> <B>37</B> (*/PrtScn) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>38</B> (RAlt) </TD><TD></TD><TD> <B>38</B> (LAlt) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>46</B> (Ctrl-Break) </TD><TD></TD><TD> <B>46</B> (ScrollLock) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>47</B> (Grey Home) </TD><TD></TD><TD> <B>47</B> (Keypad-7/Home) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>48</B> (Grey Up) </TD><TD></TD><TD> <B>48</B> (Keypad-8/UpArrow) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>49</B> (Grey PgUp) </TD><TD></TD><TD> <B>49</B> (Keypad-9/PgUp) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>4b</B> (Grey Left) </TD><TD></TD><TD> <B>4b</B> (Keypad-4/Left) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>4d</B> (Grey Right) </TD><TD></TD><TD> <B>4d</B> (Keypad-6/Right) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>4f</B> (Grey End) </TD><TD></TD><TD> <B>4f</B> (Keypad-1/End) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>50</B> (Grey Down) </TD><TD></TD><TD> <B>50</B> (Keypad-2/DownArrow) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>51</B> (Grey PgDn) </TD><TD></TD><TD> <B>51</B> (Keypad-3/PgDn) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>52</B> (Grey Insert) </TD><TD></TD><TD> <B>52</B> (Keypad-0/Ins) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>53</B> (Grey Delete) </TD><TD></TD><TD> <B>53</B> (Keypad-./Del) </TD></TR><TR><TD>
|
|
|
|
</TD></TR></TABLE></CENTER>
|
|
<P>These escaped scancodes occur only on 101+ key keyboards.
|
|
The
|
|
<A HREF="scancodes-5.html#microsoft">Microsoft keyboard</A> adds
|
|
<P>
|
|
<CENTER><TABLE BORDER><TR><TD>
|
|
<B>e0</B> <B>5b</B> (LeftWindow) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>5c</B> (RightWindow) </TD></TR><TR><TD>
|
|
<B>e0</B> <B>5d</B> (Menu) </TD></TR><TR><TD>
|
|
|
|
</TD></TR></TABLE></CENTER>
|
|
<P>Other escaped scancodes occur - see below under the individual keyboards.
|
|
<P>
|
|
<H2><A NAME="fakeshifts"></A> <A NAME="ss1.6">1.6 Fake shifts</A>
|
|
</H2>
|
|
|
|
<P>The ten grey keys Insert, Home, PgUp, Delete, End, PgDn,
|
|
Up, Left, Down, Right are supposed to function regardless
|
|
of the state of Shift and NumLock keys. But for an old AT keyboard
|
|
the keypad keys would produce digits when Numlock was on or Shift
|
|
was down. Therefore, in order to fool old programs,
|
|
fake scancodes are sent: when LShift is down, and Insert is
|
|
pressed, <B>e0</B> <B>aa</B> <B>e0</B> <B>52</B> is sent;
|
|
upon release of Insert <B>e0</B> <B>d2</B> <B>e0</B> <B>2a</B>
|
|
is sent. In other words, a fake LShift-up and
|
|
fake LShift-down are inserted.
|
|
<P>If the Shift key is released earlier than the repeated key,
|
|
then a real Shift-up code occurs (without preceding fake Shift-down)
|
|
so that a program ignoring <B>e0</B> would see one more Shift-up
|
|
than Shift-down.
|
|
<P>When NumLock is on, no fake Shifts are sent when Shift was down,
|
|
but fake Shifts are sent when Shift was not down. Thus,
|
|
with Numlock, if Insert is pressed,
|
|
<B>e0</B> <B>2a</B> <B>e0</B> <B>52</B> is sent
|
|
and upon release <B>e0</B> <B>d2</B> <B>e0</B> <B>aa</B> is sent.
|
|
The keyboard maintains a private NumLock mode, toggled when
|
|
NumLock is pressed, and set when the NumLock LED is set.
|
|
<P>In the same way, when Shift is down, the Grey-/ key produces
|
|
fake Shift-up and fake Shift-down sequences. However, it does
|
|
not react to the state of NumLock. The purpose of course is to
|
|
fool programs that identify Grey-/ with ordinary /, so that they
|
|
don't treat Shift-Grey-/ like Shift-/, i.e., ?.
|
|
<P>On a Toshiba notebook, the three Windows keys are treated like
|
|
the group of ten keys mentioned, and get fake shifts when
|
|
(left or right) Shift is down. They do not react to NumLock.
|
|
<P>
|
|
<H2><A NAME="ss1.7">1.7 Added non-fake shifts</A>
|
|
</H2>
|
|
|
|
<P>On my 121-key
|
|
<A HREF="scancodes-5.html#nokia">Nokia Data</A> keyboard there are
|
|
function keys F1, ..., F24, where F1, ..., F12 send the expected codes
|
|
<B>3b</B>, ..., <B>58</B>, and F13, ..., F24 send the same codes
|
|
together with the LShift code <B>2a</B>.
|
|
Thus, F13 gives <B>2a</B> <B>3b</B> on press,
|
|
and <B>bb</B> <B>aa</B> on release.
|
|
Similarly, there are keys with added LCtrl code <B>1d</B>.
|
|
But there are also keys with added fake shifts <B>e0 2a</B>.
|
|
<P>
|
|
<A HREF="http://www.delorie.com/djgpp/doc/rbinter/it/06/0.html">Delorie</A>
|
|
reports that <I>the "Preh Commander AT" keyboard with additional F11-F22 keys
|
|
treats F11-F20 as Shift-F1..Shift-F10 and F21/F22 as Ctrl-F1/Ctrl-F2; the
|
|
Eagle PC-2 keyboard with F11-F24 keys treats those additional keys
|
|
in the same way</I>.
|
|
<P>
|
|
<H2><A NAME="ss1.8">1.8 Turbo Mode</A>
|
|
</H2>
|
|
|
|
<P>On some motherboards the LCtrl-LAlt-GreyPlus and LCtrl-LAlt-GreyMinus
|
|
switch Turbo mode on/off, respectively. For these, the motherboard
|
|
may generate the same scancode sequence when the Turbo button is
|
|
pushed: Turbo Switch (High->Low):
|
|
<B>1d</B> <B>38</B> <B>4a</B> <B>ce</B> <B>b8</B> <B>9d</B>
|
|
and Turbo Switch (Low->High):
|
|
<B>1d</B> <B>38</B> <B>4e</B> <B>ce</B> <B>b8</B> <B>9d</B>.
|
|
<P>Other peculiar combinations in this style include
|
|
LCtrl-LAlt-LShift-GreyMinus and LCtrl-LAlt-LShift-GreyPlus to turn
|
|
system cache off/on.
|
|
<P>If Green PC system power saving mode is enabled in AMIBIOS Setup,
|
|
the AMI MegaKey keyboard controller recognizes the combinations
|
|
Ctrl-Alt-\ (put the system into immediate power down mode),
|
|
Ctrl-Alt-[ (disable the Green PC power savings mode temporarily),
|
|
Ctrl-Alt-] (enables the Green PC power down mode).
|
|
<P>Thio Yu Jin <<CODE>jin@singmail.com</CODE>> complains that on his Toshiba 4010CDS
|
|
the Ctrl-Alt-Shift-T key combination brings up the Toshiba user manual.
|
|
(04 Mar 1999 - not April 1.)
|
|
<P>
|
|
<P>
|
|
<H2><A NAME="power"></A> <A NAME="ss1.9">1.9 Power Saving</A>
|
|
</H2>
|
|
|
|
<P>
|
|
<A HREF="http://www.microsoft.com/hwdev/tech/input/Scancode.asp">Microsoft</A> recommends: "i8042-based keyboards should deploy the
|
|
following scan codes for power management buttons, i.e., POWER and SLEEP
|
|
buttons:
|
|
<P>
|
|
<CENTER><TABLE BORDER><TR><TD>
|
|
</TD><TD> Set-1 make/break </TD><TD> Set-2 make/break </TD></TR><TR><TD>
|
|
</TD></TR><TR><TD>
|
|
Power </TD><TD> <B>e0</B> <B>5e</B> / <B>e0</B> <B>de</B> </TD><TD><B>e0</B> <B>37</B> / <B>e0</B> <B>f0</B> <B>37</B> </TD></TR><TR><TD>
|
|
Sleep </TD><TD> <B>e0</B> <B>5f</B> / <B>e0</B> <B>df</B> </TD><TD><B>e0</B> <B>3f</B> / <B>e0</B> <B>f0</B> <B>3f</B> </TD></TR><TR><TD>
|
|
Wake </TD><TD> <B>e0</B> <B>63</B> / <B>e0</B> <B>e3</B> </TD><TD><B>e0</B> <B>5e</B> / <B>e0</B> <B>f0</B> <B>5e</B> </TD></TR><TR><TD>
|
|
|
|
</TD></TR></TABLE></CENTER>
|
|
<P>The Power, Sleep, and Wake event scan codes are the i8042 equivalents
|
|
to the System Power Down, System Sleep, and System Wake Up HID usages".
|
|
<P>Many keyboards have Power/Sleep/Wake keys that have to be
|
|
activated by a fourth key (unlabeled, or labeled FN): pressing
|
|
one of these four keys does not produce any scancodes, but
|
|
when the FN key is pressed simultaneously, the Power/Sleep/Wake
|
|
keys give the codes listed above.
|
|
<P>
|
|
<P>
|
|
<H2><A NAME="ss1.10">1.10 Initializing special keyboards</A>
|
|
</H2>
|
|
|
|
<P>Many keyboards have more keys and buttons than the standard ones.
|
|
Sometimes these additional keys produce scancode combinations
|
|
that were unused before. But on other keyboard such additional
|
|
keys do not produce any code at all, until some initializing
|
|
action is taken.
|
|
<P>Sometimes that action consists of writing some bytes to keyboard
|
|
registers. See, for example, the
|
|
<A HREF="scancodes-5.html#rapidinit">IBM Rapid Access keyboard</A>, and the
|
|
<A HREF="scancodes-5.html#omnibookinit">Omnibook keyboard</A>.
|
|
<P>
|
|
<H2><A NAME="LEDmanip"></A> <A NAME="ss1.11">1.11 Manipulating extra LEDs</A>
|
|
</H2>
|
|
|
|
<P>Some keyboards have additional LEDs, and in a few cases we know
|
|
how to manipulate those.
|
|
<P>The
|
|
<A HREF="scancodes-5.html#chicony">Chicony keyboard</A> needs command sequences
|
|
<B>eb</B> <B>00</B> <I>xy</I>, with
|
|
<I>xy</I> = <B>01</B> for the Moon LED and
|
|
<I>xy</I> = <B>02</B> for the zzZ LED.
|
|
<P>The
|
|
<A HREF="scancodes-5.html#EZButton">IBM EZ Button keyboard</A> needs
|
|
command sequences <B>eb</B> <B>00</B> <I>xy</I>, with
|
|
<I>xy</I> = <B>01</B> for the Msg LED,
|
|
<I>xy</I> = <B>02</B> for the CD LED,
|
|
<I>xy</I> = <B>04</B> for the Power LED,
|
|
<I>xy</I> = <B>10</B> for the Talk LED, and
|
|
<I>xy</I> = <B>20</B> for the Message Waiting LED.
|
|
<P>The
|
|
<A HREF="scancodes-5.html#ibmrapidaccess">IBM Rapid Access keyboard</A> needs
|
|
command sequences <B>eb</B> <B>00</B> <I>xy</I>, with
|
|
<I>xy</I> = <B>04</B> for the Suspend LED and
|
|
<I>xy</I> = <B>20</B> for the Mute LED.
|
|
<P>The
|
|
<A HREF="scancodes-5.html#ibmrapidaccessii">IBM Rapid Access keyboard II</A> needs
|
|
the command sequences <B>eb</B> <B>71</B> and <B>eb</B> <B>70</B>
|
|
to switch the Standby LED on and off.
|
|
<P>The
|
|
<A HREF="scancodes-5.html#logitechinternet">Logitech Internet Keyboard</A>
|
|
has an additional amber LED. It is turned on by sending <B>eb</B>,
|
|
and then blinks about once a second. It is turned off again by <B>ec</B>.
|
|
<P>
|
|
<H2><A NAME="ss1.12">1.12 The laptop FN key</A>
|
|
</H2>
|
|
|
|
<P>Laptops have no room for all nonsensical keys one usually find
|
|
on a regular keyboard. So, the number pad and other keys are
|
|
folded into the main part of the keyboard. A key without label,
|
|
or labelled FN is often used to modify the meaning of other keys.
|
|
This FN does not produce scancodes itself, it only modifies the
|
|
scancodes produced by other keys.
|
|
<P>
|
|
<A NAME="dellnoup"></A>
|
|
Neil Brown reports about his Dell Latitude D800 laptop that it has
|
|
five key combinations that do not produce proper break codes.
|
|
The five combinations FN+F2, FN+F3, FN+F10, FN+Down, FN+Up
|
|
(labelled Wireless, Brighter, Darker, Battery, CDEject)
|
|
produce make codes <B>e0</B> <B>08</B>, <B>e0</B> <B>07</B>,
|
|
<B>e0</B> <B>09</B>, <B>e0</B> <B>05</B>, <B>e0</B> <B>06</B>,
|
|
respectively. The first three do not produce any break code.
|
|
The last two have a break code that is identical to the make code.
|
|
<P>
|
|
<HR>
|
|
<A HREF="scancodes-2.html">Next</A>
|
|
Previous
|
|
<A HREF="scancodes.html#toc1">Contents</A>
|
|
</BODY>
|
|
</HTML>
|