








After the initial shock wore off, I put on my thinking cap to come up with a PIC-based solution to the problem. What was really needed was a display and a buzzer, to get my attention should the voltage fall outside a specified range. So my design criteria was set, a series of LEDs could indicate the voltage and a buzzer would also be used to warn of problems.For the software, the design follows the basic template for a PIC microcontroller. Port A and its ADC (analog-to-digital converter) function are set up while port B functions as the output for the LEDs and buzzer. Once the set-up is complete, a reading will be taken at port RA2, the input for the A/D convertor. This reading is then compared with a series of values to determine the range of the voltage. This is similar to a series of "if" statements in Basic language. If the voltage is found to be within a certain range, the relevant port B pin will be turned on. If the voltage is below 12V, the buzzer will be turned on for a brief period, to signal a low battery condition. As the voltage falls below 11.5V, the frequency of the beeps will increase, to signal increased urgency.
Make sure that you do not confuse the zener (ZD1) with the diode when you are installing them; the diode is the larger package of the two.Even more important, don't get the 78L05 3-terminal regulator and the 2N3906 transistor mixed up; they come in identical packages. The 78L05 will be labelled as such while the 2N3906 will be labelled "3906". And make sure you insert them the correct way around. The buzzer must also be installed with the correct polarity. The 330Ω current limiting resistors are all in a 10-pin in-line package. There are four green LEDs, two yellow and one red. They need to be installed in line and with the correct orientation.
Testing:
Before you insert the PIC16F819 microcontroller, do a voltage check. Connect a 12V source and check for the presence of 5V between pins 14 & 5 OF IC1. If 5V is not present, check the polarity of regulator REG1 and the polarity of the diode D1. If these tests are OK, insert the IC and test the unit over a range of voltage between 9V and 15V. Make sure that all LEDs come on in sequence and the piezo buzzer beeps for voltages below 12V.
Now it is matter of installing the unit in your car. It is preferable to install the unit in a visible position for the driver. However, it should not obscure any other instruments. The unit should be connected to the car's 12V supply after the ignition switch. This will turn the unit off with the other instruments and prevent battery drain while the motor is not running.
Author :Alan Bonnard Copyright : Silicon Chip Publications Pty Ltd
In the form of the LT1579 Linear Technology (www.linear-tech.com) has produced a practical battery switch with an integrated low-dropout regulator. In contrast to previous devices no diodes are required. The circuit is available in a 3.3 V version (LT1579CS8-3.3) and in a 5 V version (LT1579CS8-5), both in SO8 SMD packages. There is also an adjustable version and versions in an SO16 package which offer a greater range of control and drive signals. The main battery, whose terminal voltage must be at least 0.4 V higher than the desired output voltage, is connected to pin IN1. The backup battery is connected to pin IN2. The regulated output OUT can deliver a current of up to 300 mA. The LDO regulator part of the IC includes a pass transistor for the main input voltage IN1 and another for the backup battery on IN2.
The IC will switch over to the backup battery when it detects that the pass transistor for the main voltage input is in danger of no longer being able to maintain the required output voltage. The device then smoothly switches over to the backup battery. The open-drain status output BACKUP goes low to indicate when this has occurred. When neither battery is able to maintain the output voltage at the desired level the open-drain output DROPOUT goes low. The LT1579 can operate with input voltages of up to +20 V from the batteries. The regulator output OUT is short-circuit proof. The shutdown input switches off the output; if this feature is not required, the input can simply be left open.





Protect your expensive batteries from discharge damage with this mini-sized electronic cutout switch. It uses virtually no power and can be built to suit a wide range of battery voltages.
Main Features
Picture of the project:
Back in May 2002, we (Silicon Chip) presented the "Battery Guardian", a project designed specifically for protecting 12V car batteries from over-discharge. This unit has proven to be very popular and is still available from kit suppliers. This new design does not supersede the Battery Guardian – at least not when it comes to 12V car batteries. Instead, it’s a more flexible alternative that can be used with a wide range of battery voltages.
Parts layout:
In this new "Micropower Battery Protector", we’ve dispensed with the low-battery warning circuitry and the relatively cheap N-channel MOSFET used in the Battery Guardian in favour of a physically smaller module that steals much less battery power. It costs a little more but can switch lower voltages, allowing it to be used with 6V & 12V lead-acid batteries and 4-cell to 10-cell NiCd and NiMH battery packs.
PCB layout:
Most battery-powered equipment provides no mechanism for disconnecting the batteries when they’re exhausted. Even when the voltage drops too low for normal operation, battery drain usually continues until all available energy is expended. This is particularly true of equipment designed to be powered from alkaline or carbon cells but retro-fitted with rechargeables.
Circuit diagram:
Another example is emergency lighting and security equipment designed to be float-charged from the mains. In an extended blackout period, the batteries can be completely drained and may not recover when the mains power is finally restored.
Source: Silicon Chip 27 July 2004
The battery discharger published in this website may be improved by adding a Schottky diode (D3). This ensures that a NiCd cell is discharged not to 0.6–0.7 V, but to just under 1 V as recommended by the manufacturers. An additional effect is then that light-emitting diode D2 flashes when the battery connected to the terminals is flat. The circuit in the diagram is based on an astable multivibrator operating at a frequency of about 25 kHz. When transistor T2 conducts, a current flows through inductor L1, whereupon energy is stored in the resulting electromagnetic field. When T2 is cut off, the field collapses, whereupon a counter-emf is produced at a level that exceeds the forward voltage (about 1.6 V) of D2.
A current then flows through the diode so that this lights. Diode D1 prevents the current flowing through R4 and C2. This process is halted only when the battery voltage no longer provides a sufficient base potential for the transistors. In the original circuit, this happened at about 0.65 V. The addition of the forward bias of D3 (about 0.3 V), the final discharge voltage of the battery is raised to 0.9–1.0 V. Additional resistors R5 and R6 ensure that sufficient current flows through D3. When the battery is discharged to the recommended level, it must be removed from the discharger since, in contrast to the original circuit, a small current continues to flow through D3, R2-R3, and R5-R6 until the battery is totally discharged.
The flashing of D2 when the battery is nearing recommended discharge is caused by the increasing internal resistance of the battery lowering the terminal voltage to below the threshold level. If no current flows, the internal resistance is of no consequence since the terminal voltage rises to the threshold voltage by taking some energy from the battery. When the discharge is complete to the recommended level, the LED goes out. It should therefore be noted that the battery is discharged sufficiently when the LED begins to flash.
This circuit is usable as a Night Lamp when a wall mains socket is not available to plug-in an ever running small neon lamp device. In order to ensure minimum battery consumption, one 1.5V cell is used, and a simple voltage doubler drives a pulsating ultra-bright LED: current drawing is less than 500µA.
An optional Photo resistor will switch-off the circuit in daylight or when room lamps illuminate, allowing further current economy.
This device will run for about 3 months continuously on an ordinary AA sized cell or for around 6 months on an alkaline type cell but, adding the Photo resistor circuitry, running time will be doubled or, very likely, triplicated.
Circuit diagram :
Battery-powered Night Lamp Circuit diagram
Parts:
R1,R2___________1M 1/4W Resistors
R3_____________47K 1/4W Resistor (optional: see Notes)
R4____________Photo resistor (any type, optional: see Notes)
C1____________100nF 63V Polyester Capacitor
C2____________220µF 25V Electrolytic Capacitor
D1______________LED Red 10mm. Ultra-bright (see Notes)
D2___________1N5819 40V 1A Schottky-barrier Diode (see Notes)
IC1____________7555 or TS555CN CMos Timer IC
B1_____________1.5V Battery (AA or AAA cell etc.)
Circuit operation:
IC1 generates a square wave at about 4Hz frequency. C2 & D2 form a voltage doubler, necessary to raise the battery voltage to a peak value able to drive the LED.
Notes:
Source : www.redcircuits.com
Almost all 24V power systems in trucks, 4WDs, RVs, boats, etc, employ two series-connected 12V lead-acid batteries. The charging system can only maintain the sum of the individual battery voltages. If one battery is failing, this circuit will light a LED. Hence impending battery problems can be forecast. The circuit works by detecting a voltage difference between the two series connected 12V batteries. Idle current is low enough to allow the unit to be permanently left across the batteries.
Circuit diagram:
Battery Equality Monitor Circuit Diagram
Parts:
R1 = 2.K
R2 = 4.7K
R3 = 39K
R4 = 39K
R5 = 1.5K
R6 = 1.5K
Q1 = BC547
Q2 = BC547
Q3 = BC557
D1 = 3mm Red LED
D2 = 3mm GreenLED
B1 = DC 12 Volt
B2 = DC 12 Volt
Source : www.extremecircuits.net