Author Topic: keyboard scanning matrices?  (Read 2996 times)

0 Members and 1 Guest are viewing this topic.

woody

  •  Guest
keyboard scanning matrices?
« on: Wed, 02 March 2011, 11:02:19 »
To those that have mucked into their keyboard intestines:

What configurations of keyboard scanning matrices in terms of rows and columns have you seen? Examples with the respective keyboard names would be additional plus.

That's just my own curiosity, but could make a nice Wiki, too.

EDIT: Example: 11x9, "UltraBestest KBD"
« Last Edit: Wed, 02 March 2011, 11:04:29 by woody »

woody

  •  Guest
keyboard scanning matrices?
« Reply #1 on: Wed, 02 March 2011, 12:54:11 »
I need just the matrix size and eventually which keyboard it is. The matrix layout, i.e. key coordinates, is not needed at all.

Offline sixty

  • Posts: 984
    • http://deskthority.net
keyboard scanning matrices?
« Reply #2 on: Wed, 02 March 2011, 13:20:41 »
I suppose this is for your controller that you announced to be working on a while ago. If it is indeed for that, imo solve the problem like the Aikon. Offer 8x18 or something by default, but let them change rows and cols if needed. For example to 9x17.. etc

If that is not related to it, I have a collection of a few matrixes somewhere. I'll find it later.

woody

  •  Guest
keyboard scanning matrices?
« Reply #3 on: Wed, 02 March 2011, 14:44:44 »
It is indeed related. Still just tinkering with the idea, not sure what I will do and when (and whether at all), but collecting bits and pieces won't hurt.

Few example matrix sizes would be good information, thanks. It will be funny if the IC I have in mind doesn't have that much I/O.

Offline hasu

  • Posts: 3491
  • Location: Tokyo, Japan
  • @tmk
    • tmk keyboard firmware project
keyboard scanning matrices?
« Reply #4 on: Wed, 02 March 2011, 15:56:45 »
18x8, Cherry G80-3600-LYCEU-0
8x8, PFU HHKB professional(not 2)

woody

  •  Guest
keyboard scanning matrices?
« Reply #5 on: Wed, 02 March 2011, 17:19:53 »
14x8, Cherry G84-4400

woody

  •  Guest
keyboard scanning matrices?
« Reply #6 on: Thu, 03 March 2011, 10:44:20 »
14x8, Cherry G84-4100   (plus three LEDs on the keyboard PCB)

Offline Soarer

  • * Elevated Elder
  • Posts: 1918
  • Location: UK
keyboard scanning matrices?
« Reply #7 on: Thu, 03 March 2011, 10:58:44 »
13x8, Ortek MCK84
16x8, Cherry G80-8200 (NKRO)

Not sure it's worth listing all the ones that are 'something x 8' though :-/

Offline ch_123

  • * Exalted Elder
  • Posts: 5860
keyboard scanning matrices?
« Reply #8 on: Thu, 03 March 2011, 11:03:12 »
I'll dig up pictures of my SSK membrane later.

woody

  •  Guest
keyboard scanning matrices?
« Reply #9 on: Thu, 03 March 2011, 13:47:34 »
Quote from: Soarer;304263
Not sure it's worth listing all the ones that are 'something x 8' though :-/

Are there any that aren't x8? Looks they choose to be lazy and fitted the readback data into a single port.

What I don't like so far is the MCU I have has only 23 I/Os. Bummer.

Offline Soarer

  • * Elevated Elder
  • Posts: 1918
  • Location: UK
keyboard scanning matrices?
« Reply #10 on: Thu, 03 March 2011, 14:12:54 »
Quote from: woody;304387
Are there any that aren't x8? Looks they choose to be lazy and fitted the readback data into a single port.


I bet there's at least one awkward board out there! But 8 is the sensible size to use - it's not just the reading, it's the processing after that as well. The processors might have a 4MHz clock, but (I think) they're 4 clocks per instruction cycle, and some instructions will take more than one cycle... so not the most powerful!

Quote from: woody;304387
What I don't like so far is the MCU I have has only 23 I/Os. Bummer.


Not really enough :(

Of course, you could use a 3 to 8 line decoder or two on the output side, since only one line at a time is active. Or an external latch on the input side. Bit messy.

The Ortek does a neat trick of using 3 diodes so it can use 3 of the lines for both LEDs and scanning.

woody

  •  Guest
keyboard scanning matrices?
« Reply #11 on: Thu, 03 March 2011, 14:19:24 »
Yup, many solutions to I/O extending. None as simple as matrix with min. required rows/columns (square root of key count).

Offline Soarer

  • * Elevated Elder
  • Posts: 1918
  • Location: UK
keyboard scanning matrices?
« Reply #12 on: Thu, 03 March 2011, 14:44:18 »
Hmm. Let's say we want to allow for 128 keys. That's 16x8, so 24 lines.

Or... sqrt(128) = 11.314 ... which needs to be rounded up to 12x11, so 23 lines.

OK, 23 fits your chip and 24 doesn't, but in general Nx8 isn't particularly inefficient.

The worst waste of lines comes from modifiers on non-NKRO boards :-/

woody

  •  Guest
keyboard scanning matrices?
« Reply #13 on: Thu, 03 March 2011, 15:24:13 »
Quote from: Soarer;304439
The worst waste of lines comes from modifiers on non-NKRO boards :-/

That might explain the strange matrices I traced on 4100 and 4400 (both 14x8).

Offline sixty

  • Posts: 984
    • http://deskthority.net
keyboard scanning matrices?
« Reply #14 on: Thu, 03 March 2011, 15:33:35 »
most apple boards are _x9 btw.

woody

  •  Guest
keyboard scanning matrices?
« Reply #15 on: Thu, 03 March 2011, 17:12:55 »
Quote from: sixty;304479
most apple boards are _x9 btw.
That got me intrigued. Took apart Apple Keyboard II (M0487), membrane with upside-down rubber sleeves and ... my desk doesn't have enough space to have the guts and a IIgs on it to be checked with LA. Meh, some other time.

EDIT: BTW, it's Mitsumi inside.