2 ESP32's GPIOs to same header pins isolation

Thread Starter

StealthRT

Joined Mar 20, 2009
304
Hey all I am wondering if my idea below would work.

What I am wanting to do is connect 2 (really 3 ESP32's and 4 ATmega32u4's) micro controllers (in the example there are just 2 ESP32's for simplicity) and they both connect to the same header pins.

enter image description here


I know that this would not work if both ESP32's were powered on but would this work if only 1 of the ESP32 were to be powered while the other has no power?

I was unsure if this type of setup would cause an issue with one another? Or if this setup is fine as long as one is turned off?

If this would not work what could you suggest I can use in order to isolate the 2 ESP32's from each other? I was thinking a multiplexer but that would just allow 1 GPIO pin to then have 16 more GPIO pins for it.

I was also thinking about some type of reply but that would be a lot of relays to since the ESP32 has 25+ GPIO pins that I would connect to the headers.

There was another thought of using some type of optocoupler but like the suggestion above, this would also have many of them for the 25+ GPIOs.

Suggestions or confirmation would be great! Perhaps a IC that I have not heard of before that would be a good fit for this? Don't want to blow either up :)

Disclaimer: Also posted on
electronics.stackexchange.com
eevblog.com
electro-tech-online.com
 
Last edited:

BobTPH

Joined Jun 5, 2013
9,270
What is the function if the pin?

If all mcus but 1 use it as an input there is no problem connecting them together.

If more than one uses it as an output, how do you decide which is controlling it?
 

Thread Starter

StealthRT

Joined Mar 20, 2009
304
I figured the way I decide is to power only the one I am wanting to use at that time?

Each pin with be input or output. Digital or Analog.
 

Jon Chandler

Joined Jun 12, 2008
1,098
A long, long time ago, I connected my dot matrix and my daisy wheel parallel-interface printers in parallel to the parallel port on my Atari 800 computer.

If I turned on one printer or the other, it worked perfectly. If I turned on both printers at once, they very politely worked together. One would print a line, then the other the next. They shared the workload very nicely
 

Thread Starter

StealthRT

Joined Mar 20, 2009
304
A long, long time ago, I connected my dot matrix and my daisy wheel parallel-interface printers in parallel to the parallel port on my Atari 800 computer.

If I turned on one printer or the other, it worked perfectly. If I turned on both printers at once, they very politely worked together. One would print a line, then the other the next. They shared the workload very nicely
I thought you were going the Star Wars there for a second.

Would something like the 74HC157 be a good choice? I’m reading the data sheet on it and it seems to allow 4 gpio + 4 gpio and outputs one of them. But I’m not seeing anywhere about if it can do digital and analog since the gpio would be one or the other. Aside from that I’m also not seeing anywhere where the company makes a larger version that would have do more than 8 inputs.
 

ElectricSpidey

Joined Dec 2, 2017
2,882
Notice in my original post I asked, "All Digital?" when I recommended the 3-state Bus/line driver/buffer?

If you need analog, you will probably need a different solution.

Although I can't swear on that.
 

Thread Starter

StealthRT

Joined Mar 20, 2009
304
Thanks for all the replies! I'm going back to my drawing board to figure some things out with the knowledge I now have. Thanks!
:)
 
Top