AC Light dimmer with a micro - Page 1
Forum section: electronics / projects

author: roli
author_rank: Regular Contributor
timestamp: May 08, 2016, 08:12:21 pm
content: Hi!I am currently working on a personal project and I need some help and guidance from someone who actually knows what he is doing.Basically I need to build a compact light dimmer that will possibly fit into s standard light switch mounting hole. Basically my circuit will consist of a power supply, a micro and the light dimming part. I am fine when it comes to digital electronics, but I am kind of lost when it comes to everything else.I'll be using this linksiwtch power supply IC to power my circuit:https://ac-dc.power.com/products/linkswitch-family/linkswitch-tn/(yes, the circuit will be inaccessible to humans during it's operation)And an ARM SoC will be handling the rest. A 3.3V chip of course.Problem is the light dimming part. I'll need the thing to just switch (no dimming) a classic Fluorescent lamp (around 120W, 230V AC - European of course). But I want to reuse the same circuit to also dim a standard halogen light (around 40W).I know that this is commonly done with a triac. And googling has produced a lot of different circuits that do just that (something like this :http://www.inmojo.com/store/inmojo-market/item/digital-ac-dimmer-module-lite-v.2/). But I've seen some comments on other websites that this is a bad design and that it should not be used. Others that I've found are for 120V AC, ... Basically I am lost. Is that circuit ok, or is it not? Do you have anything better?I already have a circuit that I use just for switching the small halogen light (using a vo2223a power phototriac). And that was really simple to do, and works fine. But I really need a bigger power rating than just 44W (if I remember correctly that is how much a vo2223a can switch directly) and dimming would be a nice bonus.Thanks for any help!

author: madires
author_rank: Super Contributor
timestamp: May 08, 2016, 08:56:32 pm
content: The circuit is very basic and I'd recommend to add a snubber across the TRIAC, especially to deal with the ballast of a fluorescent lamp. I'd also add some input protection for the opto coupler for the zero crossing detection, something like a zener or TVS in parallel and optionally another series resistor. A MOV and X-class filter cap for the AC input might be also a good idea.

author: danadak
author_rank: Super Contributor
timestamp: May 09, 2016, 12:23:24 am
content: Are you dimming florescent by V or I control ?http://donklipstein.com/f-dim.htmlRegards, Dana.

author: roli
author_rank: Regular Contributor
timestamp: May 09, 2016, 03:54:28 pm
content: Quote from: danadak on May 09, 2016, 12:23:24 amAs I said - I don't actually plan on dimming the fluorescent lights. Only simple halogen lights.Quote from: madires on May 08, 2016, 08:56:32 pmOk. Snubber shouldn't be too much of a problem. I already have one in my current old design (RC network of 0.1UF, 120R) - would that one be ok?But I am not entirely sure for the rest. Why a zener in parallel? And I really don't know what a TVS even is, let alone how to use it.

author: TJ232
author_rank: Frequent Contributor
timestamp: June 09, 2016, 06:52:51 am
content: Take a look also to this one:https://www.eevblog.com/forum/microcontrollers/esp8266-ac-mains-wifi-dimmer-solution/It's a Voltage controlled AC MAINS dimmer and can be connected with Arduino/ESP8266/STM32/whatever MCU you want as long as you are able to provide a Voltage control between 0-2.8V (PWM, DAC, etc). Even with a simple potentiometer can be used without any kind of external MCU control.