Ghost keys on kbd matrix

Do you have a question? Post it now! No Registration Necessary

Translate This Thread From English to

Threaded View
Wow, I got bit pretty hard on a switch matrix I designed. I just threw the
thing together, row and column, and of course, once three switches are on
everything goes to hell.

The application is not a keyboard, I need to several dip switches (96
switches in all), and any combination of the switches may be on or off.

My eyes are bugging out trying to trace through the different combinations.
Do I need a diode for each switch, or just for the rows and columns?

Thanks,

Mike



Re: Ghost keys on kbd matrix
On Wed, 1 Sep 2004 19:26:44 -0700, the renowned "Mike Turco"

Quoted text here. Click to load it

If you are scanning an x-y matrix, you need a diode for each switch.
If your inputs are TTL compatible and outputs are CMOS and Vdd is 5V
you can use pull-downs and stay within specs with some margin.

Best regards,
Spehro Pefhany
--
"it's the network..."                          "The Journey is the reward"
snipped-for-privacy@interlog.com             Info for manufacturers: http://www.trexon.com
We've slightly trimmed the long signature. Click to see the full one.
Re: Ghost keys on kbd matrix


Quoted text here. Click to load it

Besides a wire to each sw, Is there any way to do this other than an x-y
matrix?



Re: Ghost keys on kbd matrix
On Wed, 1 Sep 2004 22:30:45 -0700, the renowned "Mike Turco"

Quoted text here. Click to load it

Offhand, I can't think of any, sorry (but hey, it's late).

Consider the case where every switch is closed save one, then look at
the difference of the last one being on or off.

Of course, it's possible to use shift registers and/or
(de)multiplexers to get your one wire to each sw rather than using
diodes.

Best regards,
Spehro Pefhany
--
"it's the network..."                          "The Journey is the reward"
snipped-for-privacy@interlog.com             Info for manufacturers: http://www.trexon.com
We've slightly trimmed the long signature. Click to see the full one.
Re: Ghost keys on kbd matrix
Quoted text here. Click to load it

  You can use a sea of shift registers, but that might count as a
wire-per-switch (but so can a matrix ) ?
  You can also wire two switches across each cross point, by using
two diodes in opposite directions, and smarter scan scheme,
which doubles the matrix density.
  Or, you can wire binary weighted resistors on each switch,
in small groups of 4-5, and use an analog scan scan to extract
the bit information....

-jg


Re: Ghost keys on kbd matrix
Quoted text here. Click to load it
... snip ...
Quoted text here. Click to load it

Search the literature, including this group in the past 5 years.
There are some ingenious designs out there that eliminate all
components and yet detect multiple key downs, rollover, etc.  The
basic cost is that the full x*y combinations are not available.

--
A: Because it fouls the order in which people normally read text.
Q: Why is top-posting such a bad thing?
We've slightly trimmed the long signature. Click to see the full one.
Re: Ghost keys on kbd matrix

Quoted text here. Click to load it

Unfortunately, the OP said:
Quoted text here. Click to load it

Which means he probably doesn't care that much about rollover, for example, and
that he wants to support all 2^96 possible permutations (though I've no idea
why.)  Anyway, it's a problem and a pain to many 'ingenious' methods.

Jon

Re: Ghost keys on kbd matrix
Quoted text here. Click to load it

That does smell like 96 isolation diodes, at least 8 resistors,
and an 8 x 12 scanning matrix.

--
Some similarities between GWB and Mussolini:
a) The strut;  b) Making war until brought up short:
We've slightly trimmed the long signature. Click to see the full one.
Re: Ghost keys on kbd matrix
 
Put the switches in a series string with resistors like this...

100_Ohm --- 200_Ohm --- 400_Ohm --- 800_Ohm --- 1.6_KOhm --- 3.2_KOhm --- ...
         |           |           |           |           |           |
         |           |           |           |           |           |
         -- SWITCH ---- SWITCH ---- SWITCH ---- SWITCH ---- SWITCH --- ...

...and use the entire string in a RC circuit like this...

DIGITAL OUT --- RESISTOR_SWITCH_STRING ------ DIGITAL IN
                                          |
                                          |
                                        -----
                                        ----- C
                                          |
                                          |
                                        -----
                                         --- GND

...to measure the resistance by measuring the delay.  This will allow
you to tell if any combination of switches are closed - each combination
has a unique total resistance.

You might want to have several such circuits so as to keep the end
resistors from being too large/small, to keep it from being too slow,
or avoid having to use precision components and from having to
calibrate.

  

--
Guy Macon <http://www.guymacon.com


Re: Ghost keys on kbd matrix

Quoted text here. Click to load it

with 2^96 permutations possible, it's pretty certain that the OP would have to
break things up a lot, given what you are talking about with delay timing.  Not
a 'might want,' but a *must have*.  It's very hard to imagine a single system of
time delays, given about 8E28 permutations to separately observe, that could be
discerned in human lifetimes though a single arrangement.  :)

In any case, 96 diodes start looking really good when compared against ~96
resistors, some number of capacitors, and trying to discern timing.

I wonder if the OP really needs all 8E28 permutations, though.

Jon

Re: Ghost keys on kbd matrix

Quoted text here. Click to load it

Twelve strings with eight switches each could be managed.  If the I/O
can be tri-stated, you would only need one capacitor and one digital
input , and would be using 13 I/O lines as opposed to the 20 that
a 10x10 or 12x8 matrix would use.

Quoted text here. Click to load it

Can 96 diodes handle the all switches closed except one case?


Re: Ghost keys on kbd matrix

Quoted text here. Click to load it

yes.

Jon

Re: Ghost keys on kbd matrix

Thanks to all!

Quoted text here. Click to load it

I think I'm going to go with the 96 wires. Given the actual application, its
going to save me a lot of money and board space.

Quoted text here. Click to load it

Each switch represents something independent of all the other switches. (Its
a crazy mixed up world :-)


Mike



Re: Ghost keys on kbd matrix
Quoted text here. Click to load it

At that density I'd consider an EEPROM and some display / simpler keypad to
set the numerous settings.



Re: Ghost keys on kbd matrix
On Thu, 2 Sep 2004 12:04:52 -0400, the renowned "John Harlow"

Quoted text here. Click to load it

One aspect that needs consideration is testing- fully testing a setup
like that *requires* physically operating each of the 96 switches
individually.

OTOH, switches are easier to understand for some users and don't flip
states even with the worst EMI.  

Best regards,
Spehro Pefhany
--
"it's the network..."                          "The Journey is the reward"
snipped-for-privacy@interlog.com             Info for manufacturers: http://www.trexon.com
We've slightly trimmed the long signature. Click to see the full one.
Re: Ghost keys on kbd matrix
Quoted text here. Click to load it

Quite true, but consider the EEPROM route can be quickly set to "factory"
settings and allow for settings to be easily transferred to other systems,
and can keep customer's statically charged hands away from potentially
dangerous voltage levels.




Re: Ghost keys on kbd matrix

Quoted text here. Click to load it

"Fully testing" a parameter space of 2^96?  You must be kidding.  Even
"literally forever" doesn't come close to describing how long that
would take.

--
Hans-Bernhard Broeker ( snipped-for-privacy@physik.rwth-aachen.de)
Even if all the snow were burnt, ashes would remain.

Re: Ghost keys on kbd matrix
On 3 Sep 2004 10:31:21 GMT, the renowned Hans-Bernhard Broeker

Quoted text here. Click to load it

I wondered if someone would pick up on that. Operating one switch at a
time, with the others in the opposite state, (I think) will get ALL
faults that are shorts/opens/missing or defective parts. That's (O) 96
operations, not (O) 2^96. Of course it's possible for there to be
other faults (for example, if there was heavy PCB leakage that caused
a wrong state when several switches were closed), but that is much
less likely. Operating 96 switches by hand is still a PITA. I recently
built a test routine into a product to check 16 dipswitches and
immediately found a problem with my prototype (two port pins shorted).

Best regards,
Spehro Pefhany
--
"it's the network..."                          "The Journey is the reward"
snipped-for-privacy@interlog.com             Info for manufacturers: http://www.trexon.com
We've slightly trimmed the long signature. Click to see the full one.
Re: Ghost keys on kbd matrix

Quoted text here. Click to load it

Walking ones followed by walking zeros; it's a great RAM test
and this switch matrix is in one sense a RAM...



Re: Ghost keys on kbd matrix
Quoted text here. Click to load it

Gee, how about an 8-pin microcontroller with 64 bytes of EEPROM, and a
MAX232 so you can program it from a standard serial port? Smaller,
cheaper, less bugging out of the eyes.

Site Timeline