PDA

View Full Version : 50hz sync for light dimmer



tirithen
- 4th September 2008, 01:15
I found this site with a real simple circuit for a light dimmer (http://www.radiolocman.com/shem/schematics.html?di=34004) that I built and it works but I'm having problems figuring out how to do the zero crossing detection with this 1M resistor connected directly to the pic12f675 gpio.2 pin. Since he connects it to gpio.2 pin my first guess was that he used INTE to trigger the interrupt but I have failed to make it work, it seemes that an other method is required to detect the change in the sine wave. I need to find how he has slowed it as this limits the components and obviously works. Via A/D?

If anyone is interested in my app so far here it is (it's not working so far). The idea is to make a dimmer that is connected between the ac line and the lamp with an ir-reciver and lightsensor (LED used as sensor). Then a central ir-transmitter with a clock sends a signal for timed control or a remote control for direct control or ir-diode connected to a computer for control via internet or possibly voice... haha, depending on how far I get.

For now I need to find the zero crossing with only a resistor between the ac line and the gpio2 pin. Any ideas?

b1arrk5
- 6th September 2008, 18:01
Personally, I wouldn't use a resistor, it's just dangerous. Please consider using an opto-isolator, and take a look at this link;

http://www.8051projects.net/_zero_crossing_opto-triac

It's simple, inexpensive, and unlike the 1 meg resistor, it gives you some isolation so that a spike doesn't come through and fry you or PIC.

I built an IR remote system using Bruce's IR decoder chip, my Sony television remote control, and some X-10 modules. Sit on the couch, aim the remote away from the TV and toward the circuit, and turn on different lights. Then I added a modem so that I can turn the lights on and off using text messages. I used a 16F877 with Darrel's Instant Interrupts, so I'm sorry that I can't help you with the 12F chip and interrupts, but I'm sure someone else will chime in.

Good Luck,

Jerry

nasib
- 6th September 2008, 19:29
Please can u send me a schematic diagram for 2000 watts inverter and the details of the transformer winding for same 2000 watts inverter?