![]() |
![]() |
![]() |
|
|
|||||||
| Electronic Projects Design/Ideas/Reviews Are you building an electronic project or want to? Maybe you need some assistance? Come and submit your electronic questions here and let our experienced members find a solution. |
|
|
Thread Tools | Display Modes |
|
|
(permalink) | |
|
Quote:
Whats the relationship between the dimmer and the PIC, in your design ?
__________________
Eric "Good enough is Perfect" PIC tutorials: Gramo's: www.digital-diy.net/ Bill's: www.blueroomelectronics.com/ |
||
|
|
|
|
|
(permalink) |
|
Im simply trying to replace an existing light switch with a dimmer switch;
However, instead of the off-the-shelf dimmer switches avaliable that use a variable resistor to control the dim amount, i would like to use a PIC. I have tested the dimmer circuit and the PIC code used to dim a bulb, but deriving power inline with a bulb is causing me a few concerns. |
|
|
|
|
|
|
(permalink) |
|
So why do you keep asking about LED's?.
|
|
|
|
|
|
|
(permalink) |
|
Because, in addition to controlling the triac firing angle, the PIC will also control 10 LEDs in a bargraph format, indicating the current dim position.
1 LED lit indicates the lamp has been dimmed to its minimum value (off). 10 LEDs lit indicates the lamp is at full brightness. The LEDs will be PWM controlled to reduce power consumption still further. |
|
|
|
|
|
|
(permalink) | |
|
Quote:
I dont want to sound like a smart a*rse, but wont the actual lamp you are controlling tell you how dim the light is? The bog standard light dimmers that control a triacs firing angle are quite efficient, minimal power wastage?
__________________
Eric "Good enough is Perfect" PIC tutorials: Gramo's: www.digital-diy.net/ Bill's: www.blueroomelectronics.com/ |
||
|
|
|
|
|
(permalink) | |
|
Quote:
I'm not too concerned with wasting power, 10mA is nothing, and is less than the standby light on the TV. |
||
|
|
|
|
|
(permalink) |
|
You can buy a light dimmer that has a 10 LEDs bar graph. It has up and down buttons and also has IR remote control.
__________________
Uncle $crooge |
|
|
|
|
|
|
(permalink) |
|
I know - but where is the fun in that!
If i can get this PSU sorted, then i can do other things like security, auto-dim after x-seconds, etc.... |
|
|
|
|
|
|
(permalink) | |
|
Quote:
|
||
|
|
|
|
|
(permalink) | |
|
Quote:
I guess you could use a small current transformer in series with the lamp to generate voltage for the PIC when the lamp is at it's brightest and drawing max current. It does add the complication of extra inductance in the load. Another technique would be to never bring the bulb to 100% brightness though this won't be very efficient.
__________________
--- The days of the digital watch are numbered. --- |
||
|
|
|
|
|
(permalink) |
|
If you make the current requirement low enough, you could connect it between the live and earth and still comply with the IEE regulations. In order to comply the capacitance must be <4n7 to earth and the resistance much be >1M to earth.
What current can you get your PIC working down to, will it work down to 200ľA?
__________________
I also post at the following sites: http://www.stop-microsoft.org http://www.heated-debates.com Screen name: Aloone_Jonez |
|
|
|
|
|
|
(permalink) |
|
The PIC will work, however, its going to be tricky to fire a triac at such a low current.
I need about 30mA really to do the LEDs and the triac. |
|
|
|
|
|
|
(permalink) | |
|
Quote:
This is one way you could get +5V for the PIC and LED's. Consider the Triac as being OFF, non conducting. The capacitive reactance of C1 at 50HZ will limit the current thru the Lamp/C1 and the power zener to approx 35mA. The voltage drop across the 5V6 zener, will reduced by the forward voltage drop of the 1N4007 diode, which charges the Cd smoothing cap, giving approx +5V, wrt to the neutral line, this will power the PIC etc. As the Triac is switched into conduction by the trigger transformer, the current flowing thru the Triac will also flow thru the 5V6 zener [ thats why it has to be at least a 5Watt zener], the voltage drop across the zener is 5.6V as before. You will always have 5.6V drop on the positive half cycle of the mains supply, that shouldn't be a problem. The problem is the Triac trigger reference, I have shown a trigger isolation transformer. You have not said in your posts, how you intend driving the Triac from the PIC? Where are you going to get the mains phase cross over point reference for the dimmer control? Please look thru the drawing, any points you dont understand... ask
__________________
Eric "Good enough is Perfect" PIC tutorials: Gramo's: www.digital-diy.net/ Bill's: www.blueroomelectronics.com/ Last edited by ericgibbs; 7th July 2008 at 11:22 AM. |
||
|
|
|
|
|
(permalink) |
|
HI,
I get the phase cross over from a resistor and diode in series with each other, directly into the PIC input pin from the live wire (just after the switch). The PIC has input over and under voltage protection diodes build into it, so i get an interrupt when the phase goes from zero to peak and another when the phase changes from peak to zero, 10ms apart, which is enough to detect the zero crossing points (there is a small error on the cross over points due to the trigger threshhold, but this is only a few uS) I drive the triac via a MOC 3020 device, which converts a logic level into the correct levels for driving triacs. The lamp in the drawing is in the wrong place, it should be connected between the bottom of the zener (currently the N line) and N. L --- PSU --- LAMP --- N Last edited by kybert; 31st October 2007 at 12:58 PM. |
|
|
|
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Latest |
| Linear Unregulated Power Supply | jbchrist | Electronic Projects Design/Ideas/Reviews | 19 | 16th February 2007 10:10 AM |
| Power supply design | FusionITR | General Electronics Chat | 4 | 11th March 2006 01:16 PM |
| Ultra low power power supply | steevke | Electronic Projects Design/Ideas/Reviews | 1 | 3rd February 2006 03:46 AM |
| Power Supply for a project to be powered within an Auto? | hexibot43 | General Electronics Chat | 16 | 8th September 2005 02:35 PM |
| Power supply/ current supply design | inkedallusion | Electronic Projects Design/Ideas/Reviews | 1 | 17th December 2002 01:10 AM |