On Tue, Mar 23, 2004 at 12:57:02PM +0200, Lucian wrote: > Ok, the source I need is for a security system I'm designing. if it > works well, it could be produced in high volumes. > The system is powered from the wall outlet to a 13.8V step-down > transformer, which feeds the regulators. This would be simple if I > didn't needed a battery backup. From the sensors point of view, the 12V > could be between 9V and 16V, but I have also some comparators which work > at 12V and if the voltage drops bellow, the result isn't accurate > anymore. OK. This helps. Here's a key question: Why do the comparators work at 12V? As you know comparators compare voltages. Using resistor dividers, possibly built into an opamp divider, it should be possible to take the original 12V requirement and cut it to something much less, such as 4V. Once you've done that, then you can ditch the 12V requirement, still keeping the unregulated higher voltage supply to power the circuit. You then have: 1) 13.8V input supply feeding... 2) A 12V gel cell which serves as the input to... 3) A 5V switcher which then using dividers drives.... 4) the comparators. 12V is then rendered unnecessary. > When the power is off, the battery must backup both the 12V and the 5V. Again using the comparators at a lesser voltage obviates the need for a regulated 12V supply. > I thought of using 2 regulators, and when the power fails, a relay to > connect the battery to the 12V directly and to the 5V regulator. Bad idea. It'll glitch when the power fails. The only way for this to work effectively is for the battery to be the primary power source while actively being charged from the line. I have a sunrise/sunset light controller that is battery backed, and when developing I tried both ways. I never got the relay method to work without the board resetting. But with the battery feeding the regulator, it "switches" smoothly, because it doesn't switch. > Is this suitable ? I would also need a charging circuit for a lead-acid > battery, can you indicate me a good circuit ? The UC3906 I alluded to earlier. However if you have a PIC onboard, there's not necessarily a need for it. Also if your input voltage is only 13.8V you can only float charge anyway as you need a minimum of 14.4V to bulk/absorption charge. BAJ -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics