Saturday, April 13, 2013

Browse » home» » » » » A Car Battery Monitor

A Car Battery Monitor

A close name on the street can in reality center of consideration your thoughts on the importance of having a battery display in a car. I had been playing a nice week of touring around the united states of americaside at a leisurely tempo and taking in the beautiful surroundings on a daily basis. It wasnt until the ultimate day, with the big rush to return house, that I had to power at evening.My house is deep within the us of a and on the highway I used to be travelling the closest petrol station may be 80km away. I was traveling thru a neighborhood that is stuffed with open-cut coal mines and massive closely loaded semi-trailers continuously pound the highways, travelling at somewhat excessive velocitys. It used to be around 8pm at evening and the complete thing used to be very dark no side highway milds or home milds anyplace.

Just as I was once going up a hill, the solarshines started out to dim and the engine coughed. A massive semi-trailer loomed within the rear-vision mirror as I pushed the seize in and tried to relaxationart. My pace was falling rapidly and my lights were blacked out - I was once like a sitting duck in the direction of the highway, as the semi-trailer came swiftly bearing down on me. I simply managed to tug the auto off the street, as the semi-trailer got here screaming prior, missing me via inches! After calling for the lend a hand of the NRMA, the issue was once discovered to be a fault in the alternator, which used to be failing to charge the battery. The battery voltage had been falling underneath the heavy load of the milds and on the worst imaginable time, there was now not enough power for the lights or the motor.

After the preliminary shock wore off, I put on my thinking cap to come up with a PIC-based method to the problem. What was once in level of fact wanted used to be a show and a buzzer, to get my consideration must the voltage fall out of doors a targeted vary. So my design standards was set, a sequence of LEDs might indicate the voltage and a buzzer would also be used to warn of problems.
Main Features:
  • Visual indication of battery voltage
  • Audible warning when voltage becomes low
  • Screw terminals for easy connection
  • Simple and straightforward to construct
Circuit details:

The circuit is in line with PIC16F819 18-pin microcontroller which has an analog-to-digital (A/D) input to observe the battery voltage and outputs able to driving LEDs right away, to maintain the part count down. There are seven LEDs in all, giving a just right range of voltage indication. The topmost LED, LED1, comes on for voltages above 14V as a manner to happen when the battery is absolutely charged. LED2 point outs for voltages between 13.5V and 14V while LED3 point outs between thirteenV and 13.5V. Normally, probably the mostse LEDs shall be on. LED4 quilts 12.5V to 13V while LED5 quilts 12V to 12.5V. LED6 duvets from eleven.5V to 12V while LED7 comes on for voltages below 11.5V. These two LEDs are backed up with the help of the piezo chime which beeps for voltages between 11.5V and 12V and change intos more insistent for voltages under eleven.5V.

That might seem fairly conservative. After all, most automobiles will start and no longer using a bothers, even if the battery voltage could be a slightly under 12V, wont they? Well, no. Some brand new automotives will happily crank the motor at voltages beneath 11V however their engine management won't let the motor begin except the voltage is above 11V. So dont assume that a modern automobile will all the time begin reliably. This little battery monitor may easily prevent an extraordinarily inconvenient failure to start! So lets describe the the rest of the circuit. The incoming supply is linked by method of diode D1 which provides safety once extrast reverse polarity whereas zener diode ZD1 gives safety from spike voltages.

A usual 7805 3-terminal regulator is then used to provide a steady 5V to the microcontroller. The battery voltage is sensed by means of a voltage divider the use of 33kΩ and 100kΩ resistors. This delivers the voltage down to inside the 0-5V vary for the A/D input of the PIC16F819. Port B (RB0 to RB7) of the microcontroller is then used to force the quite loads of LEDs, with current limiting equipped by the use of the 330Ω resistor network. RB7, pin thirteen, drives a swaping transistor for the piezo buzzer.

Software:
For the software, the design follows the basic template for a PIC microcontroller. Port A and its ADC (analog-to-digital converter) operate are set up while port B functions because the output for the LEDs and buzzer. Once the set-up is full, a reading will likely be taken at port RA2, the enter for the A/D convertor. This reading is then when compared with a sequence of prices to resolve the range of the voltage. This is just like a collection of \"if\" statements in Basic language. If the voltage is found to be inside a certain vary, the related port B pin will almost definitely be fliped on. If the voltage is below 12V, the buzzer will most definitely be turned on for a brief duration, to signal a low battery situation. As the voltage falls beneath 11.5V, the frequency of the beeps will elevate, to signal elevated urgency.

Building it:

All the parts are installed on a small PC board measuring 46 x 46mm (available from Futurlec). The place to begin should be the IC socket for the PIC16F819, as this is best to mount whereas the board is naked. The next item will even be the PC terminal block. The resistors and capacitors can then follow. Make certain the electrolytics are inserted with perfect polarity.

Make sure that you don't confuse the zener (ZD1) with the diode when you in finding yourself putting in them; the diode is the larger bundle of the two.
 
Even extra essential, dont get the 78L05 3-terminal regulator and the 2N3906 transistor mixed up; they arrive in similar packages. The 78L05 will most certainly be labelled as such while the 2N3906 will most probably be labelled \"3906\". And you ought to definitely insert them the precise manner round. The buzzer should even be installed with the right polarity. The 330Ω current limiting resistors are all in a 10-pin in-line package. There are four green LEDs, two yellow and one crimson. They wish to be installed in line and with the precise orientation.

Testing:

Before you insert the PIC16F819 microcontroller, do a voltage examine. Connect a 12V supply and test for the presence of 5V between pins 14 & 5 OF IC1. If 5V just isn't existing, verify the polarity of regulator REG1 and the polarity of the diode D1. If these take a appear ats are OK, insert the IC and check the unit over a variety of voltage between 9V and 15V. Make positive that every one LEDs come on in sequence and the piezo buzzer beeps for voltages under 12V. 

Now it is subject of putting in the unit to your automobile. It is best to install the unit in a visual position for the driving force. However, it must now not obscure every other devices. The unit will have to be linked to the autos 12V supply after the ignition switch. This will flip the unit off with the other instruments and prevent battery drain whereas the motor is simply not working.



Author :Alan Bonnard Copyright : Silicon Chip Publications Pty Ltd

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.