Keyboard Ghosting, N-key Rollover: How Many Keys Your Keyboard Can Take?

, , …,

How many simultaneous key presses can your keyboard handle?

Test How Many Keys Can Your Keyboard Register

Here's a test you can do.

Hold down both left ⇧ Shift key and right ⇧ Shift key, then press x. See if the letter shows up on your screen.

Yes? Now, try other keys, while keep both the ⇧ Shift keys depressed. Go through the whole alphabet. Best is to ask your friend to help you hold both the ⇧ Shift down.

On my Microsoft Comfort Curve Keyboard 2000 and Natural Ergonomic Keyboard 4000, when both ⇧ Shift are held down, the key x and / and 3 does not work!

apple bondi blue imac keyboard
“Apple Bondi Blue iMac keyboard (M2452)” (year 1999)

On my Apple iMac keyboard M2452 (year ≈2000), all the top row {Q W E R T Y U I O P [} does not work, except ] and \.

Apple pro keyboard
“Apple pro keyboard (German) (A1048)” img src

On my Apple keyboard A1048 (year 2005), same result.

N-key rollover, Key Ghosting, Keyboard Switch Circuit Design

Apparently, this is a known problem, and is a problem for vast majority of keyboards. This problem is called n-key rollover and key ghosting.

The issue is rather complex. It has to do with cost-saving design of the circuit, and also the keyboard interface protocol (⁖ USB vs PS/2). Following is a rough description of the situation.

Ideally, you'd think that each key is a switch. When a key is pressed, a signal is send for that key. This is logically simple, but it is a expensive way to design the circuit. Instead, the electronics of the keys are laid out on a rectangular grid. When a key is pressed, it shorts the row and column the key is on. This row+column determines which key is pressed. This way, you don't need a switch per key. Suppose you have 30 keys on a 3×10 matrix. With one switch per key (full n-key rollover), you need 30 switches. But with a grid approach, you need just 3+10=13.

keyboard key ghosting
Grid approach for keyboard circuit. (image from Microsoft)

The problem with the grid approach is that when several keys on the same column or row are being pressed, the design has problem knowing exactly which new key is being pressed. So it may not register a key you pressed, or may send a adjacent key that you didn't press. (this is why it's called ghosting)

This is a simple design flaw of circuit, and can be easily fixed, However, fixing this problem so that all keys can be detected correctly when simultaneously pressed, means more electronic components, more cost, and people never really need to press more than say 5 keys at the same time anyway, so keyboard makers don't bother with complete solutions (called full n-key rollover). They just make few extra grids for different cluster of keys and or re-arrange the correspondence between the keys and positions on the grid, so that common key combination do not lie in the same column or row.

The modifier keys, ⁖ {Alt, Ctrl, ⇧ Shift}, often need to be used with other keys together. So, keyboard makers have made sure that multiple keys with these have no problem. But uncommon combination, such as pressing both Left and Right ⇧ Shift plus other keys, is practically never used. So they become the victims.

Connector Matters: USB vs PS/2

Also, due to interface tech, typically USB cannot detect more than 6 simultaneously pressed keys, while PS/2 can.

I've read that theoretically USB can detect more than 6 simultaneous keys, but very few keyboard makers do that. (Corsair K60, K90 Gaming Keyboards provides 20 key roll-over over USB.)

Software and Operating System

But also, it is reported that even if keyboard and the connector sent all keys correctly, you operating system, keyboard driver, or application, just doesn't know what to with it, and may drop the signal as if you never pressed the keys.

Which Keyboard Has Full N-Key Rollover?

Any non-gaming keyboard you buy from Microsoft and Logitech Keyboards do not have n-key rollover. For example, all these: Microsoft Keyboards GalleryLogitech Keyboards GalleryApple Computer Keyboards.

Here's a online app from Microsoft that you can use to test how many keys your keyboard can detect, and what key combos your keyboard is weak at: http://www.microsoft.com/appliedsciences/content/projects/KeyboardGhostingDemo.aspx. (i've tried it and i think it's a fine app, but i wouldn't trust this as a good test on keyboard key rollover issue, because web tech cannot reliably deal with keyboard input.)

Gaming Keyboards and anti-ghosting tech

Some gaming keyboards, such as those from Microsoft, have so-called “anti-ghosting” tech. Basically, it's a scheme to let you press many keys simultaneously, but am not sure how good is their claim.

Unlike partial anti-ghosting solutions which have many combinations of 3 keys which do not work, Microsoft’s SideWinder X4 features multitouch technology that allows it to detect, and report ANY combination of QWERTY keys, up to 17 keys. Additionally, it can report 7 modifier keys, 1 hot key and 1 macro key, bringing the maximum number of reported keys to 26. See the SideWinder X4 Anti-Ghosting FAQ for more information.

Some gaming keyboard do provide full n-key rollover (i don't think any from Microsoft or Logitech actually do full n-key rollover.).

Expensive Mechanical Key-Switch Keyboards

Often, mechanical key-switch Keyboards provide full n-key rollover. They are usually from $80 to $300. However, because today most are using USB, they are effectively 6-key rollover. See: List of Keyboards with Mechanical Switches.

Who the Hell Needs to Press 6 Keys Simultaneously?

You might wonder who actually need to press so many keys simultaneously.

Wikipedia cited Braille2000, see: Source www.braille2000.com. Quote:

To use any computer braille-entry program, including Braille2000, you will need a keyboard that responds to six-key input. Be alerted that many famous-brand computer systems are supplied with keyboards that are NOT suitable. Be especially careful when shopping for a laptop computer not being able to use its built-in keyboard will be a real hassle.

Also, in gaming, the need to press more than 5 keys simultaneously is common. Usually, the arrows keys or WASD keys are used to control your character movement, while ⇧ Shift with left/right arrow makes your avatar move left/right instead of turning left/right. Sometimes 2 arrows such as up/right arrow makes your avatar walk diagonally. Add keys for jumping or crouching, usually needed to be combined with avatar movement keys. Add a key for run mode. Then, there's also things like firing a gun, shield, quickly you have 5 or 6 keys pressed simultaneously.

Basic modern keyboards already have shifted their electronic grid so that multi-key combo with the modifier is no problem. But when the game or game playing gets advanced, like doing some strife shooting while prim jump etc as in Second Life , you need a keyboard that does well. For this reason, as cited by Microsoft and elsewhere, gaming keyboards often take the extra mile to make this correct.

As another example, i recall about 10 year ago, i can play Street Fighter on PC, in a 2 player versus mode. For single player, you need 4 keys for the movement and another 4 or 6 for various levels of kick and punch. For 2 person playing on the same keyboard you really need keyboard that can detect some 20 simultaneous keys correctly. Remember those super combo inputs for executing special attacks. LOL

N-key Rollover and Emacs

Discovered a dead key. In emacs, i have the ▤ Menu key set as Hyper, and i have 【Hyper+⇧ Shift+x】 as a shortcut to some command. However, Microsoft Natural Ergonomic 4000 simply does not register that combination when right ⇧ Shift is used, but left ⇧ Shift works. 〔☛ Emacs: How to define Super & Hyper Keys

References

blog comments powered by Disqus