Searching \ for '[OT:] different approach to keyboard scanning?' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/index.htm?key=different+approach
Search entire site for: 'different approach to keyboard scanning?'.

Exact match. Not showing close matches.
PICList Thread
'[OT:] different approach to keyboard scanning?'
2003\04\12@180606 by James Newton, webhost

face picon face
source= http://www.piclist.com/postbot.asp?id=piclist\2003\04\11\174744a

Let me see if I have all this right. Combining Scott and Eric's comments you
could do this:

   0   1   2   3  GND
   |   |   |   |   |
0---+--KEY-KEY-KEY-KEY-
   |   |   |   |   |
1---+---+--KEY-KEY-KEY-
   |   |   |   |   |
2---+---+---+--KEY-KEY-
   |   |   |   |   |
3---+---+---+---+--KEY-
   |   |   |   |   |

Weak pull-ups enabled, first read the port and check for any lows, this
would be a key on the GND (far right) column. If all pins are high, ground
pin 0 and any lows on 1 thru 3 would be a key in the top row. Then ground 1
and a low on 2 or 3 indicates the two keys on the second row (other than the
last column), finally ground 2 and check the remaining key (on the third
row) by reading back 3.

That is a 10 key pad in 4 IO lines with no external components other than
the keys.

---
James Newton: PICList.com webmaster, former Admin #3
spam_OUTjamesnewtonTakeThisOuTspampiclist.com  1-619-652-0593 phone
http://www.piclist.com/member/JMN-EFP-786
PIC/PICList FAQ: http://www.piclist.com

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads

2003\04\12@183757 by Herbert Graf

flavicon
face
Wow, thanks for the summary, I didn't notice this thread until now. That is
an excellent design! 10keys with only 4 I/O ports used!?? Gonna file this
one in my "info" file... TTYL

> {Original Message removed}

2003\04\14@010742 by Carey Fisher - NCS

picon face
part 1 2888 bytes content-type:text/plain; (decoded 7bit)

Would you believe you can read 75 switches with 5 I/O lines?  Check out the
attached Word doc. It has a couple methods for reading many switches with
few I/O lines.


----- Original Message -----
From: "Herbert Graf" <.....mailinglistKILLspamspam@spam@FARCITE.NET>
To: <PICLISTspamKILLspamMITVMA.MIT.EDU>
Sent: Saturday, April 12, 2003 6:37 PM
Subject: Re: [OT:] different approach to keyboard scanning?


> Wow, thanks for the summary, I didn't notice this thread until now. That
is
> an excellent design! 10keys with only 4 I/O ports used!?? Gonna file this
> one in my "info" file... TTYL
>
> > {Original Message removed}
part 2 29221 bytes content-type:application/msword; (decode)

part 3 2 bytes
-

2003\04\14@024338 by Stuart Meier

flavicon
picon face
PLease do not send Word attachments. Can you resumit as text/gif

Stuart
----- Original Message -----
From: "Carey Fisher - NCS" <.....ncsKILLspamspam.....NCSRADIO.COM>
To: <EraseMEPICLISTspam_OUTspamTakeThisOuTMITVMA.MIT.EDU>
Sent: 14 April 2003 06:07
Subject: Re: [OT:] different approach to keyboard scanning?


{Quote hidden}

> > > {Original Message removed}

2003\04\14@042853 by hael Rigby-Jones

picon face
> -----Original Message-----
> From: Herbert Graf [SMTP:KILLspammailinglistKILLspamspamFARCITE.NET]
> Sent: Saturday, April 12, 2003 11:38 PM
> To:   RemoveMEPICLISTTakeThisOuTspamMITVMA.MIT.EDU
> Subject:      Re: [OT:] different approach to keyboard scanning?
>
> Wow, thanks for the summary, I didn't notice this thread until now. That
> is
> an excellent design! 10keys with only 4 I/O ports used!?? Gonna file this
> one in my "info" file... TTYL
>
>
Dennis Crawley recently posted a complete project using an idea I had a few
years back at http://www.mikerj.clara.net/keypad.html . The subject was
[PIC]:4x4&LCD in 1port

Regards

Mike



=======================================================================
This e-mail is intended for the person it is addressed to only. The
information contained in it may be confidential and/or protected by
law. If you are not the intended recipient of this message, you must
not make any use of this information, or copy or show it to any
person. Please contact us immediately to tell us that you have
received this e-mail, and return the original to us. Any use,
forwarding, printing or copying of this message is strictly prohibited.
No part of this message can be considered a request for goods or
services.
=======================================================================
Any questions about Bookham's E-Mail service should be directed to spamBeGonepostmasterspamBeGonespambookham.com.

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.

2003\04\14@122115 by Michael Park

picon face
{Quote hidden}

Unfortunately you don't get n-key rollover this way (something I require,
but that's just me), so you might as well fill in the lower half of the
triangle and get 16 keys, no?

   0   1   2   3  GND
   |   |   |   |   |
0---+--KEY-KEY-KEY-KEY-
   |   |   |   |   |
1--KEY--+--KEY-KEY-KEY-
   |   |   |   |   |
2--KEY-KEY--+--KEY-KEY-
   |   |   |   |   |
3--KEY-KEY-KEY--+--KEY-
   |   |   |   |   |

Btw, why did this thread become [OT]?  Should I have marked my original
query [OT]?

_________________________________________________________________
STOP MORE SPAM with the new MSN 8 and get 2 months FREE*
http://join.msn.com/?page=features/junkmail

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.

2003\04\14@221121 by Eric Bohlman

picon face
4/14/03 10:32:52 AM, Michael Park <RemoveMEmp__spamTakeThisOuTHOTMAIL.COM> wrote:

>Unfortunately you don't get n-key rollover this way (something I require,
>but that's just me), so you might as well fill in the lower half of the
>triangle and get 16 keys, no?
>
>    0   1   2   3  GND
>    |   |   |   |   |
>0---+--KEY-KEY-KEY-KEY-
>    |   |   |   |   |
>1--KEY--+--KEY-KEY-KEY-
>    |   |   |   |   |
>2--KEY-KEY--+--KEY-KEY-
>    |   |   |   |   |
>3--KEY-KEY-KEY--+--KEY-
>    |   |   |   |   |

Won't work, unless you put diodes in series with the keys.  Otherwise, there's no way to distinguish
between, say, the first key (going left-to-right and top-to-bottom) from the fifth key; they're both
at the intersection of port bit 0 and port bit 1.

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.

2003\04\16@102732 by Edson Brusque

face
flavicon
face
Hello,

    I've been thinking about using the PIC A/D to scan a 16 keys
keyboard. The example bellow have only 4 keys for simplicity:

            ,----K1----VDD
            |
            1k
            |
            +----K2----VDD
            |
            1k
            |
            +----K3----VDD
            |
            1k
            |
     ADC----+----K4----VDD
            |
            1k
            |
           GND

    Without any key pressed, the ADC would read 0V, with K1 pressed it
would be 1.25V, with K2=1.66V, K3=2.5V, K4=5V.

    I think this would be very interesting for projects using a PIC
with ADC and short of I/O.

    Best regards,

    Brusque

--
-----------------------------------------------------------------
Edson Brusque                 C.I.Tronics Lighting Designers Ltda
Research and Development               Blumenau  -  SC  -  Brazil
Say NO to HTML mail                          http://www.citronics.com.br
-----------------------------------------------------------------

--
http://www.piclist.com hint: To leave the PICList
piclist-unsubscribe-requestEraseMEspam.....mitvma.mit.edu>

2003\04\16@103911 by Wagner Lipnharski

flavicon
face
Edson Brusque wrote:
{Quote hidden}

Other than that, look this design we made and used 11 years ago;

http://www.ustr.net/electronics/akeys.shtml

Wagner.

--
http://www.piclist.com hint: To leave the PICList
EraseMEpiclist-unsubscribe-requestspammitvma.mit.edu>

2003\04\16@110322 by Larry G. Nelson Sr.

picon face
Another method is to use an R / 2R ladder configuration. That allows you to
have multiple key presses or chording. There is a real limit due to
resolution of the converter and accuracy of the components but this method
lets you use resistor networks and the absolute value is less important
than the match between components. 4 buttons allows 16 combinations and
works well with a PIC 8 bit converter. I did this 7 or 8 years ago and many
of you probably have used the product it is in.
Larry



At 10:34 AM 4/16/03 -0400, Wagner Lipnharski wrote:
{Quote hidden}

Larry G. Nelson Sr.
RemoveMEL.Nelsonspam_OUTspamKILLspamieee.org
http://www.mchipguru.com

--
http://www.piclist.com hint: To leave the PICList
RemoveMEpiclist-unsubscribe-requestTakeThisOuTspamspammitvma.mit.edu>

2003\04\16@151821 by Talmage Wesley

flavicon
face
Just saw this approach, and wondered how does one know which combinations
are presed?


And how can one press all 4 buttons at once and get correct output?

{Original Message removed}

2003\04\28@085256 by Larry G. Nelson Sr.
picon face
It works like a D/A with each switch being a binary count input. 1,2,4,8,...
The number represented by the switch combo is translated to an analog value
by the R/2R ladder and the A/D reads the value. You use a look up table
type of code to determine the switch combo ie if between 1.05 and 1.35 it
is switches 3 and 5 or some such value you have calculated. The problem is
in the number of switches. Theoretically you can use 8 switches with an 8
bit converter but with tolerances and noise I usually have 4 or 5 that I
set as a limit.
Larry


At 02:24 PM 4/16/03 -0500, you wrote:
>Just saw this approach, and wondered how does one know which combinations
>are presed?
>
>
>And how can one press all 4 buttons at once and get correct output?
>
>{Original Message removed}

2003\04\28@173719 by Walter Banks

picon face
Michael Park wrote:

> Unfortunately you don't get n-key rollover this way (something I require,
> but that's just me),

Most keyboards no longer use diodes to achieve n key roll over. (Many also only
support
2 or 3 key rollover) They do it by by tracking in software what they know the
previous state of the
keyboard was and comparing the current scan with the previous one and logically
determining
what was pressed in between.

w..

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

More... (looser matching)
- Last day of these posts
- In 2003 , 2004 only
- Today
- New search...