Home     Contact     Projects     Experiments     Circuits     Theory     BLOG     PIC Tutorials     Time for Science     RSS     Terms of services     Privacy policy  
   
 Home      Projects     Experiments     Circuits     Theory     BLOG     PIC Tutorials     Time for Science   

24 April 2010
Author: Giorgos Lazaridis
PIC DCV Controlled AC Light Dimmer

IMPORTANT
DANGER OF ELECTRIC SHOCK!
Read this before taking any further action!!!
Precautions to avoid electric shock


The circuit mounted on a breadboard for test-run

Safety First: The high voltage circuitry is covered with a plastic transparent cup.

Actually, i plan to make a 4-channel DC controlled lamp dimmer. Unfortunately, looking in my stock cabinet, i found out that i had run out of 16F690... Yet, i had to make the programming ASAP! Thus, i made a single channel PIC with the 12F615. I will use the same routine for the 4-channel dimmer, when the courier arrives.

If you do not know how the AC Dimmer works, try this link:

How Dimmer works

You may also want to know more about TRIACs:

How TRIACs work

If you want to see another dimmer without a microcontroller (only with a 555), visit this link:

Voltage Controlled AC Light Dimmer

The circuit in operation



The Circuit

This dimmer, like the 555 dimmer that i made some weeks ago, will be controlled with a DC voltage level. The original design will be controlled with 0 to 5 volts, but using a voltage divider, you can increase this number as much as you like. I use a potentiometer to adjust the control DC voltage, you can use whichever DC voltage source. You may use for example a photocell and a resistor to make an ambient light equalizer...

Here is the schematic diagram:





The transformer is used to provide both power to the circuit and to get the zero cross detection pulse. The 7805 is used to fix the supply to 5 Volts. There are 2 potentiometers connected in series. The first one (R7), is used to set the minimum luminosity (that needs the maximum trigger delay). The R3 is used to control the dimmer! This is actually the control potentiometer.

I hate messing high and low voltages. SAFETY FIRST! That's why i use the transformer for the zero cross detection (and not just some 4 MOhm resistors), and that's why i use the optocoupler. I use the MOC3021, for Greece has 220V mains. For 110/120 volts you may consider using the MOC3011. Check out the datasheet of the MOC series (find it in the Bill Of Materials section at the end of this article).

I use the BT136D TRIAC to control the lamp. It can handle up to 4 Amperes load. Translated into wattage for 220 Volts lamp, this is up to 880 Watts lamp... It is enough for your household lamps, isn't it? If not, then use another TRIAC.




Adjusting the circuit

The adjustment of this circuit is very simple. First of all you need to connect the potentiometer R3 correctly, so that when is turned to the left, the lamp will fade. If you are sure that is connected correct, proceed to the next step.

Put the R7 in the middle. Turn the R3 completely to the left (OFF position). Then turn it a few degrees to the right, not too much, about 2 degrees. Using a insulated small screwdriver, turn the R7 slowly and steady, so that the lamp is turned off. When the lamp is off completely, the dimmer is adjusted! That's it.




The Firmware

Not much to say about the firmware. There are 2 parameters that you may need to change, if the frequency of your power supply is not 50Hz. The GLMinVal, sets the minimum trigger delay value - that is the maximum luminosity. This parameter defines the point above which the lamp will be 100% powered. The GLMaxVal on the other hand, controls the max trigger delay - that is the minimum lamp luminosity. This is the value below which the lamp is turned off completely. Change the values with caution if you are not 100% sure what you are doing.

Here is the full assembly listing for the firmware, to compile and upload:

 PIC Dimmer - Assembly listing

If you do not want to change anything and simply upload the firmware, here is the binary ready for upload:

 PIC Dimmer - Binary file



Bill Of Materials (Second circuit)
Resistors
R1Resistor 1 KOhm 1/4 Watt 5% Carbon Film 
R2Resistor 10 KOhm 1/4 Watt 5% Carbon Film 
R35 KOhm potentiometer
R4Resistor 4.7 KOhm 1/4 Watt 5% Carbon Film 
R5Resistor 470 KOhm 1/4 Watt 5% Carbon Film 
R6Resistor 10 KOhm 1/4 Watt 5% Carbon Film 
R72.2 KOhm potentiometer
R8-9Resistor 220 Ohm 1/4 Watt 5% Carbon Film 
Capacitors
C1100 pF ceramic capacitor
C21000 uF 16 Volts electrolytic capacitor
Integrated Circuits
IC17805 Positive Voltage Regulator 
IC2PIC12F615 Microcontroller 
OK1MOC3021 Random Phase Optoisolator TRIAC Driver Output 
Transistors - TRIACs
Q1BC548 Switching and Applications NPN Epitaxial Transistor 
T1BT136D Sensitive gate TRIAC 
Diodes
D11N4001 General Purpose Diode Rectifier 
B12W10M Single Phase 2 Amps Silicon Bridge Rectifier 







Relative pages
  • Learn how dimmers work
  • The SCR (Silicon Control Rectifiers) theory
  • The TRIAC theory
  • The voltage divider theory
  • How to make an Ambient Light Level Equalizer
  • How to make a light / dark activated switch - 3 different circuits under the microscope
  • Voltage controlled light dimmer circuit
  • Learning PICs @ PCB Heaven On-Line Book





  • Comments

      Name

      Email (shall not be published)

      Website

    Notify me of new posts via email


    Write your comments below:
    BEFORE you post a comment:You are welcome to comment for corrections and suggestions on this page. But if you have questions please use the forum instead to post it. Thank you.


          

  • At 7 March 2016, 12:32:35 user Debashis wrote:   [reply @ Debashis]
    • Can sumone pls tell me... Can i controle Inductive load with This Circuit....
      Thank u in advance


  • At 19 December 2015, 23:00:20 user Atam wrote:   [reply @ Atam]
    • Excuse Google translation.
      Excellent project, congratulations. I have done 12F675, it works OK.


  • At 13 May 2015, 12:21:42 user MVA wrote:   [reply @ MVA]
    • Nice work. Very nice information you shared. But I am not able to understand code as it is assembly. Can you please post code in C?


  • At 19 February 2015, 8:27:24 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Alex Houben The analog input cannot be PWM, it must be a smooth DC voltage. Also make sure that you have tune the circuit properly with the potentiometers


  • At 17 February 2015, 11:25:04 user Alex Houben wrote:   [reply @ Alex Houben]
    • Hi,

      I use your pic dimmer in combination with a velleman VM140 ( http://www.velleman.eu/products/view/?country=be&lang=en&id=369162 )
      The analog outputs are used a input for your dimmer. But when I dim the lights they blink approximately > 20% dim.

      I was wondering: This Analog out generates a PWM DC voltage; how does your dimmer handle this? Perhaps it is better with a capacitor?

      Alex


  • At 1 December 2014, 18:00:28 user taher wrote:   [reply @ taher]
    • Hi
      It's nice project. I want to make one on PIC. Can you show me the way how to load .Hex(binary) file to PIC12f615 micro controller using PIC2Kit? please reply ASAP


  • At 22 September 2014, 14:45:00 user nadmie wrote:   [reply @ nadmie]
    • Hello.do you build the mini project for ir remote control for dimmer that can adjust the brightness such as from 0% until 100% or From dim to bright. Please reply asap. Tq :)


  • At 31 August 2014, 6:36:43 user Giorgos wrote:   [reply @ Giorgos]
    • @Mat The PIC dimmer needs no setup, the 555 version needs to set up the period of the signal. Also the PIC dimmer can operate through all 0-100% brightness, the 555 cannot.


  • At 30 August 2014, 22:23:59 user Mat wrote:   [reply @ Mat]
    • Hi there

      Can you help me compare this circuit with the 555 version you wrote about?

      What is different between this and the 555 dimmer? I see you can set GLMinVal and GLMaxVal which is really good and I guess there is no equivalent in the other circuit?

      Basically I'm looking to make a 4 channel 5V DC controlled standalone dimmer which can be controlled by arduino from the analog outputs...

      Thanks!


  • At 25 January 2014, 8:26:54 user Mrunal Ahirrao wrote:   [reply @ Mrunal Ahirrao]
    • Sir,
      This circuit of zero crossing detector is not working.I have used same circuit.in this the transistor Q1 is always ON. So I am not getting Pulse output. Any help would be appreciated.


  • At 8 November 2013, 10:00:28 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Mrunal Ahirrao no its not suitable for inductive loads


  • At 3 November 2013, 6:01:13 user Mrunal Ahirrao wrote:   [reply @ Mrunal Ahirrao]
    • Sir,
      can we use this same circuit for table fan speed controller?


  • At 26 October 2013, 8:26:26 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Mrunal Ahirrao There are many ways to connect a TRIAC gate. This one is provided by the datasheet of the optocoupler.


  • At 25 October 2013, 3:11:44 user Mrunal Ahirrao wrote:   [reply @ Mrunal Ahirrao]
    • Sir,
      I have a simple question. I didn't got how you connected triac. you have connected the gate terminal directly with live. How? according to my knowledge gate terminal has to be connected to microcontroller using transistor to provide negative triggering to triac. Please explain.


  • At 15 September 2013, 8:28:56 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Miro it will work no matter what. don't worry.


  • At 14 September 2013, 18:49:26 user Miro wrote:   [reply @ Miro]
    • Hello. I have one simple question.
      When I'm connecting this dimmer to mains voltage should I always check in wall socket (where I want to plug dimmer) where is neutral and where is line and connect it as it's shown in schematic.

      What will happen if I reverse neutral and line?

      For example in my house sockets are mainly connected with line on the right side, but some of them are different. It'll be absurd if I have to check in every room where are line and neutral if I want to use this dimmer.
      I hope you understand what I mean.
      Cheers!


  • At 11 June 2013, 14:28:17 user Cheerio wrote:   [reply @ Cheerio]
    • @Giorgos Lazaridis thx i get it now.


  • At 11 June 2013, 6:56:55 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Cheerio Hello Cheerio! The point is that when the TRIAC is turned ON, it will not turn OFF until the voltage across A1 and A2 is 0. That being said, if you send a pulse to the gate at say 10 degrees and you turn this pulse off at 11 degrees, the TRIAC will continue to conduct until 180 degrees where the voltage becomes 0 again. In other words, sending PWM to a TRIAC will only keep the TRIA ON all the time.


  • At 7 June 2013, 15:43:45 user Cheerio wrote:   [reply @ Cheerio]
    • Hey kam!
      I am just wondering why you bother with ther zero cross detection. What about generating a pwm signal and use a dutycycle stepping of 10ms. the zerocrossing detection is done by the optocoupler and the dimming effect will average i guess.
      Can you give me your opinion on this? your zerocross detection is most likely not a coincidence.


  • At 15 April 2013, 20:26:59 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @ZHEN Lamp is at AC. L-N. Not DC


  • At 14 April 2013, 2:01:58 user ZHEN wrote:   [reply @ ZHEN]
    • just wondering this circuit .. i saw the lamp is connect to DC part ...and why called AC dimmer ..... and i want to know how to control to the AC lamp in high voltage site...may u reply me ...


  • At 29 January 2013, 7:06:52 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Bloody Nine i uploaded a new code with the mclre disabled. Try this one.


  • At 28 January 2013, 21:39:29 user Bloody Nine wrote:   [reply @ Bloody Nine]
    • @Giorgos Lazaridis Thanks for your reply. I have tested my optocoupler and triac and both seem to be working, but the problem persists. The incoming voltage is 240V, would I have to change the assembler code? I noticed your circuit runs of 220V. Thanks again.


  • At 27 January 2013, 15:57:55 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Bloody Nine test the optocoupler-triac connection if it is ok by giving manually power to the opto LED


  • At 26 January 2013, 16:46:05 user Bloody Nine wrote:   [reply @ Bloody Nine]
    • Hi George,

      I have built this circuit using and LDR instead of R7, and programmed my PIC in MPLAB. However, when I give the circuit power, the lap flicks on for an instant, and doesnt come back on. Any suggestions what that might be?

      Thanks in advance


  • At 25 November 2012, 19:10:19 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Jonquil i just replaced r7 with the ldr


  • At 25 November 2012, 18:16:14 user Jonquil wrote:   [reply @ Jonquil]
    • Hi,

      Can you show the circuit diagram of the LDR set up you used?

      Thanks


  • At 10 November 2012, 19:16:21 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Hrinkleson Actually almost any other triac (that fits your needs) will work. Choose one according to your power requirements. PIR sensor is a totally different case - it will not work here.


  • At 6 November 2012, 21:14:29 user Hrinkleson wrote:   [reply @ Hrinkleson]
    • Hi George. Can you suggest an alternative to the BT136D triac? I have replaced the potentiometers with light dependent resistor circuit to make it automatic dimming. If i wanted to add a PIR sensor circuit, where would that go?


  • At 20 October 2012, 15:58:07 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @joe 220/12


  • At 20 October 2012, 12:30:55 user joe wrote:   [reply @ joe]
    • Hi Giorgos,

      What transformer do you use?

      Joe


  • At 19 October 2012, 13:04:32 user Alex wrote:   [reply @ Alex]
    • @Giorgos Lazaridis
      Ok thanks I'll try this weekend and inform you.
      Alex


  • At 19 October 2012, 9:29:52 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Alex oh i thought it was the 555 circuit. Change the lines:
      movlw b'11111000'
      movwf option_reg
      To
      movlw b'10111000'
      movwf option_reg

      I hope that this will work since the interrupt will now occur at failing edge and not rising edge (the 6th bit of option register)


  • At 18 October 2012, 9:50:06 user Alex wrote:   [reply @ Alex]
    • @Giorgos Lazaridis
      I know that but this is about the PIC controller in this schematic there is no 555

      Alex


  • At 17 October 2012, 14:50:28 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Alex Use an inverting transistor to invert your signal. The 555 cannot accept other pulse to operate.


  • At 17 October 2012, 14:23:00 user Alex wrote:   [reply @ Alex]
    • Hi Giorgos,

      When I check my scoop you trigger in the rising edge. Is it also possible to send me of publish a hex file for descending edge. I want to use my own zero cross, but it is wider. If you want I'll send you a scoop picture of my zero cross.

      Alex


  • At 27 July 2012, 17:43:44 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Erik I do? my bad. turn it off :D


  • At 27 July 2012, 16:04:28 user Erik wrote:   [reply @ Erik]
    • @Giorgos Lazaridis Thanks.I saw in your code (correct me if I'm wrong) that MCLR is on.If it is,shouldn't then be something connected on pin GP3(5 volts through 4,7 Kohm resistor)?


  • At 27 July 2012, 13:40:42 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Erik no there is no need to pull it up. R6 does this for you


  • At 27 July 2012, 1:58:43 user Erik wrote:   [reply @ Erik]
    • @Giorgos Lazaridis Ok.No problem.One more question.Is pin GP2 (pin for zero crossing detection) programmed as pull-up input?


  • At 23 July 2012, 19:46:38 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Erik I'm sorry but i cannot offer changes in programs whatsoever, i have too little time.


  • At 22 July 2012, 22:56:02 user Erik wrote:   [reply @ Erik]
    • Hello.
      I'm trying to rewrite program for c but I don't understand assembly code(what are commands exactly doing).
      Can you write comments in the commands line so I can know what is code exactly doing.You can upload notepad with comments here or send it to my mail adress.
      Thank you.


  • At 18 July 2012, 15:24:02 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Alek 3.2VA at 12V is some 250mA, which is more than enough. And the rectifier is ok as well.


  • At 17 July 2012, 19:42:38 user Alek wrote:   [reply @ Alek]
    • @Giorgos Lazaridis
      Hy once again.
      Yesterday I bought 220/12V 3.2VA.They oferred me trafos betwen 2 and 30 VA.
      Is that ok or should I take another trafo with different VA?
      And also I bought W10M Single Phase 1 Amps Silicon Bridge Rectifier.They didn't have 2 Amps rectifier.


  • At 10 July 2012, 5:28:48 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Alek 220/12V


  • At 9 July 2012, 13:13:42 user Alek wrote:   [reply @ Alek]
    • @Giorgos Lazaridis Thank you for your quick response.
      Can you tell me which exact transformer did you use?


  • At 9 July 2012, 11:44:21 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Alek well, 5V after the 2 diodes of rectification will become some 3.4V which are not suitable for stable operation. The wires i used are all thin wires from UTP cable... there are no large currents on the board, unless you use a big bulb in watts.
      Remember to use precision potentiometers for the setup otherwise you will get a headache to stable it.


  • At 8 July 2012, 22:34:12 user Alek wrote:   [reply @ Alek]
    • @Giorgos Lazaridis Thank you for your answer.I have two more questions.
      Which transformer did you use?I have 220/5V transformer at home.If I use that one should I remove R2 resistor or change something in schematic?
      And can you tell me what thickness of the wire did you use for breadboard test-run


  • At 4 July 2012, 19:58:18 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Alek I kinda chose them from an educated guess. Resistors R4 R5 will perform a voltage divider to the base of Q1 which makes the voltage much less. C1-R1 performs a small low pass filter. R2 can be omitted if the transformer's voltage is small.
      Whenever the base voltage is above 0.7 volts (Q1's Vbe voltage), Q1 saturates and current passes through the CE contact. So, the output voltage of the transistor is 0 (or nearly 0). But whenever the voltage is below 0.7, the transistor is in cutoff and no current goes through CE, so all voltage appears at the edge of R6. This is your pulse...


  • At 4 July 2012, 16:52:19 user Alek wrote:   [reply @ Alek]
    • Hello.Great project!
      I have one question that is maybe not usual.How did you calculate elements(resistors,capacitors and transistor) for zero crossing detection and how this sheme exactly works.How we get impuls at the zero crossing.
      Thank you.
      Alek


  • At 13 February 2012, 17:37:23 user Giorgos Lazaridis wrote:   [reply @ Giorgos Lazaridis]
    • @Delusional hmmm i'm not quite sure, but actually i do not think that you need to change anything. The transformer mst be 110/12, the MOC works for 110 as well... the timing is flexible so you can adjust it for 60... so hopefully it will work as-is.


  • At 12 February 2012, 19:43:30 user Delusional wrote:   [reply @ Delusional]
    • What would i need to change to make this work with 120V/60Hz?

      Thanks in advance...


  • At 25 January 2012, 19:51:06 user Kammenos wrote:   [reply @ Kammenos]
    • @Scottie no there is no problem with this. You may wanna replace R7 with a 5K potentiometer instead and remove this resistor.


  • At 25 January 2012, 19:27:56 user Scottie wrote:   [reply @ Scottie]
    • Hi there again (wrote on 13 Jan). Tried the circuit, works well. Only I found that I needed a 2k2 Ohm resistor between 5V and the 2k2 trimpot to get a turn off point middway otherwise the trimpot had to be fully anticlockwise. Any downside in the PIC ADC calculation by adding this ?


  • At 13 January 2012, 23:03:46 user Kammenos wrote:   [reply @ Kammenos]
    • @Scottie i think i had this 7805 with the heatsink already... not necessary indeed.


  • At 13 January 2012, 14:51:33 user Scottie wrote:   [reply @ Scottie]
    • Hi there, great circuit, looking forward to trying this out next week. Can you tell me one thing - why do you have a heat sink on the 7805, I would expect only a relatively small current used in the 5 volt section with only the PIC and optocoupler devices ?


  • At 13 December 2011, 5:52:47 user Kammenos wrote:   [reply @ Kammenos]
    • @Rich i've been told that again from people using a specific IE version. Try with mozilla or chrome


  • At 10 December 2011, 7:26:58 user Rich wrote:   [reply @ Rich]
    • Hi:

      2nd e-mail about this. For some reason I can not view the assembly code listing. I like to build this circuit and need to program the PIC. Could you e-mail me the assembly code listing? Many thanks in advance. Richard


  • At 2 November 2011, 6:49:38 user Kammenos wrote:   [reply @ Kammenos]
    • @Pratik if you know how dimmer works and a little bit about assembly, then this is a simple program. The main idea is that within the MainLoop, it constantly reads the ADC to get new TriggerDelay value, which is actually the delay from the time that the circuit detects a zero-cross, until the PIC triggers the triac.
      Then, in Cont1 the pic tests the timer0 module. This module becomes zero every time that the PIC detects zero-cross (interrupt routine). If the tmr becomes higher than the TriggerDelay, then the PIC activates the triac (bsf Trigger). The triac gate is also cleared within the interrupt routine.
      Dimmers always add some kind of noise in the power lines. To avoid noise, you need to add filters, but i am not good at this. A small load will not add significant noise. But remember that a hair dryer adds much more noise than any dimmer.
      As for the halogens, i have never test anything with them, so i cannot answer.


  • At 1 November 2011, 16:50:49 user Pratik wrote:   [reply @ Pratik]
    • Great post and great work,
      I am doing this same project and i want to dim three halogen. It would be great of you if i get some help in understanding your assembly program. I need to know what are you doing in the program. About How and when is the triac triggered . A good flowchart and little explanation will clear my doubts.I have heard that noise is generated with this methos . Is it true.If yes what is the other solution.
      Also i want to know whether i can convert ac to dc and then make use of IGBTS or Mosfet to dim the halogens. If so How can I do this. Any ideas can be useful to me.
      regards,
      Pratik


  • At 25 July 2011, 9:35:29 user Alex Houben wrote:   [reply @ Alex Houben]
    • Ok thanks for the quick respond!

      I'll try to write my own code, keep up the good work!
      Alex


  • At 25 July 2011, 4:47:47 user Kammenos wrote:   [reply @ Kammenos]
    • @Alex Houben i'm sorry there is no picbasic code, only assembly.


  • At 24 July 2011, 18:56:20 user Alex Houben wrote:   [reply @ Alex Houben]
    • Hi,
      I have build the project and it works perfectly!!!

      Is it possible to post the picbasic sourcecode, if it exists.
      I want to build a multichannel dc controlled dimmer with one pic.

      Thanks in advance!

      Alex

      Belgium


  • At 22 April 2011, 5:46:50 user Kammenos wrote:   [reply @ Kammenos]
    • @DAVID there is no mistake. I checked. This is what datasheet states about ANSEL,3
      bit 3 - ANS3: Analog Select Between Analog or Digital Function on Pin GP4
      1 = Analog input. Pin is assigned as analog input(1).
      0 = Digital I/O. Pin is assigned to port or special function.

      It is for GP4 (pin 3)


  • At 16 April 2011, 15:30:02 user DAVID wrote:   [reply @ DAVID]
    • bsf ansel,3 ; 1000 GPIO 3 IS ADC INPUT

      YOUR CODE SEEMS TO SET gpio3 AS INPUT FOR ADC BUT IS INFACT CONNECTED TO GPIO4 ON PIN 3 WHICH bit is wrong the code or the schematic..

      All the best David


  • At 6 April 2011, 12:52:50 user Kammenos wrote:   [reply @ Kammenos]
    • @nmol sure, any pic can run similar code and circuit. Choose one with more pins.


  • At 6 April 2011, 12:24:57 user @nmol wrote:   [reply @ @nmol]
    • is there any pic controller which can be useful fr 4 channel ac load dimmer


  • At 3 April 2011, 5:54:01 user Kammenos wrote:   [reply @ Kammenos]
    • @Bryan microgeo answered


  • At 3 April 2011, 5:42:46 user microgeo wrote:   [reply @ microgeo]
    • I was interested in the zero-crossing too but that is unfiltered "DC" after the rectifiers. Enough to trigger the pulse in his circuit. I used this to learn circuit modeling and the model generates a beautiful pulse just like his video.


  • At 3 April 2011, 3:02:46 user Bryan wrote:   [reply @ Bryan]
    • Zero crossing point detection is only used on AC circuits, so why did you bother putting it on this DC circuit, its not doing anything. the bridge rectifier is producing DC from the AC, so anything after the bridge is DC, and does not have a sinusoidal wave for the zero point to detect. Your just wasting components and potentially endangering your life by messing around with mains voltage when you obviously have no idea what your doing.


  • At 1 April 2011, 9:14:11 user Kammenos wrote:   [reply @ Kammenos]
    • @Raavan i have also upload the assembly file. No C code is available. I program only in assembly.


  • At 1 April 2011, 5:52:43 user Raavan wrote:   [reply @ Raavan]
    • Hello Everyone.
      I have a doubt regarding the programming of the microcontroller. You have actually given the binary file, is it possible for the programmer(the brain behind the heart of the circuit) to upload the algorithm and if possible the c program of the same binary file.
      Thank You well in advance and I hope for a quick reply.


  • At 18 March 2011, 18:44:17 user Kammenos wrote:   [reply @ Kammenos]
    • the assembly listing fits only for this PIC.


  • At 18 March 2011, 10:43:01 user dee wrote:   [reply @ dee]
    • and If I use an ATMEGA 8 BIT MCU will the code/assembly listing will remain same?


  • At 18 March 2011, 10:41:14 user dee wrote:   [reply @ dee]
    • Can I use a different MCU of same configuration like that of ATMEGA MCU of 8 bits?


  • At 17 March 2011, 20:09:58 user Kammenos wrote:   [reply @ Kammenos]
    • the chip is enough, but you need the programmer.


  • At 17 March 2011, 19:37:35 user dee wrote:   [reply @ dee]
    • hi Kammenos
      For PIC12F615 , just this chip will work or I have to also get the development board?


  • At 4 March 2011, 14:29:06 user Kammenos wrote:   [reply @ Kammenos]
    • dee, it is tie T1 BT136D triac.


  • At 4 March 2011, 8:53:00 user dee wrote:   [reply @ dee]
    • hi
      in the circuit ,what is the part in the end numered as 1 2 3. and is this lamp getting an ac circuit or DC. Could you explain me the lamp part..


  • At 3 March 2011, 21:26:22 user Kammenos wrote:   [reply @ Kammenos]
    • R7 is to be changed but the specification you have to find it yourself


  • At 3 March 2011, 19:48:16 user dee wrote:   [reply @ dee]
    • hi,
      for using it for automatic light regulation , which part is to be replaced with photocell and which photocell(specifications)we have to use.
      pls help its urgent.


  • At 11 January 2011, 14:47:40 user microgeo wrote:   [reply @ microgeo]
    • This is an excellent and well-explained analog and digital project. Being new to PICs, while the circuit and video make sense, I am struggling with programming since I use basic. Would you mind helping myself and others with a description of the logic of your programming? Much appreciated!


  • At 23 December 2010, 14:20:53 user Kammenos wrote:   [reply @ Kammenos]
    • I would never sleep quiet if i had a dimmer without galvanic insulation between mains and PIC. I began with a huge resistor (4 o 8 MOhms i do not remember), and worked perfectly, until i asked myself one single thing: And if the resistor fails??? It is most unlikely, but again, this galvanic insulation keeps the circuit itself safer as there is no connection with ground.


  • At 23 December 2010, 12:34:52 user Matt wrote:   [reply @ Matt]
    • Excellent approach, especially with regards to electrical safety. I have seen other designs which are directly coupled to the mains but I prefer this way to get the zero-crossing signal after isolating from the mains with the transformer. Use of the optocoupler on the triac side again keeps the pic safely isolated from the mains. Brilliant - I will choose this approach for my dimmer circuit design and I hope others will too.


  • At 22 December 2010, 5:24:31 user Kammenos wrote:   [reply @ Kammenos]
    • No sorry. i do only assembly.


  • At 21 December 2010, 22:44:08 user Mert wrote:   [reply @ Mert]
    • Hi,
      this is very good project but i can't understand assembly code. Do you have ccs code of this project?

      Pls help



    delicious
    digg
    reddit this Reddit this
    Faves



     HOT in heaven!


    NEW in heaven!



    New Theory: AC electric motor working principle



     Contact     Forum     Projects     Experiments     Circuits     Theory     BLOG     PIC Tutorials     Time for Science     RSS   

    Site design: Giorgos Lazaridis
    © Copyright 2008
    Please read the Terms of services and the Privacy policy