Mcu 0137-SLA-charge-controller

From wikipost
Revision as of 13:57, 16 June 2019 by Admin (talk | contribs)
Jump to navigationJump to search

For me this charge controller is part of a bigger project, but since it should work fine as a stand-alone solution I thought I'd put it here for the world to see and use.

I will be using the 8-pin 8-bit ATtiny84 for this design.

This charge controller aims to do the following:

  • use battery voltage sensing to detect whether the charging circuit should be activated or not.
  • use a fixed charge current in combination with an LM317 to regulate charge current
  • set final charge voltage using a trimpot
  • enter sleep mode on the microcontroller to save power when the battery is charged.
  • signal charge state with an LED


  • use a boost converter to allow charging from low input voltages (e.g. 5V from a USB port).

The first version of the charge controller schematic:

0137 schematic v1.0.png

The next step will be to work out the following features:

  • choosing a more powerful FET to controller higher charge currents
  • minimise current draw when not charging (hopefully less than a few uA's)

Sizing the Charge Controller FET

N-channel FETs Q2 and Q4 are just for switching the P-channel FETs to ground, so they can be low-power 2N7000 or BS138. The FET Q3 is used to switch on the voltage-divider network to sample the battery voltage and with the two resistors in series we'll see only a few mA's running through Q3, so no worries there as well. However, P-channel FET Q1 is the one that is the one that will be applying the charge current (as regulated by the LM317) to the battery.

(to be continued..)