Home     Forum     Projects     Experiments     Circuits     Theory     BLOG     PIC Tutorials     Time for Science

### Author Topic: Dimmer error  (Read 4093 times)

0 Members and 1 Guest are viewing this topic.

#### Erkeli

• Guest
##### Dimmer error
« on: March 20, 2008, 16:46:38 PM »
Well, i made my dimmer using a PIC but i have came up with a problem. I have a constant to measure time for each period. This timer is the one that will send the trigger to the gate of the scr. Then, it will start counting again for the next time to send the trigger to gate. To make my self more clear, this timer tries to find the exact moment that the voltage is 0 volts.

And here comes my problem. I do not really can exactly calculate this. I put a value and it works perfect but after a while the lamp starts lighting more and less. This is normal because i cannot calculate exactly the point that the voltage is 0.

How do you calculate this? I saw some examples with some 4-8mohms resistors connected to a dimmer chip that i think they are used to check the voltage and find always the corect time to send the gate trigger. But i do not really like this method and after all, i do not know if it can be used for a PIC also.

Any help on the table?

#### kam

• Hero Member
• Posts: 1849
##### Re: Dimmer error
« Reply #1 on: March 20, 2008, 20:20:09 PM »
Why don't you read the Dimmer theory pages? The answer lies there!

#### Stefano

• Guest
##### Re: Dimmer error
« Reply #2 on: March 20, 2008, 23:06:59 PM »
Timer? Value? you can only detect the zero crossing if you want to make a dimmer. that's why there are these 8Mohms resistors. Kam has a very nice idea to his theory pages that you have no direct connection of mains to the PIC.

Surf the site!

#### Erkeli

• Guest
##### Re: Dimmer error
« Reply #3 on: March 22, 2008, 12:08:22 PM »

But it turns now that i have to completely re-constructure my dimmer

One more question regarding the zero crossing circuit you provide. How can i adjust R1?

#### kam

• Hero Member
• Posts: 1849
##### Re: Dimmer error
« Reply #4 on: March 22, 2008, 17:54:00 PM »
One more question regarding the zero crossing circuit you provide. How can i adjust R1?

In case you have an oscillator, you need to adjust it so it has as tight width as can be but do not decrease the voltage of the peek less than 3.5 volts.

Otherwise, put the resistor into half and use your instinct. It is easy. You will understand by the results.

#### Erkeli

• Guest
##### Re: Dimmer error
« Reply #5 on: March 23, 2008, 00:36:18 AM »
IC.
I keep you informed when i have results. Tomorrow i will do some work for this.