How to interface an arduino with a pcb which is powered by a capacitive dropper

Thread Starter

yxrip

Joined Oct 31, 2025
13
Hi
I'm not an engineer but a maker who is trying to become a repair technician.
I have this pcb of a product which i'm trying to repair and it doesn't have any transformer on it which after some research my strong guess is that it's powered by a capacitor dropper circuitry: no voltage regulators, 4 diodes as a rectifier, and zener diodes paired with capacitors feeding different parts of the pcb.
I wanna measure different timings on, but with a vague understanding I gathered from the internet, I'm afraid it would be neither accurate nor safe, specially because I can't power the arduino with the pcb so that they have a common power source, and so I'm stuck with the option of powering it usign the usb port of my pc(also I'm printing things to the serial monitor).
I wanted to ask how valid my concerns are and what solutions I have.
 

MrChips

Joined Oct 2, 2009
34,628
Welcome to AAC!

What you mean to say is that the PSU (power supply unit) is a transformerless PSU and it is connected to AC mains via a series capacitor.

It is a bad idea to experiment with electronics using a transformerless PSU. At some point, you will need to connect devices that share a common ground with earth ground. Get a proper PSU that is designed using a step-down transformer and with isolation from AC LINE voltages.
 

Thread Starter

yxrip

Joined Oct 31, 2025
13
Welcome to AAC!

What you mean to say is that the PSU (power supply unit) is a transformerless PSU and it is connected to AC mains via a series capacitor.

It is a bad idea to experiment with electronics using a transformerless PSU. At some point, you will need to connect devices that share a common ground with earth ground. Get a proper PSU that is designed using a step-down transformer and with isolation from AC LINE voltages.
Thank you!
The tranfsormerless part is correct, but I think I wasn't completely clear: what i mean is the section of an electronic device's pcb which turns ac into dc for the rest of it.
I want to do some experimenting/hacking on this pcb using an arduino, and because it's not safe as you said, i was wondering if there's a way to do it for example by adding/soldering something to the pcb or powering it or powering the arduino a certain way etc.
 

MrChips

Joined Oct 2, 2009
34,628
If you are a maker, the best way to learn is by doing and making things yourself.

I would suggest that you make and experiment with the following circuits:

1) AC to DC unregulated power supply

1761998474532.png

2) Regulated DC power supply

1761998561902.png

Reference: https://www.eleccircuit.com/power-supply-circuit/

3) Visit a second hand store and buy unregulated transformers for your Arduino and other projects. The Arduino has a voltage regulator on board. Hence you need unregulated DC about about 3 - 5 V higher than the MCU supply voltage.

Learn the difference between transformer and transformerless adapters.
Adapters with transformers are generally heavier than transformerless adapters.

1761999136536.png
 

Irving

Joined Jan 30, 2016
4,996
You are right to be concerned. Here is the circuit of a typical capacitve transformerless element (TLE) such as you describe. The '0v rail' from the bridge rectifier is actually potentially (no pun intended) several tens if not 100s of volts from AC_Neutral and the Protective Earth (PE). Connecting the ground of a typical USB port, or test equipment such as an oscilloscope - both of which are usually connected to PE - to that can result in significant damage (been there, done that - you only do it once!). This type of supply is usually less than a couple of watts. If you can measure the voltage across A & B, then one option is to replace that with an isolated DC power supply of similar voltage, either home-made as described above, or purchased.

1762019161036.png

However, if its more than a couple of watts, it may not be a purely passive supply - it could be a non-isolated SMPS like this one from another thread. Because the output from the bridge is now a full rectified mains - 325v from a 230v supply - replacing it as above isn't an easy option.




If it is not possible to power the TLE from an alternate supply then you have only one option - Use a mains isolation transformer. The diagram below shows the same TLE supplied from the 1:1 isolation transformer which allows its secondary to float, thus allowing the the -ve rail from the bridge to become a safe ground referenced back to the mains earth.

1762018726157.png
 
Last edited:

Thread Starter

yxrip

Joined Oct 31, 2025
13
You are right to be concerned. Here is the circuit of a typical capacitve transformerless element (TLE) such as you describe. The '0v rail' from the bridge rectifier is actually potentially (no pun intended) several tens if not 100s of volts from AC_Neutral and the Protective Earth (PE). Connecting the ground of a typical USB port, or test equipment such as an oscilloscope - both of which are usually connected to PE - to that can result in significant damage (been there, done that - you only do it once!). This type of supply is usually less than a couple of watts. If you can measure the voltage across A & B, then one option is to replace that with an isolated DC power supply of similar voltage, either home-made as described above, or purchased.

View attachment 358098

However, if its more than a couple of watts, it may not be a purely passive supply - it could be a non-isolated SMPS like this one from another thread. Because the output from the bridge is now a full rectified mains - 325v from a 230v supply - replacing it as above isn't an easy option.




If it is not possible to power the TLE from an alternate supply then you have only one option - Use a mains isolation transformer. The diagram below shows the same TLE supplied from the 1:1 isolation transformer which allows its secondary to float, thus allowing the the -ve rail from the bridge to become a safe ground referenced back to the mains earth.

View attachment 358095
Thank you very much!
Your reply is very to the point and also stated simply enough for me to understand a lot of it. So what I understand is that with an isolation transformer I create the same potential difference in the circuit as it expects i.e. mains but not giving it the full current, hence power, because... there are less electrons in the circuit than there is in the wall outlet(?) or something like that.
 

MrChips

Joined Oct 2, 2009
34,628
Forget about discussing "electrons in the circuit". This will lead you astray.

What you want is isolation from AC mains. That is what a transformer will provide, besides reducing the AC mains voltage to a safer voltage.
 

wayneh

Joined Sep 9, 2010
18,087
I wanna measure different timings on,...
I'm a little confused: Do you have an oscilloscope? I don't think you'll have much to measure time-wise without one. What are you hoping to do?
...but with a vague understanding I gathered from the internet, I'm afraid it would be neither accurate nor safe...
It is possible to safely and accurately measure things on a live circuit. But safe practices must be learned. It's not uncommon to learn the hard way, by releasing the magic smoke or an unpleasant contact with Ol' Sparky. Learning from the hard experiences of others is a highly recommended alternative. The hard lessons are not usually fatal but you certainly want to avoid them.
..., specially because I can't power the arduino with the pcb so that they have a common power source, and so I'm stuck with the option of powering it usign the usb port of my pc(also I'm printing things to the serial monitor).
I wanted to ask how valid my concerns are and what solutions I have.
You're hoping to use your Arduino instead of an oscilloscope? You are right to be concerned: You cannot connect the "grounds" of circuits with different PSUs unless at least one of them is floating. If they're both powered from the same ultimate source, for instance the wall power, there is the risk of current flowing from one to the other and damaging one or both PSUs. If your PC is a battery-powered laptop, that's floating and should be OK.
You can connect two supply grounds if you first ensure the lack of current flow. Start by measuring if there is an AC voltage present. If there's only a few volts, try connecting the grounds thru a resistor, eg. at least 1K. Measure for a voltage drop again. Repeat until you're sure that there is essentially zero current even with the grounds connected thru a low-value to zero ohm resistor. Obviously, it's easier to just not attach grounds unless one supply is isolated.
 

Irving

Joined Jan 30, 2016
4,996
Thank you very much!
Your reply is very to the point and also stated simply enough for me to understand a lot of it. So what I understand is that with an isolation transformer I create the same potential difference in the circuit as it expects i.e. mains but not giving it the full current, hence power, because... there are less electrons in the circuit than there is in the wall outlet(?) or something like that.
No, the isolation transformer is a 1:1 ratio..230v in gives 230v out, but what it does do is remove the relationship between the incoming mains Neutral line and the Protective Earth (PE) allowing you to create the relationship you must have between PE and the 0v output of the power supply.

Once you rectify AC mains directly the DC output is a few tens or hundreds of volts away from the Neutral line and also PE so cannot be connected to PE. But most test equipment, PCs, etc, are connected to PE and therein lies the danger...
 
Last edited:

Thread Starter

yxrip

Joined Oct 31, 2025
13
Forget about discussing "electrons in the circuit". This will lead you astray.

What you want is isolation from AC mains. That is what a transformer will provide, besides reducing the AC mains voltage to a safer voltage.
Thank you but I'm trying to understand why is that AV with the same voltage is dangerous without an isolation transformer but safe with it.
 

Thread Starter

yxrip

Joined Oct 31, 2025
13
I'm a little confused: Do you have an oscilloscope? I don't think you'll have much to measure time-wise without one. What are you hoping to do?
I don't have an oscilloscope and I'm trying to make a crude one with and arduino, not a general purpose oscilloscope though, but only for this pcb at hand.
No, the isolation transformer is a 1:1 ratio..230v in gives 230v out, but what it does do is remove the relationship between the incoming mains Neutral line and the Protective Earth (PE) allowing you to create the relationship you must have between PE and the 0v output of the power supply.

Once you rectify AC mains directly the DC output is a few tens or hundreds of volts away from the Neutral line and also PE so cannot be connected to PE. But most test equipment, PCs, etc, are connected to PE and therein lies the danger...
What would be the situation without a protective earth? I don't have that
 

Irving

Joined Jan 30, 2016
4,996
230v AC is always dangerous, but there are different sorts of danger.

Without the isolation transformer the DC output of the power supply is superimposed on an AC voltage but from the reference point of the internal '0v' rail its static... which is fine inside a sealed box but from the outside reference of the Arduino etc its still bouncing up and down.

With the isolation transformer we can tie the internal '0v' rail to the external 0v rail and its now static, but the isolation transformer output is now bouncing up and down - but as long as we don't touch it there's no danger.

There's always a PE - somewhere - where are you based?
 

Thread Starter

yxrip

Joined Oct 31, 2025
13
230v AC is always dangerous, but there are different sorts of danger.

Without the isolation transformer the DC output of the power supply is superimposed on an AC voltage but from the reference point of the internal '0v' rail its static... which is fine inside a sealed box but from the outside reference of the Arduino etc its still bouncing up and down.

With the isolation transformer we can tie the internal '0v' rail to the external 0v rail and its now static, but the isolation transformer output is now bouncing up and down - but as long as we don't touch it there's no danger.

There's always a PE - somewhere - where are you based?
I think I've got the answer I wanted but just for my understanding, is it correct to say that both rails of the dc section go up and down with mains but remain static in reference to each other? Is that what floating mean? and with a transformer for arduino, it also does the same thing as pcb?
I'm in Iran and electrical safety is not discovered yet in here
 

MrChips

Joined Oct 2, 2009
34,628
120 V or 240 V is dangerous to your health.

Every power supply must have a return path. The feed lines are called LINE (L) and NEUTRAL (N).
In old installations, there are only two lines. It is possible to reverse the connection by rotating the plug. Hence you don't know which is L and which is N.

In modern electricity installations, there is a third connection called Protective Earth (PE), ground, earth ground, or simply earth. This is a connection that is bonded to earth ground and serves as a protection in the event that there is a fault in the system. In normal usage, no current should be flowing in the PE.

Because you don't know how your power supply is connected to AC mains, you don't ever want your circuit to come into contact with L or N. Hence you need to provide galvanic isolation. Read about galvanic isolation.

If your power supply is connector to AC mains via a series capacitor, your entire circuit could be directly connected to 240 VAC.

Galvanic isolation is provided by a suitable power transformer. L and N are connected to the primary winding of the transformer. There must be no galvanic connection between the primary winding and the secondary winding. In other words it is isolated from AC mains.

Never connect the secondary side to L or N.

1762280086833.png

Floating means that your circuit has no galvanic connection to L, N, or PE.
In the drawing shown above, the secondary circuit is floating.

Any circuit powered by a battery with no connection to PE is floating.
Once you make a connection to PE, it is no longer floating.

1762280519378.png
 

Irving

Joined Jan 30, 2016
4,996
is it correct to say that both rails of the dc section go up and down with mains but remain static in reference to each other?
Exactly so.

Is that what floating mean?
Floating = no fixed external reference - so then you can define the reference - by convention that's usually the PE.

and with a transformer for arduino, it also does the same thing as pcb?
This is where things get tricky... you have to define a common reference that is known to be static and will stay static. In your situation, where, I guess, there is little control of adherence to standards, it becomes a minefield.
 
Top