Author Topic: Dual power-input switching circuit  (Read 953 times)

0 Members and 1 Guest are viewing this topic.

Offline volkspolizistTopic starter

  • Newbie
  • Posts: 5
  • Country: de
Dual power-input switching circuit
« on: August 11, 2026, 02:57:18 pm »

I designed this circuit and would like to verify that it will work as intended before ordering the PCB.

There are two power inputs: CN1 is a barrel jack, and U18 is a USB-C port controlled by USB-PD. If both power sources are connected at the same time, they should never be paralleled, since their voltages may be different.

The priority between the two sources does not really matter, but I designed it so that when CN1 supplies power, the USB-C power path is disconnected.

Will this circuit work as intended, including during plug/unplug transitions and other edge cases? Are there any failure modes I may have overlooked?
 

Offline Gribo

  • Frequent Contributor
  • **
  • Posts: 678
  • Country: ca
Re: Dual power-input switching circuit
« Reply #1 on: August 11, 2026, 05:10:13 pm »
Is it AI slop, or did you make it unreadable on purpose?
I am available for freelance work.
 
The following users thanked this post: UnijunctionTransistor

Offline volkspolizistTopic starter

  • Newbie
  • Posts: 5
  • Country: de
Re: Dual power-input switching circuit
« Reply #2 on: August 11, 2026, 05:19:41 pm »
Is it AI slop, or did you make it unreadable on purpose?
I agree its not beautiful but its definitely not unreadable
 

Offline UnijunctionTransistor

  • Frequent Contributor
  • **
  • Posts: 488
  • Country: us
  • Ohms Law: Resistance is futile.
Re: Dual power-input switching circuit
« Reply #3 on: August 11, 2026, 05:56:33 pm »
You are correct, it is not unreadable, but it is definitely hard to follow.

To me at least, I cannot really tell exactly how the switching action occurs in the area reproduced below. The wiring is convoluted, and showing the double Mosfets as building blocks without knowing whether they are N or P channel, gives a headache attempting to understand the signal flow.

It appears that you created the schematic with Easyeda. If so, in its library you can find the symbol shown as a pair of individual Mosfets within the same package.  It is fair easier to understand what is going on, and you can place the Mosfet symbols in a path which shows the signal flow.

Lastly, use the capabilities to change the wire weight to show the actual power lines, to differentiate from signal lines.
There are several other issues, but I will stop here.



[ Specified attachment is not available ]


« Last Edit: August 11, 2026, 06:01:57 pm by UnijunctionTransistor »
 

Offline volkspolizistTopic starter

  • Newbie
  • Posts: 5
  • Country: de
Re: Dual power-input switching circuit
« Reply #4 on: August 11, 2026, 06:01:08 pm »
Sorry for the confusing schematic, those are pnp's i just didnt spend that much on making it look good, it only needs to work, it was done on kicad I dont remember where the library come from though
 

Offline Doctorandus_P

  • Super Contributor
  • ***
  • Posts: 5368
  • Country: nl
Re: Dual power-input switching circuit
« Reply #5 on: August 11, 2026, 06:04:49 pm »
I did not look further when I saw wires drawn though the diodes at the top and though texts on other places. First draw a proper schematic, then I may have a second look.

Sloppy schematics are OK for "back of an envelope" ad hoc ideas, but if you want some sort of review, then first get your own schematic on order to increase the chance that others take you seriously. Such sloppy schematics is simply instant dismissal for me (and lots of others).
 

Online mariush

  • Super Contributor
  • ***
  • Posts: 5345
  • Country: ro
  • .
Re: Dual power-input switching circuit
« Reply #6 on: August 11, 2026, 06:28:39 pm »
Any particular reason you can't use a switch like let's say TPS2121 ?

TPS2121 : https://www.lcsc.com/product-detail/C485916.html

Two inputs, up to 22v on each input, up to 4.5A current through it, 56 mOhm resistance ... has options to select highest voltage, or override or do various things.
 

Offline volkspolizistTopic starter

  • Newbie
  • Posts: 5
  • Country: de
Re: Dual power-input switching circuit
« Reply #7 on: August 11, 2026, 06:31:10 pm »
Any particular reason you can't use a switch like let's say TPS2121 ?

TPS2121 : https://www.lcsc.com/product-detail/C485916.html

Two inputs, up to 22v on each input, up to 4.5A current through it, 56 mOhm resistance ... has options to select highest voltage, or override or do various things.
price, APM4953(UMW) is very cheap and the device isnt that power intensive
 

Online mariush

  • Super Contributor
  • ***
  • Posts: 5345
  • Country: ro
  • .
Re: Dual power-input switching circuit
« Reply #8 on: August 11, 2026, 09:46:36 pm »
Any particular reason you can't use a switch like let's say TPS2121 ?

TPS2121 : https://www.lcsc.com/product-detail/C485916.html

Two inputs, up to 22v on each input, up to 4.5A current through it, 56 mOhm resistance ... has options to select highest voltage, or override or do various things.
price, APM4953(UMW) is very cheap and the device isnt that power intensive

3 x 10 cents  + 2 x 5 cents  (bss123) + 5-10 cents for passives (resistors) = ~50 cents .. vs 1$ for single IC
not to mention the amount of pcb space all those passives will use.

If you don't negotiate a voltage higher than 5v, TPS2116 is around 40-45 cents : https://www.lcsc.com/product-detail/C3235557.html ... max 5.5v inputs, 2.5A max
« Last Edit: August 11, 2026, 09:51:09 pm by mariush »
 

Offline xvr

  • Frequent Contributor
  • **
  • Posts: 921
  • Country: ie
    • LinkedIn
Re: Dual power-input switching circuit
« Reply #9 on: August 12, 2026, 10:24:56 am »
Quote
i just didnt spend that much on making it look good, it only needs to work,
Very often, a device works as well as its schematic looks.
 
The following users thanked this post: volkspolizist

Offline SteveThackery

  • Super Contributor
  • ***
  • Posts: 3379
  • Country: gb
  • 50 year novice
Re: Dual power-input switching circuit
« Reply #10 on: August 12, 2026, 10:32:14 am »
Sorry for the confusing schematic

Wow, that is EXTREMELY difficult to read. You can't really expect people to help with a schematic like that. I'm amazed you can understand it yourself. It would be a good exercise, and a learning opportunity, to clean it up. Oh, and don't be tempted to put every component in a box and join them all up with net labels - that is just as bad.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf

 

-->