Author Topic: Grounding of non-isolated power supply  (Read 1645 times)

0 Members and 3 Guests are viewing this topic.

Offline x4ceTopic starter

  • Contributor
  • Posts: 32
  • Country: pk
Grounding of non-isolated power supply
« on: August 01, 2024, 06:22:37 pm »
Hello,

I have created a following non-isolated power supply circuit. I am very well aware that it could be dangerous. This is the first time I am trying to build a non-isolated supply and wanted to ask about grounding. The grounding shown is correct? Can we isolate it using capacitors?



Thanks
« Last Edit: August 02, 2024, 04:26:39 am by x4ce »
 

Offline Andy Chee

  • Frequent Contributor
  • **
  • Posts: 922
  • Country: au
Re: Grounding of non-isolated power supply
« Reply #1 on: August 01, 2024, 06:30:26 pm »
This non-isolated design cannot be connected to ground.  Ground must remain unconnected.

If you require grounding, then use an isolated design.
 
The following users thanked this post: SeanB, x4ce

Offline PGPG

  • Regular Contributor
  • *
  • Posts: 123
  • Country: pl
Re: Grounding of non-isolated power supply
« Reply #2 on: August 01, 2024, 11:08:26 pm »
wanted to ask about grounding. The grounding shown is correct?

What do you understand as 'grounding'?
1. Connecting to protective grounding of your AC supply?
2. Point to which '-' of something being supplied by your supply should be connected?

If 1. - don't do that!
If 2. - yes it is the right point/net to get '-' of your supply. But have in mind that this point even it can be the 'ground' to some circuit it is not save ground. It should not be touched by you.

And why you used +5V power symbol while you used 3.3V IC?
 
The following users thanked this post: x4ce

Offline x4ceTopic starter

  • Contributor
  • Posts: 32
  • Country: pk
Re: Grounding of non-isolated power supply
« Reply #3 on: August 02, 2024, 04:34:50 am »
Thanks for your response.

Thanks for pointing out the power symbol and I have updated my schematic, accordingly.

Yes, by grounding, I meant connecting negative(-) of the DC supply. So, the neg(-) of DC will be connected with AC neutral and touching may be very risky. In such a design, is it suggested to use a ground plane in PCB as it will cover the whole PCB and more risk associated with it?

Should I also put AGND on AC input side before bridge? I have used only on the rectified side.

Secondly, I have a Zener diode of 5.1V/1W rating and using 3V3 LDO, there might be a loss but as it is powered through mains then no big deal? Should I replace it with 3.9V/1W one?

Thanks
« Last Edit: August 02, 2024, 04:36:28 am by x4ce »
 

Offline Andy Chee

  • Frequent Contributor
  • **
  • Posts: 922
  • Country: au
Re: Grounding of non-isolated power supply
« Reply #4 on: August 02, 2024, 06:05:30 am »
Should I also put AGND on AC input side before bridge? I have used only on the rectified side.

Definitely NO!

This design must only use reference GND on the rectified side.

Remember, this is reference GND, not safety GND.  If you want something safe, then the entire design must be changed.

Wat is the purpose of your power supply?  Are you powering a light dimmer?  Motor controller?  Or medical device?  Touch sensor?
« Last Edit: August 02, 2024, 06:07:10 am by Andy Chee »
 
The following users thanked this post: x4ce

Offline Phil1977

  • Frequent Contributor
  • **
  • Posts: 537
  • Country: de
Re: Grounding of non-isolated power supply
« Reply #5 on: August 02, 2024, 06:23:49 am »
Are $1.34 minus the capacitor dropper components really worth the following risks:

- Electric shock while testing
- Electric shock due to insulation failure
- Circuit destruction due to accidental / wrong grounding
- Circuit destruction due to power surges or stupid phase correlation of switching off/switching on

Yes there are some applications for capacitive droppers, but is yours one of them?

https://hlktech.net/index.php?id=product&cate=cate703

PS: I personally started replacing capacitive droppers with these modules as soon as I see one with a blown fuse or fuse resistor. Up to now this always was a final solution, I have never had a failure with these micro-SMPS so far.
« Last Edit: August 02, 2024, 06:30:06 am by Phil1977 »
 
The following users thanked this post: tooki

Offline Andy Chee

  • Frequent Contributor
  • **
  • Posts: 922
  • Country: au
Re: Grounding of non-isolated power supply
« Reply #6 on: August 02, 2024, 07:57:05 am »
 

Offline Phil1977

  • Frequent Contributor
  • **
  • Posts: 537
  • Country: de
Re: Grounding of non-isolated power supply
« Reply #7 on: August 02, 2024, 08:09:48 am »
But these notoriously unsafe modules are also notoriously unreliable.

The low-power potted modules are even cheaper, safer and more reliable. They just don't have much power.

PS: I miss a fuse in the OP´s design.
 

Offline PGPG

  • Regular Contributor
  • *
  • Posts: 123
  • Country: pl
Re: Grounding of non-isolated power supply
« Reply #8 on: August 02, 2024, 12:34:11 pm »
So, the neg(-) of DC will be connected with AC neutral and touching may be very risky.

I don't understand your reasoning.
Where from the conclusion that (-) of DC will be connected with AC neutral?

If it were connected with neutral touching it would be not so risky. But it is not connected with neutral.

Seeing your reasoning, and those simple mistake with 3V3 and 5V I think that even you declared that you are "very well aware that it could be dangerous" you should not do this project.
 

Offline wasedadoc

  • Super Contributor
  • ***
  • Posts: 1589
  • Country: gb
Re: Grounding of non-isolated power supply
« Reply #9 on: August 02, 2024, 02:14:54 pm »
The 100 Ohms and 2.2uF are only about 1.5k at 50Hz. 220 volt rms ac input lets -200mA peak through the bridge rectifier to the point you ask about connecting to ground. Gasp!
 

Online wraper

  • Supporter
  • ****
  • Posts: 17515
  • Country: lv
Re: Grounding of non-isolated power supply
« Reply #10 on: August 02, 2024, 02:22:07 pm »
Ground != Earth. In many cases they're connected together but ground is not the same as Protective Earth (PE). Ground basically is just a common reference point in the circuit, usually a negative power rail or in the middle of split power rails. So there is nothing wrong with OP's circuit per se, as long as everything is well isolated from the outside (it must not be connected to PE other than through Y class safety capacitors).
« Last Edit: August 02, 2024, 03:39:43 pm by wraper »
 
The following users thanked this post: x4ce

Offline x4ceTopic starter

  • Contributor
  • Posts: 32
  • Country: pk
Re: Grounding of non-isolated power supply
« Reply #11 on: August 02, 2024, 05:36:15 pm »
So, the neg(-) of DC will be connected with AC neutral and touching may be very risky.

I don't understand your reasoning.
Where from the conclusion that (-) of DC will be connected with AC neutral?

If it were connected with neutral touching it would be not so risky. But it is not connected with neutral.

Seeing your reasoning, and those simple mistake with 3V3 and 5V I think that even you declared that you are "very well aware that it could be dangerous" you should not do this project.

Thanks for your honest suggestion.

From that I meant that AC phase & neutral will be passing through bridge to rectified side and there might still be high voltage or risk associated?
 

Offline x4ceTopic starter

  • Contributor
  • Posts: 32
  • Country: pk
Re: Grounding of non-isolated power supply
« Reply #12 on: August 02, 2024, 05:39:39 pm »
Should I also put AGND on AC input side before bridge? I have used only on the rectified side.

Definitely NO!

This design must only use reference GND on the rectified side.

Remember, this is reference GND, not safety GND.  If you want something safe, then the entire design must be changed.

Wat is the purpose of your power supply?  Are you powering a light dimmer?  Motor controller?  Or medical device?  Touch sensor?

Thanks!

I want to make a low-cost, AC powered solution for powering microcontroller.
 

Offline x4ceTopic starter

  • Contributor
  • Posts: 32
  • Country: pk
Re: Grounding of non-isolated power supply
« Reply #13 on: August 02, 2024, 05:41:12 pm »
But these notoriously unsafe modules are also notoriously unreliable.

The low-power potted modules are even cheaper, safer and more reliable. They just don't have much power.

PS: I miss a fuse in the OP´s design.


I have used these modules in one of my projects but I had 35V in my neg(-) rail and that might be due to induction through PCB. Besides, you need to have protection with it as well.
 

Offline x4ceTopic starter

  • Contributor
  • Posts: 32
  • Country: pk
Re: Grounding of non-isolated power supply
« Reply #14 on: August 02, 2024, 05:42:26 pm »
Ground != Earth. In many cases they're connected together but ground is not the same as Protective Earth (PE). Ground basically is just a common reference point in the circuit, usually a negative power rail or in the middle of split power rails. So there is nothing wrong with OP's circuit per se, as long as everything is well isolated from the outside (it must not be connected to PE other than through Y class safety capacitors).

Thanks for your response.

Is there any further suggestion in its improvement.

Thanks
 

Offline Andy Chee

  • Frequent Contributor
  • **
  • Posts: 922
  • Country: au
Re: Grounding of non-isolated power supply
« Reply #15 on: August 02, 2024, 05:56:51 pm »
Should I also put AGND on AC input side before bridge? I have used only on the rectified side.

Definitely NO!

This design must only use reference GND on the rectified side.

Remember, this is reference GND, not safety GND.  If you want something safe, then the entire design must be changed.

Wat is the purpose of your power supply?  Are you powering a light dimmer?  Motor controller?  Or medical device?  Touch sensor?

Thanks!

I want to make a low-cost, AC powered solution for powering microcontroller.

Yes, but what does the microcontroller do?  Is the microcontroller connected to sensors?  What kind of sensors?  Is the microcontroller connected to MOSFET for motor PWM?  or light/LED dimming phase control triac?

This extra information is important to making your project a success.
 
The following users thanked this post: wraper, x4ce

Online wraper

  • Supporter
  • ****
  • Posts: 17515
  • Country: lv
Re: Grounding of non-isolated power supply
« Reply #16 on: August 02, 2024, 07:58:08 pm »
Ground != Earth. In many cases they're connected together but ground is not the same as Protective Earth (PE). Ground basically is just a common reference point in the circuit, usually a negative power rail or in the middle of split power rails. So there is nothing wrong with OP's circuit per se, as long as everything is well isolated from the outside (it must not be connected to PE other than through Y class safety capacitors).

Thanks for your response.

Is there any further suggestion in its improvement.

Thanks
With this circuit in isolation it does not even matter what you consider as ground. Often it's just something arbitrary just to draw schematics with GND symbols instead of long lines across all the circuit. Also it's used for simulation as you define it as a reference point for all voltages.
For particular circuit I can give some suggestions not related to GND. Either: a) add a fuse, or B) throw out R3 and use fusible resistor with adequate voltage rating for R1 (TVS is not needed for this circuit and likely will cause more reliability problems than it solves). R1 also should be sufficiently powerful to survive inrush current when powered on. R2 must be rated for at least 350V peak voltage, regular 1/4W resistors are not suitable. Must be higher power or high voltage series. C1 should be a usual film capacitor rated for at least 630VDC or X2/X1 safety capacitor. For Input connector I suggest using 3 pin version and leave middle contact unconnected to have more distance.
« Last Edit: August 02, 2024, 10:14:03 pm by wraper »
 
The following users thanked this post: x4ce

Offline x4ceTopic starter

  • Contributor
  • Posts: 32
  • Country: pk
Re: Grounding of non-isolated power supply
« Reply #17 on: August 03, 2024, 04:31:52 am »
Should I also put AGND on AC input side before bridge? I have used only on the rectified side.

Definitely NO!

This design must only use reference GND on the rectified side.

Remember, this is reference GND, not safety GND.  If you want something safe, then the entire design must be changed.

Wat is the purpose of your power supply?  Are you powering a light dimmer?  Motor controller?  Or medical device?  Touch sensor?

Thanks!

I want to make a low-cost, AC powered solution for powering microcontroller.

Yes, but what does the microcontroller do?  Is the microcontroller connected to sensors?  What kind of sensors?  Is the microcontroller connected to MOSFET for motor PWM?  or light/LED dimming phase control triac?

This extra information is important to making your project a success.

Definitely not going to control 220VAC using TRIAC.

Just to measure AC voltage and current, operating Relay, or opto-coupler to detect AC voltage etc.
 

Offline x4ceTopic starter

  • Contributor
  • Posts: 32
  • Country: pk
Re: Grounding of non-isolated power supply
« Reply #18 on: August 03, 2024, 04:32:42 am »
Ground != Earth. In many cases they're connected together but ground is not the same as Protective Earth (PE). Ground basically is just a common reference point in the circuit, usually a negative power rail or in the middle of split power rails. So there is nothing wrong with OP's circuit per se, as long as everything is well isolated from the outside (it must not be connected to PE other than through Y class safety capacitors).

Thanks for your response.

Is there any further suggestion in its improvement.

Thanks
With this circuit in isolation it does not even matter what you consider as ground. Often it's just something arbitrary just to draw schematics with GND symbols instead of long lines across all the circuit. Also it's used for simulation as you define it as a reference point for all voltages.
For particular circuit I can give some suggestions not related to GND. Either: a) add a fuse, or B) throw out R3 and use fusible resistor with adequate voltage rating for R1 (TVS is not needed for this circuit and likely will cause more reliability problems than it solves). R1 also should be sufficiently powerful to survive inrush current when powered on. R2 must be rated for at least 350V peak voltage, regular 1/4W resistors are not suitable. Must be higher power or high voltage series. C1 should be a usual film capacitor rated for at least 630VDC or X2/X1 safety capacitor. For Input connector I suggest using 3 pin version and leave middle contact unconnected to have more distance.

Thanks, I will consider putting these into my schematic/ design.
 

Offline Andy Chee

  • Frequent Contributor
  • **
  • Posts: 922
  • Country: au
Re: Grounding of non-isolated power supply
« Reply #19 on: August 03, 2024, 06:07:00 am »
Should I also put AGND on AC input side before bridge? I have used only on the rectified side.

Definitely NO!

This design must only use reference GND on the rectified side.

Remember, this is reference GND, not safety GND.  If you want something safe, then the entire design must be changed.

Wat is the purpose of your power supply?  Are you powering a light dimmer?  Motor controller?  Or medical device?  Touch sensor?

Thanks!

I want to make a low-cost, AC powered solution for powering microcontroller.

Yes, but what does the microcontroller do?  Is the microcontroller connected to sensors?  What kind of sensors?  Is the microcontroller connected to MOSFET for motor PWM?  or light/LED dimming phase control triac?

This extra information is important to making your project a success.

Definitely not going to control 220VAC using TRIAC.

Just to measure AC voltage and current, operating Relay, or opto-coupler to detect AC voltage etc.
Ok!   Now this is interesting!

If you are going to measure the AC voltage of the same source that is powering your microcontroller, then you will have to be very particular about your reference GND and circuit design.

This would be much easier with an isolated/floating power supply for the microcontroller.
 
The following users thanked this post: x4ce

Offline ledtester

  • Super Contributor
  • ***
  • Posts: 3202
  • Country: us
Re: Grounding of non-isolated power supply
« Reply #20 on: August 03, 2024, 06:16:27 am »
Just to measure AC voltage and current, operating Relay, or opto-coupler to detect AC voltage etc.

Have a look at Atmel App Note 465 for design considerations and calculations:

https://ww1.microchip.com/downloads/en/AppNotes/Atmel-2566-Single-Phase-Power-Energy-Meter-with-Tamper-Detection_Ap-Notes_AVR465.pdf

To get signals/data out of the microcontroller you'll have to some sort of isolated data channel.

Note that you can get power meter modules with a rs485 interface from Aliexpress.

And to just detect/measure AC current you can use a current transformer and you wouldn't have to use your non-isolated power supply.
 
The following users thanked this post: x4ce

Offline Andy Chee

  • Frequent Contributor
  • **
  • Posts: 922
  • Country: au
Re: Grounding of non-isolated power supply
« Reply #21 on: August 03, 2024, 06:29:37 am »
Just to measure AC voltage and current, operating Relay, or opto-coupler to detect AC voltage etc.

Have a look at Atmel App Note 465 for design considerations and calculations:


In particular note that the Atmel app note uses a half wave rectifier, which allows the Neutral to act as reference GND.  This is not possible with your bridge rectifier design, meaning a simple resistor voltage divider to measure AC voltage is also not possible with your bridge rectifier design.
 
The following users thanked this post: x4ce

Offline Xena E

  • Frequent Contributor
  • **
  • Posts: 327
  • Country: gb
Re: Grounding of non-isolated power supply
« Reply #22 on: August 03, 2024, 08:44:37 am »

Thanks, I will consider putting these into my schematic/ design.

This was a worrying comment. I translated it as: "FU___I'm doing this anyway." (From someone with very little idea what they're doing.)

Non isolated (particularly full wave rectified) power supplies, are the reason that many careless people are now taking a dirt nap.

If you want to do this yourself, FFS just buy a transformer, then you can ground the crap out of your do-dad.

Stay safe...
 
The following users thanked this post: x4ce

Offline MrAl

  • Super Contributor
  • ***
  • Posts: 1553
Re: Grounding of non-isolated power supply
« Reply #23 on: August 03, 2024, 09:20:48 am »
Hello,

I have created a following non-isolated power supply circuit. I am very well aware that it could be dangerous. This is the first time I am trying to build a non-isolated supply and wanted to ask about grounding. The grounding shown is correct? Can we isolate it using capacitors?



Thanks

Hello there,

If you look at your schematic, if you connect AGND to pin 2 of your input connector (pin 2 being the neutral) you can see you will short out the lower diode in the full wave bridge rectifier.  That looks like it will render that part of the circuit as a voltage doubler which is half wave.

However, if you put two capacitors in series with the input, one cap for each lead, it will be a full wave rectifier again and work as you intended.  This will not be galvanically isolated though so it will not be much safer, but it will allow the circuit to work for powering devices that do not have to be isolated from the line like a small relay or similar.
The cost of those two caps may be a little more than you want to pay though you'd have to check.  They would have to be at least equal to the other cap there which is 2.2uf, and have a high enough voltage rating to handle the peak of the 230vac RMS input voltage.

In these cases it is usually better to just buy a wall wart that has the required output.  They are much cheaper these days and already built and already have galvanic isolation too.
The only time you would not want to do this is in a large production run where you have to create thousands or even millions of these power supplies and it has to be kept very small.  There you want to cut costs to the minimum and have the circuit be as small as possible.  That's as long as it does not require real galvanic isolation.


 
The following users thanked this post: x4ce

Offline SteveThackery

  • Frequent Contributor
  • **
  • Posts: 384
  • Country: gb
Re: Grounding of non-isolated power supply
« Reply #24 on: August 03, 2024, 11:07:32 am »
@x4ce: I'm a bit like you - my experience and knowledge places me firmly in the "novice" category. I can totally relate to where you are coming from with your original post.

However, please let me beg you: the electrical mains supply (whether 110V or 220-240V) is extremely dangerous stuff and, as a novice, it is just too easy to make a simple mistake which has the potential to kill someone. And it's not just your life at risk - it might be someone you love, or a complete stranger. Even if someone just gets a painful shock, how will your conscience feel?

Yes, a person who knows what they are doing can design and build their own power supply. But even if you are just building a capacitive dropper, you need a thorough understanding of the standards and ratings each component must meet. You need to understand about double insulation, about component spacing and track clearances, about the correct material for the PCB, about the choice of connectors, and so on.  This is definitely non-trivial, even when the circuit looks simple on paper.

Plug-top PSUs are everywhere and cheap. So are those encapsulated modules referred to earlier. Having been a hobbyist (and permanent novice) for 50 years, I wouldn't dream of making my own mains-powered PSU. As well as being potentially dangerous, it's just not worth the considerable effort when you can buy a suitable unit for a few bucks (or pounds, in my case).

Please, abandon your current course, buy a PSU module from a source you trust, and then move on to the more interesting part of your project (whatever it is, you haven't given us details).
 
The following users thanked this post: x4ce


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf