One diode in series from the battery to Vdd, one resistor from 220VAC phase to INT (better with an optocoupler). On 6/26/07, Miguel Reznicek wrote: > Friends: > > Does someone know of a PIC chip circuit that will monitor the 220 VAC mains > and use them to run, but that can automatically switch to a battery power > when the mains fails? I need to make an alarm for when the power fails. > > Thanks in advance, > > Miguel Reznicek > mreznicek@pretensa.com > > > -- > 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