r/electronic_circuits

Image 1 — How to properly discharge the capacitors of a DC/DC switching circuit after primary supply voltage has been switched off?
Image 2 — How to properly discharge the capacitors of a DC/DC switching circuit after primary supply voltage has been switched off?
Image 3 — How to properly discharge the capacitors of a DC/DC switching circuit after primary supply voltage has been switched off?

How to properly discharge the capacitors of a DC/DC switching circuit after primary supply voltage has been switched off?

I am designing a DC/DC switching circuit based on TI's TPS62136 which steps down 12.5V-14.5V DC input to 11.6-ish V output. Figure 1 shows the schematics.

The primary supply voltage is hot-plugged to the input. The load is not a resistive load, but requires a forward voltage around 9-ish V, i.e. at some point during ramp-up/ramp-down of the secondary side the load becomes conductive/non-conductive.

As all specimen of my first attempt failed miserably during the 2nd power-cycle, I got a lot of helpful suggestions on this sub-reddit what I could improve.

One of the advices has been to considerably decrease the resistance of the voltage dividers (R1+R2 and R3+R4) to provide a safe path for the input/output capacitors to discharge when there is no input power. The advice pointed out that without an alternative path the capacitors might discharge trough the IC and destroy it.

While I decreased the total resistance of the voltage dividers significantly, the result isn't as expected. (TI's original reference design uses voltage dividers in the mega ohms, now it's only kilo ohms.) Here are the two main issues:

  1. There is indeed a reverse current around 100mA through the SW pin of the IC when being power-off which is responsible for the bulk of discharging the output capacitors.
  2. The input side still remains energized for quite a long time, as the time constant is approximately τ ≅ 450ms. (Note, the derated capacitance due to the DC bias is about 99µF not 2×47µF + 2×10µF = 114µF.)

Figure 2 shows the voltages: At 10.2ms the input supply is switched-off. Vic and Vout drop rapidly until Vic reaches 10.9V, then the IC switches off as EN drops below its 0.7V reference voltage. From there on, Vout smoothly decreases, i.e. C6+C7 are discharged, but Vic remains high.

Figure 3 shows some relevant currents: i(R503) (blue) is the current through the SW pin of the IC, i(V1) (orange) is the current through the simulated voltage supply and i(R204) (red) is the simulated load. At 10.2ms the current through i(V1) and i(R204) drops to zero, but one can see a reverse current of -100ms trough i(R503), i.e. the SW pin.

Here are my questions:

  1. Should I be worried about the -100ms reverse current through SW and should I do something about it? Are reverse currents a problem after all? The data sheet doesn't say anything about it. The data sheet neither warns about it nor explicitly states that it is fine. However, I wonder if it was an issues and had the potential to destroy the IC, I would have assumed that more people would report problems and there would be a warning. However, it could explain why my first batch failed on the 2nd power cycle.
  2. Should I be worried that Vic and the IC remain high and powered for quite some time? I cannot decrease the voltage divider any further without sacrificing efficiency and getting close to the maximum power rating of the resistors.
  3. Is there any better suited and recommended option to properly de-energize the circuit (input and output capacitors) during power off? My thoughts went into a direction of using MOSFETs of depletion type which are self-conductive and then construct something in the spirit of the slow-start mechanism which works the opposite way and shortens Vic/Vout to GND via a resistor with about 100Ω. But that was just a spontaneous idea. Probably there is something better. However, if possible I would like to keep it simply and not add more complexity to the circuit, if it isn't necessary.
u/MobileInspector9861 — 11 hours ago

Something pop in my sewing machine

*popped

Was dumb and plugged my American sewing machine in a Europe plug socket w/o adapter. I suspect at the very least the gray thing left of the red marks need replacing but I don't know what it is. Also maybe the power supply part? Its a bit sooty.

Any advice?

u/acdvdmm — 6 days ago

Ultra-low-cost Buck Converter IC for Smart Switch (90-270VAC to 12V/300mA) in a highly unstable grid

Hello everyone,

I am currently designing a non-isolated Buck converter power supply that will be integrated into a smart home wall switch. Due to the very constrained space inside the standard junction box, keeping the footprint and BOM count as small as possible is a major priority.

Additionally, the local electrical grid here in my country is highly unstable. The AC input can fluctuate anywhere from 90V up to 270V AC (and sometimes spikes up to 290V).

Here are my core design requirements:

Topology: Non-isolated Buck (High-side)

Input: 90V - 270VAC (needs to survive harsh 290V transients)

Output: 12V DC

Load Current: 220mA continuous (Targeting a 300mA capable IC for thermal headroom and stability)

Cost: Must be extremely cheap for mass production via Chinese PCBA houses (JLCPCB, etc.).

My Current Progress & Dilemma:

I built a prototype on a perfboard using the classic VIPer22A. It works, but I have some concerns. Its switching frequency is around 60kHz. I am wondering if 60kHz is ideal for this kind of compact application, or if I should move to a higher frequency IC to reduce the inductor size (since smaller size is a huge plus for me).

I also evaluated the LNK306 (and a few other LinkSwitch ICs). They are absolutely fantastic, and the low BOM count is exactly what I need. However, when pricing them out for mass production, the IC alone costs around $0.80 - $1.00+, which completely kills the profit margin for a cheap smart switch.

I know ICs like the PN801x or BP2525 are often used in cheap Chinese smart plugs. However, these specific ICs are completely unavailable in my local electronics market for building and testing the initial physical prototypes.

My Questions for the Community:

Is the VIPer22A at 60kHz still a viable and reliable option for commercial smart switches today, or is the required inductor size going to be a bottleneck for a wall box?

If I want to minimize the inductor size (higher frequency) but keep the mass production IC cost down to pennies, what are the best alternatives? How do you guys handle prototyping when your target mass-production IC isn't available locally?

Could you recommend any reliable simulation software or online tools specifically for offline AC-DC non-isolated buck converters? Most tools I find focus heavily on DC-DC.

How do you accurately estimate the wholesale/mass-production BOM cost for components from Chinese suppliers (e.g., LCSC) to calculate the final product cost before committing to a run?

I appreciate any IC recommendations or design insights you can share. Thanks!

reddit.com
u/Elegant_Back9525 — 5 days ago
▲ 13 r/electronic_circuits+3 crossposts

Sony CDP-C77ES display only works with power button fully pressed in

I have no idea why this is happening i cleaned everything with contact cleaner and its still the same any advice is appreciated.

u/Overall-Number-6956 — 6 days ago

Is there a way to use a BC547 NPN transistor as a reliable on off switch for nodemcu pins connection

Hello, as the title says is it possible to do?

More details

I'm building a primitive water level sensor to use with my nodemcu,

I don't have access to a lot of the sensors I did try to get an ultrasonic sensor which was very very bad so after some researching I found the best way is just to get a PPR pipe which is locally available and stick a bunch of graphite rods in it

But I ran into an issue where I wanted some resolution for the level sensing so I put eight levels but the node MCU doesn't support that many pins so I thought of a good idea for multiplexing since I don't have access to an I2C board to expand the pin number

The idea was that the top level probes would be connected directly to the pins and the lower level probes will be connected through a transistor switch so when I read the top level if it reaches any of them then the lower levels mean nothing and if the top levels are not rich then I switch to lower levels and read those but I only have npn transistors type bc547

The way the sensor is going to work there is a probe that is for sending at the very bottom of the pipe and the reading probes are above it when I do want to take a read I put the sender probe to high meaning it goes to 3.3 volts and the other problem receive that 3.3 volts the voltage needed for the node MCU to register it clearly is above 2 and maybe 2.4 volts can this be done reliably

I did try you searching for a long time and all I got is some complicated answers ai gave me some answers but it was very flaky and unreliable it the contradicted itself a lot times most of the time about the the minimum voltage required and currently cash and other stuff that I'm not really an expert about

So to recap I want to use four transistors controlled by a separate pin to turn them on and off and turning them on Bridges a gap between the lower probe and the corresponding pin

If it's doable can you explain the limitations like leaking and voltage drops as i am a beginner and thanks 🙏

reddit.com
u/SOLID-DevMan — 9 days ago

Troubleshooting a button box I bought online

I bought an Arduino based button box with an LED flag box, but the button part of it isn't working. I don't want to say the brand or store, so I don't create any bad press, especially since I've been emailing them back and forth, trying to fix this problem, and they genuinely want to help make it work, but nothing has helped so far. Wondering if anyone has any experience with this type of device.

The problem is, one button is always on, except if some other buttons are pressed. Half the other buttons / toggles don't work at all. The LED flag box works fine, though.

I took pictures of the interior, and he says it seems to be connected correctly. We also re-flashed the firmware, but no luck.

At this point, I think the only thing left, is to request a refund, but wondering if there's anything else I could try first.

reddit.com
u/warlock257 — 8 days ago