The circuit can be divided into e main parts:
Measuring the temperature:
This is the most interesting part of the project, the purpose is to use a low cost design with a low cost components along with a good accuracy. i have used the great idea from http://www.electronics-lab.com/projects/pc/013/
, review it , it contains all the required details.
A separate module in the program has been written to measure the temperature, as it can be used in other purposes.
The charging circuit:
- I used LM317 in the first design, but the efficiency was too bad and the charging current was limited to 1.5A, in this circuit i used a simple adjustable constant current source, using one comparator of the LM324 IC. and the high current MOSFET trannsistor IRF520.
- The current is adjusted manually using the 10Kohm variable resistor. ( i'm working on changing the current through the software ).
- The program controls the charging process by pulling Pin(7) high or low.
The discharging circuit:
- I have used the remaining two comparators from the IC, one for discharging the battery pack and the other for listening to the battery voltage and stop the discharging process as soon as it drops to a predetermined value ( for ex. 1V for each cell )
- The program monitors pin(8) , it will disconnect the battery and stop charging when it's logic level "0".
- You can use any power transistor can handle the discharge current.
- Another variable resistor ( 5K ohm ) controls the discharge current.