Connecting 6 push buttons with ESP32 with 1 common pin

Thread Starter

StealthRT

Joined Mar 20, 2009
303
Hey all I have 6 buttons that have the following voltage:

enter image description here









I want to hook up a 4N25 to each one of these so I can use the ESP32 as a "virtual push" to each of these buttons. When the button is pressed the 3.2vdc goes to ground.

enter image description here







To minimize the amount of wire going to each one I have come up with the following:

enter image description here















Is it possible to just hook 1 of the buttons left/bottom pins to all of the 4N25 chips so that I don't have to run 2 wires per button? Or is there a better way of doing this that will minimize the amount of wires?

The switches are connected to a TM1650 chip.
 
Last edited:

Jon Chandler

Joined Jun 12, 2008
1,029
From another forum, the switches are connected to a TM1650 and scanned as a switch matrix.

So the short answer is no.

The long answer is no, this won't work.
 

ronsimpson

Joined Oct 7, 2019
2,989
I have read this question on another forum and totally do not understand any part.
Picture-1, buttons and voltages. Totally do not understand. Picture-2 and -3 the same.
Why do you need opto isolators?
The 3.3V on the computer and the 3.3V on the keyboard, are they the same supply?
 

Jon Chandler

Joined Jun 12, 2008
1,029
The poster wants to use an ESP32 to short the contacts (as clarified in the other forum – grrrrr, that makes me irate) to use the ESP32 outputs to effectively "push the buttons."

The TM1650 uses a scanned keypad matrix and (from the same pins) a multiplexed LED display therefore no part of the switch can be tied to V+ or ground.

Aside from relay contacts shorting the switch contacts, I don't see any way to accomplish this that totally isolates the circuit from V+ and ground.
 

Sensacell

Joined Jun 19, 2012
3,432
It should work if you determine which direction the current normally flows when each switch is activated, connect the individual photo isolator pins E and C to the appropriate terminals so the transistor conducts in the right direction.

A single common is probably not workable, since it's a multiplexed switch matrix.
 
Top