wont a relay be a better option... "Dwayne Reid" wrote in message news:20070213204740.34VH3HNBQQ@priv-edtnaa05.telusplanet.net... > At 10:56 AM 2/13/2007, peter green wrote: > >>a better soloution imo is to use an optocoupler, connect a suitable >>resistor in series with the optocoupler to limit the current to >>something the led in the optocoupler can handle and stick a suitable >>diode in inverse paralell with the optocoupler LED to prevent >>reverse breakdown. > > Peter - if you were using a resistor to limit the current, you would > be better off putting the diode in series with the resistor rather > than across the opto LED. The LED needs to see current in only one > direction. By putting the resistor in series with the diode, you > have reduced the power consumption by half. This allows a smaller > resistor. > > That said - I don't think that a resistor-based approach is 'best', > especially if sensing 220 VAC. Too much dissipation in the resistor. > > dwayne > > -- > Dwayne Reid > Trinity Electronics Systems Ltd Edmonton, AB, CANADA > (780) 489-3199 voice (780) 487-6397 fax > > Celebrating 22 years of Engineering Innovation (1984 - 2006) > .-. .-. .-. .-. .-. .-. .-. .-. .-. .- > `-' `-' `-' `-' `-' `-' `-' `-' `-' > Do NOT send unsolicited commercial email to this email address. > This message neither grants consent to receive unsolicited > commercial email nor is intended to solicit commercial email. > > -- > http://www.piclist.com PIC/SX FAQ & list archive > View/change your membership options at > http://mailman.mit.edu/mailman/listinfo/piclist > -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist