CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Keypad intergration questions

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
kam



Joined: 15 Jul 2005
Posts: 59

View user's profile Send private message

Keypad intergration questions
PostPosted: Mon Jul 18, 2005 9:51 pm     Reply with quote

Hi all!

I have a need to interface to a keypad. From what I know (so far!), I can use 8 pins for a 4x4 matrix keypad etc....my question is, what if my keypad was 6x6? More pins? Different approach? Come to the realization that 6x6 is WAYYYYYY to much and that they should really want the 4x4? Wink

Thanks!

~Kam (^8*
Ttelmah
Guest







PostPosted: Tue Jul 19, 2005 4:20 am     Reply with quote

It all depends on how many pins your processor has available. Yes, you can just scan 6*6. Larger keyboards like this are commonly scanned just this way using a micro. However when the chip has to do something else as well, the typical solution, is to add an external multiplexer/demultiplexer to keep the pin count down. For instance, if you use a 3 to 8 line decoder, and drive this from three lines on the chip, you can scan a 8*6 keypad, using just 9 lines (six inputs, and three to drive the 'column select' using the decoder). Add a eight input multiplexer, and you can handle a 8*8 keyboard matrix, using just seven lines (three to turn on the column, three to select the row, and one input bit).
If the keyboard is a custom matrix, then consider designing the layout to simplify the pins needed. For example, you can scan a 4*8 matrix, using four output lines, one input line, and an eight input multiplexer, to give up to 32 keys (enough for a simple 'alpha' keypad, with a few extra control keys), on a single 8 pin port.

Best Wishes
treitmey



Joined: 23 Jan 2004
Posts: 1094
Location: Appleton,WI USA

View user's profile Send private message Visit poster's website

PostPosted: Tue Jul 19, 2005 10:22 am     Reply with quote

You could also use a keypad decoder chip. Then interface to that chip with for example 2 pins and I2C.
http://www.maxim-ic.com/appnotes.cfm/appnote_number/3414
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group