I am really in a tough situation and need very serious elaborative help with this. Almost like spoon-feeding.
It's been days I've been trying to get my zero cross detector (and the triac dimmer) to work properly but nothing works fine. I am trying to get my circuit to work but all in vain whereas there is another product (which I opened to reverse engineer) that uses the same triac and almost similar components but with few changes and sill works. I'll explain both cases to you.
I am using an H11AA1 optocoupler with a 150k resistor to use AC voltage to generate interrupts on my ESP8266 (esp-12e) micro-controller (integrated wifi). The circuit is as in image
But the problems that I face a numerous -
- A 1/4W resistor gets too hot and burns if any lesser value is used.
- The interrupts are for the RISING edge as there will be spikes when there is zero cross. The interrupt durations are (in milliseconds) are like -- 10,9,0,0,1,9,10,0,0,0,10,0,0,10,9,9,1,0,0,1,1,10,....... and so on. WHY?!!? Why is it so jumpy? And the random values? I was suggested that the current on the AC side is less. But as I said lowering resistance burns it and increasing might spoil it more. Talk about paradox, huh?
Now about the product I was trying to reverse engineer -
Why that's a problem to me -
- They are using a variant of the (almost) same opto-coupler, H11A1. And they use a "330k" smd resistor (x2 times higher) that's got to be 1/4W. Now obviously the 2 times higher resistance is the reason why it's not burning. But how's that giving enough current to generate the right interrupts?
Please help me here. With the current scenario there's pretty irregular flickering in the triac dimmer tested with incandescent light bulb. It's been days to understand why this is happening...
Big thanks in advance.. :)