Page 1 of 2

Problem with arduino

PostPosted: Fri Mar 09, 2012 7:14 am
by fitri
Hi all,

a few day a go i do blow an opto-isolator that connect with my arduino..so frustrated..
last night i just want to give it a try to test my arduino board..so i download one of example program..but the Led does not act as desired..
the arduino environment show as below:


is this mean my arduino spoiled?

Re: Problem with arduino

PostPosted: Fri Mar 09, 2012 11:22 am
by ABSF
How did the opto-coupler get spoilt? Did you accidentally shorts the output to the input of the opto?

Allen

Re: Problem with arduino

PostPosted: Fri Mar 09, 2012 12:33 pm
by fitri
ABSF WROTE:How did the opto-coupler get spoilt? Did you accidentally shorts the output to the input of the opto?

Allen


i think i didnt check the spect carefully..im usiang H11AA1..is it for 110v or 220v?

Re: Problem with arduino

PostPosted: Fri Mar 09, 2012 5:53 pm
by robosang
A photo of your hardware will be helpful.

Re: Problem with arduino

PostPosted: Fri Mar 09, 2012 6:01 pm
by ABSF
robosang WROTE:A photo of your hardware will be helpful.


Agreed with robosang. This is a circuit involving AC 220V so the opto should be kept away from you Arduino and the driving circuit. I'd mount the opto-coupler on a separate PCB to prevent accidents.

Allen

Re: Problem with arduino

PostPosted: Sat Mar 10, 2012 7:30 am
by ABSF
fitri WROTE:
ABSF WROTE:How did the opto-coupler get spoilt? Did you accidentally shorts the output to the input of the opto?

Allen


i think i didnt check the spect carefully..im usiang H11AA1..is it for 110v or 220v?


H11AA1 is the wrong component. It is totally different from MOC3021. The secondary side of H11AA1 is a photo-transistor but on MOC3021 it is a photo DIAC. Always check the datasheet if the shopkeeper recommended you a substitute.

Allen

Re: Problem with arduino

PostPosted: Sat Mar 10, 2012 4:11 pm
by fitri
this is how i connect the circuit...sorry i dont have any CAD software...
:oops:

Re: Problem with arduino

PostPosted: Sat Mar 10, 2012 5:02 pm
by ABSF
Actually your circuit should look something like this:

ac_control_jpg.JPG
AC control from Arduino forum


The 120V AC is connected to the LED side of the optocoupler through 4x 47K resistors . The LED inside the opto has a Vf of 1.5Volts. The 4x 47K is used to drop 120-1.5=118.5V of the AC. The current through the LED is about 2.5mA. Since you're connecting to 220V you have to recalculate the value of the 4 resistors. Or else if the LED punches through and burn the transistor the high voltage would go into the Arduino pin_2 and toast the AVR. If you're lucky only the AVR is spoilt or else some other components on the Arduino board might also be toasted.

The values of R7, R8 and T1 might have to be changed/recalculated if you want it to work on 220V. The MOC3021 might have to be changed to one with ZCC and able to withstand 400V AC.

Allen

Re: Problem with arduino

PostPosted: Mon Mar 12, 2012 8:45 am
by fitri
ABSF WROTE:Actually your circuit should look something like this:

ac_control_jpg.JPG


The 120V AC is connected to the LED side of the optocoupler through 4x 47K resistors . The LED inside the opto has a Vf of 1.5Volts. The 4x 47K is used to drop 120-1.5=118.5V of the AC. The current through the LED is about 2.5mA. Since you're connecting to 220V you have to recalculate the value of the 4 resistors. Or else if the LED punches through and burn the transistor the high voltage would go into the Arduino pin_2 and toast the AVR. If you're lucky only the AVR is spoilt or else some other components on the Arduino board might also be toasted.

The values of R7, R8 and T1 might have to be changed/recalculated if you want it to work on 220V. The MOC3021 might have to be changed to one with ZCC and able to withstand 400V AC.

Allen

Hi,

this is my understanding,

4N25M use for arduino input = use to detect zero crossing of AC
MOC3012 replace with MOC3041, =this use to trigger bt137
all resistor need to calculate back.

Re: Problem with arduino

PostPosted: Mon Mar 12, 2012 10:31 am
by ABSF
fitri WROTE:Hi,

this is my understanding,

4N25M use for arduino input = use to detect zero crossing of AC
MOC3012 replace with MOC3041, =this use to trigger bt137
all resistor need to calculate back.


I forgot to mention that the circuit is for someone with good electronics experience. If you connect 220V AC directly to both opto couplers, there is always some dangers that you might get shocked by the AC and worse if you use breadboards.

If you dont understand what I have posted and need to double confirm for what I've said, this project is certainly not for you. :twisted: If something bad happens to you, I would be feeling guilty and might get me into trouble. Why not do some other safer projects and when you gain enough experience, you can always come back to do this project ?

I am not going to response to any further questions concerning this project unless others are willing to help. cheers!! :cry:

Allen