Multi-function joystick buttons without relays

I've successfully interfaced an xbox controller with my pc via USB and autohotkey scripting. What I'm stuck on now is figuring out the wiring for creating alternate functionality in each button.

Say I have five buttons - A B C D E - on the joystick. Each button is a SPST momentary switch, which pulls to ground when activated. I now want to introduce button X to the mix. Which means wiring X across buttons A through E so that X is now also activated with each press of A through E (similar idea to having a second keyboard where all characters are capitalized by default). Can it be done without use of PICs, DPST switches or relays for each button?

Reply to
S Rated
Loading thread data ...

yes, use an AND gate or a "diode and"

Reply to
Jasen Betts

s
f

I'm not sure I follow how you'd accomplish this with logic gates. Would you mind explaining how you would go about wiring this?

I want to effectively create another set of buttons - AX BX CX DX EX - by wiring up five additional momentary switches. When the AX button is pressed, it not only pulls A to ground but also X. Thus, the joystick controller simply sees this as simultaneous pressing of A and X.

Reply to
S Rated

It's also known as the diode-or:

formatting link

In the first circuit shown, the +5VA, B, and C each have a pullup R (4.7k-22k) to the +5v., and the button to ground is to the left of each diode. The one they have labeled "TERMPOWER OUT" is your "X".

Have Fun! Rich

Reply to
Rich Grise

Existing: ___ Gnd---+---o o---A----------------------------+-->

| ___ | +---o o---B----------------------+--> | | ___ | | +---o o---C----------------+--> | | | ___ | | | +---o o---D----------+--> | | | | ___ | | | | +---o o---E----+--> | | | | | | | | | Added: | | | | | [D1] [D2] [D3] [D4] [D5] ___ | | | | | Gnd---+---o o---EX---+--> | | | | | ___ | | | | +---o o---DX---------+--> | | | | ___ | | | +---o o---CX---------------+--> | | | ___ | | +---o o---BX---------------------+--> | | ___ | +---o o---AX---------------------------+-->

The banded end of each diode is at the bottom.

Ed

Reply to
ehsjr

I thought you wanted something slightly different.

UPPERCASE = outputs lowercase = inputs (low when pressed)

A = a ? ax B = b ? bx C = c ? cx D = d ? dx E = e ? ex X = ax ? bx ? cx ? dx ? ex (I used an uncommon symbols if it doesn't show correctly '?' is 'and')

Reply to
Jasen Betts

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.