I need some advice to my summer project, I would like to get max 150mA from 220V. After some research I build up the following circuit:

enter code here

In the A and B point I would like to connect a bulb and control the power on the light this is why I'm using the X2 TRIAC. In the C-D point I would like to connect a Li-Ion battery charger(MCP73871-Microchip), because I also need a battery to provide the necessary power when the X2 is off. To regulate the voltage I also would like to connect a buck regulator(MCP1603) on the output of the MCP73871 to have a constant voltage. After this I will connect a microcontroller to control the power on the bulb. The control circuit need max 40mA of current(microcontroller+buck regulator+charger+sensors).

My question are:

  • Am I in a good way?
  • Is this concept good, where can I improve this circuit/idea and how?
  • How can I calculate the maximum and minimum current in the C line?
  • If I would have a 200mAh battery than a 100mA charging current would be sufficient? What is the minimum charging current for 100mA
  • \$\begingroup\$ i've noticed that triac is in series with R4//C3 - what kind of lightbulb are you going to use? Are you aware that in this place voltage will not be 220V? \$\endgroup\$
    – miceuz
    Jun 14, 2012 at 21:09
  • \$\begingroup\$ Yes I know that, I will have ca. 214.9V, As Far as I know I can power up a bulb wit this voltage. \$\endgroup\$
    – Mokus
    Jun 15, 2012 at 8:33

3 Answers 3


Here is a microchip AN that I think is almost exactly what you need (also you need zero crossing detection which I didn't see mentioned...that is in here too)



From schematics i can see that zener diode needs a current limiting resistor.

Microchip has a great datasheet AN954 about resistive/capacitive power supplies - you can find all the formulae for max current calculations there.

In general, I wouldn't play with unisolated power sources. At least, when you will be debugging this circuit, always keep one hand in your pocket, this way you might get shocked but hopefully not fatally.


First of all, I don't see transformer anywhere! Basically it means that between C and D you will get huge DC voltage which will practically burn anything you connect.

Also I would suggest that you put light bulb in parallel to the AC voltage source in order to avoid decreasing output power of your device!

If you want to make all other calculations (output voltage, power etc.) you need to include transformer in your scheme...


  • 2
    \$\begingroup\$ note C3 and R4 - it will drop the voltage \$\endgroup\$
    – miceuz
    Jun 14, 2012 at 20:54
  • 1
    \$\begingroup\$ He's specifically designing a transformerless power supply. And no, you won't get a huge voltage between C and D, as C3 limits the power available, and D12 will clamp the output voltage to something reasonable. \$\endgroup\$ Jun 14, 2012 at 21:00
  • 2
    \$\begingroup\$ Admittedly, this kind of supply can be dangerous, as it provides no electrical isolation. However, it does work. \$\endgroup\$ Jun 14, 2012 at 21:01
  • \$\begingroup\$ I really don't see why anyone would want to create this kind of power supply? It is like using CRT instead of transistors... :S \$\endgroup\$
    – Amon
    Jun 14, 2012 at 21:02
  • 1
    \$\begingroup\$ @Amon because transformers are large, expensive and heavy and people don't realise how dangerous mains power is even with a series resistor/capacitor/light bulb. Also the danger is often with the people that don't expect it, like children or partners. \$\endgroup\$
    – jippie
    Jun 14, 2012 at 21:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.