PIC Based Auto Dimmer circuit schematic with explanation


The operation of the dimmer is based on phase control; during a full cycle of an AC waveform, a thyristor will only allow a part of the waveform to be delivered to the load. Take a look at the following waveforms:

PIC Based Auto Dimmer  circuit schematic with explanation PIC Based Auto Dimmer  circuit schematic with explanation

The only difference is that the waveform on the left will bright the lamp higher than the waveform on the right. That is because, on the left waveform, the triac will be conductive earlier than the triac shown in the right waveform.

The time that the triac becomes conductive is symbolized with the Greek letter α (ALPHA) , called firing angle, so controlling this angle you can control the phase voltage, and is measured in angles from the zero point of the waveform. This zero point is the point that the voltage is 0 volts, and this happens 2 times every one full period of the wave form. When the α becomes smaller, then the dimmer becomes conductive sooner and the lamp is brighter. When the α becomes bigger, then the triac delays more to become conductive and thus the lamb is dimmer.


A full wavelength period is 360 degrees (2π). Due to the fact that during a full wave length the zero cross occurs twice, α can take values from 0° to 180 degrees (0 - π). When α = 0°, the full power is delivered to the load and when α = π, no power is delivered to the load.

The zero cross detection circuit is the most critical part when designing a dimmer. This circuit will watch the input power waveform and detect when this waveform crosses the 0 point and becomes 0 volts.


Zero cross detection circuits are mainly used in cases when the dimmers needs to be controlled from a micro controller. In that case, the micro-controller needs to know the zero cross detection point of the waveform, so that it can calculate the angle offset to send the trigger pulse to the gate of the triac.

In this case i am using three second delay for auto changing the brightness and interrupt for zero crossing. The range required for my test is 10% to 90% means 22v to 198v for 220v ac.
Also note me using 4Mhz crystal with 22pF capacitors.

Video:


Download: Code n Files

Schematic:
PIC Based Auto Dimmer  circuit schematic with explanation
MCU Based Auto Dimmer
Components Required:
R1-R3, R6-------------------------10k ohm
R7-R8-----------------------------1k ohm
C1----------------------------------10nF Ceramic
Q1----------------------------------BC547
Q2----------------------------------BC557
U1----------------------------------PIC16F628A
U2----------------------------------BT136 Triac
Bridge Rectifier
4MHz Crystal
22pF Ceramic (2)


EmoticonEmoticon

Advertisement