Switch Multiplexing

Status
Not open for further replies.
Yeah the third button is to scroll through the options you want to change.

Thanks Nigel, the double diode method appears to be my best bet.
I like to keep things simple...
 
Disclaimer:
the circuit listed below is only to show the LOGIG behind switch multiplexing . the parts listed such as 74AC11160 may NOT work as described .. it was my intention to show only the logic connections required.. your choice of specific chips may vary..ie an LS160 will work..
also all connections to get the 138 to work properly are not described..
With that said i believe the circuit will work..
 

Attachments

  • sw_multiplexer.sch
    44.9 KB · Views: 272

It might have helped if you had posted it in a readable format?, only a small number of people can probably read the file (I'm not one of them!). You should use popular graphics formats, and not obscure proprietary formats which require people to have the same package as you. For a diagram, GIF is an excellent choice, as it gives full quality and excellent compression.
 
Exactly, I like Eagle, but I don't like to install it just to view somebody's scheme! Post it in GIF, so that more people can help you.
 
sorry , i thought every one on here had eagle layout SW
EDIT : disclaimer still applies..
 

Attachments

  • switch_multiplexer.gif
    8.5 KB · Views: 638
williB said:
sorry , i thought every one on here had eagle layout SW
EDIT : disclaimer still applies..
What's the purpose of 3 paralell resistors?

EDIT: And I think this is just too complicated to save 1 PIN (2 IC's !!!)
I think 4017 would serve well!
 
lol , good point i suppose only one is really needed..
EDIT: you dont see the usefullness because i didnt draw in more switches..
ie ONE 3X8 decoder can multiplex 8 different switches..
 
williB said:
sorry , i thought every one on here had eagle layout SW
EDIT : disclaimer still applies..

Notice that your GIF is only 20% the size of your SCH file?, and EVERYONE can see it, live on screen, without having to download it :lol:
 
congradulations Jay we just developed a switch multiplexing scheme for the pic , which can input any number of switch inputs and combinations of them...
because in one pass 0 to 9 of the counter if two switches are held down , the pic can determine that too !!
 
I know, this is Elegant solution! 8)
 

i suppose one of us should see if it actually works ..
 
Those are nice schemes guys, but half the fun and the challenge is to do it all with the PIC (grin)...

Regards, Mike
 
Mike said:
Those are nice schemes guys, but half the fun and the challenge is to do it all with the PIC (grin)...

Regards, Mike
If the PIC has A2D, then simple resistor Ladder is fine.

Or Nigels Diode sollution is nice,
 
One of my favorite schemes (borrowed from some popular Amateur Radio transceivers) is to use a Rotary Encoder with detent and built-in push-button switch on the shaft... It requires 3-pins for the A and B switch outputs and the push button switch output... It's relatively simple to decode a left or right turn and use this to increase or decrease a value (hours, minutes, seconds, perhaps?) or to scroll up or down through an LCD Menu System, etc... It's also relatively easy to detect 'short' and 'long' push button presses which can be used like <enter> and <esc> keys, among other things... It can really clean up a front panel...

Regards, Mike
 

It's called a 'port expander', specific chips are freely available for this purpose, both input and output versions - they are commonly used in VCR's and TV's.

The main problem is that you are greatly increasing the numbers of components used!.

If you need a fair amount of buttons, you could use a 16F628 to multiplex 56 keys (7x8 matrix) - using the remaining I/O pin to serially output the value of the key pressed - you could also make the spare pin an input, and wait for a signal to read the keypad. All this with one single 18 pin PIC, 56 switches, 7 resistors, a decoupling capacitor - AND NOTHING ELSE! - requiring only one I/O pin on your main PIC.
 
Nigel Goodwin said:
Notice that your GIF is only 20% the size of your SCH file?, and EVERYONE can see it, live on screen, without having to download it :lol:

Technically ... You do download it
 
Yeah ,but say you wanted to add 9 switches to your project and you only had one input and one optput left..
a single 4017 seems like a viable solution
* ducks and covers *
:lol:
EDIT : Nigel can your matrix detect two switches being pressed at the same time ??
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…