Triac control of AC lamp

Thread Starter


Joined Dec 6, 2015
Hi all i am a pure newbe to Triacs, i want to make a lamp dimmer, switch using arduino.

but first of all i am testing the parts saperately, i made the following schematic in Proteus,

but as you can see the lamp is automatically glowing even if nothing is connected at input (1, 2) of MOC3021 ----- it is strange ?

and there are no errors

if it automatically glow how can i plan to control it by a pulse etc at input of MOC3021?

pls tell me where i am wrong so that i can do successful simulation and then order the components and make the hardware

thanks in advance


Joined Jun 26, 2012
Try a resistor 33K-68Kfrom the gate of the triac to the lower main terminal (the one not connected to the lamp).
Also, you might need a small capacitor in parallel with that resistor.


Joined Jun 22, 2012
You need to use a zero crossing opto like moc3041, or Il410, also you need to detect the zero crossing for your micro, to sync the pulses.