You have the right version.
It's suppose to work unless you have some hardware issue OR device prograemmer issue.
You have the right version.
It's suppose to work unless you have some hardware issue OR device prograemmer issue.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Mister-e - Thanks! I will go over my circuit again. It helps knowing that the code I am trying to run is the correct version - I can focus my attention elsewhere. If you (or anyone else) can offer some troubleshooting ideas, they would be appreciated.
Atom058
Well, I did find (part of) my problem - It was a bad solder at GPIO.4 so it was never seeing the zero crossing. Having fixed that, I now can dim the light up and down just like it is supposed to. However, (bet you saw this coming) when it is between full on and full off, it flickers randomly. The dimming works but it flickers until it gets to full on or full off. I am sure that this is a timing issue but can't see where to get at it. I am at 60 Hz, 120V. I am using the code as previously posted.
I know that some of you (Mister_e) feel like you are beating a dead horse with this dimmer project, but if you can help me get through this, I will post my final code, circuit diagrams and parts lists so that anyone can build this and you will never have to deal with it again (hopefully!).
Thanks (Mister_e)!
Atom058
interesting. to me it's sounds like a an delay offset in the Zero Crossing. Done by the transformer AND the 470uF cap.
Can be solved in software.
Give me the transformer information, part #, voltage etc. I will work on this.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Steve - Thanks for your reply - The transformer is from Jameco (www.jameco.com), P/N: 249412. The spec sheet says that I should be getting 8VAC @ 1.6A (I know that is a little over-kill on the amperage, but it is what I had lying around), but I am measuring 9.8VAC across the input to my bridge rectifier. Using a voltage divider (4k7 & 10K), that gets the DC voltage to GPIO.4 down to 4.33VDC. The cap is a 470 uF 25V electrolytic.
Let me know if you need anything else... Thanks!
Atom058
Steve - Any luck with the info that I posted?
I've been looking at some related posts and I am wondering if the timing problem is related to the maxdelay value. If I am running at 60 hz, that means that I complete 1 cycle every 16.7 mS. Or, I cross zero every 8.35 mS (8350 uS). Is that correct? In the code, MaxDelay is 6000 uS. Is this where my problem is?
Can you tell me why the transformer and 470 uF cap is of interest to you? How does this affect my timing?
Every day is a learning experience and I'm always looking for more!
Thanks! Atom058
I would love to hear from anyone that has successfully built this dimmer that is discussed on this thread. I have followed the code and schematics (as well as the changes to both) and can not achieve the end result. The circuit and code, as it stands now, will allow me to go to full on and full off by quickly tapping the inc/dec buttons. This part works perfectly. If I press and hold the inc/dec buttons, the lighting level changes gradually, just like it is supposed to, but I get flickering. Mister-e seems to think that it is a timing issue - and I am in agreement, but I do not know where to make adjustments. If anyone can give me some trouble-shooting ideas, I would greatly appreciate it.
I think this is a great design that has many uses. I would love to get it to work and post my final results!
This circuit, once I get it right, is going to be the basis for a larger design, But until I get this part working, I can not move forward.
Please help!
Atom058
Bookmarks