> > My questions.... > 1. how do I build a circuit that allows the device > to use power from the > wall-wart when available, but from the LiIon > otherwise. Specifically, > the device should *not* use any power that is > recharging the LiIon cell. There are sample circuits on the net. Basically it use a diode for the battery to only allow current to flow in absence of the walmart adapter. > Additionally, the wall-wart supply will also have to > be regulated > *after* feeding the charger down to 5V from 5.7 > *nominal*. (I was > thinking a resistor/zener/schottky combination - > 50Ohm, 5.1V Zener, and > then a schottky, but this wold not be as effective > if the input voltage > was at the charger's max of 12V...). > 2. How do I build a protection circuit so that the > device will be shut > down if the LiIon voltage drops below 2.5V. This > must not draw more than > a few uA from the cell! Okay, you can use the ADC module from the MCU to determine the voltage that you want to *shutdown* and just wait till the power satifies your voltage requirement. John > > In regards to 1, it may be useful to see the > "Typical Application" > diagrams on page2 of the MCP73863 (charging IC) > datasheet here: > http://ww1.microchip.com/downloads/en/DeviceDoc/21893c.pdf > The LT1111-5datasheet is here: > http://www.linear.com/pc/downloadDocument.do?navId=H0,C1,C1003,C1042,C1033,P1459,D2092 > > > You can check on of the latest articles from circuit cellar for more information on the charging circuit. I can't remember which article off hand. John PS: If you want a really cheap comparator and charging solution the PIC already have a comparator built in. Just charge the battey until the reference voltage is reached. __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist