A smart Battery charger circuit design guide

Published by MKDas on

Designing a proper battery charger circuit is a demanding project for almost anyone who works with power electronics. in this article, we are going to learn about the battery charger circuit design. After learning these techniques, you’ll be able to design your own battery charger circuit yourself.

Disclaimer: Electricity is always dangerous. Skill required to work with electricity. Do work with your own risk. Author will not be responsible for any misuse or harmful act. This website contents is also copyright protected. Anything copied and directly posted in your website and claiming it as yours is prohibited and nonsensical. Author published all the articles as opensource to help you making your project and learning purpose only. Learn and make one for yourself. If need any help feel free to ask the author. Author will be helpful to you. Thanks.

Basics of a battery charger circuit:

A battery charger circuit can be different types depending on battery size and power rating. But the basic blocks are almost the same for each battery charger circuit. If we want to see the very basic one then this block is will be the basic block diagram of your battery charger circuit:

Basic block diagram of a battery charger circuit

Each battery charger circuit has a power source higher than the battery voltage. This power is then delivered to the battery via a switching device. A current sensing circuit can be used herein between the switching device and the battery to sense the charging current. A voltage sensing circuit is used to sense the battery voltage.

Now depending on the battery size, this basic block can be modified to add some protections and features to improve the charging circuit performance as well as the battery charging efficiency.

What can be added?

We can add a temperature sensor for the battery to sense the battery temperature. We also can add a protection circuit for battery terminals for the wrong polarity. Also, we can add some short circuit protecting mechanisms and some other blocks too.

If we redraw the basic block diagram to little updated one, the block diagram will be this:

Improved block diagram for a battery charger circuit

Why these updates?

Yes, the question comes first to all of us that why we need to update the circuit like this? The answer is, we have to protect the charging circuit itself as well as the battery. Also, we need some kind of user-friendly options so that the operator can operate the charges as per his/her requirement. Let’s discuss one by one.

Input protection circuit:

If the charger circuit itself is overloaded or shorted somehow and there is no protection circuit between the input power source and our charger what will happen? Either the charger circuit will burn itself or the input source line will be damaged due to a short circuit. That is why we must keep a protection circuit, at least for the short circuit protection should be kept.

A simple fuse or MCB is enough for this purpose. But more important is to keep such a type of protection.

Or DC fuses can be used for DC power line protection.

Depending on different power sources, a line filter circuit can be introduced too. But this line filter is used only in SMPS based systems where the input is AC. The AC supply is filtered for EMI (Electro-Magnetic Interference) and then this power is used for the rest of the circuit.

But for DC to DC or simple low-frequency transformer-based systems, a fuse or MCB is enough.t For the DC circuit, we should use a DC fuse rather than the AC fuse to get proper protection.

Temperature sensor for switching device:

As the temperature of the battery, the temperature of the switching device is also important, especially for the large battery chargers. The switching devices are mostly semiconductor-based like MOSFETs, IGBTs, or BJTs. With temperature rise, these semiconductors draw higher current and get more heated. If a proper cooling system (using a heat sink or cooling fan) is not used, the semiconductor will have a thermal runaway that will damage the device in the end.

NTC type temperature sensor for Heatsink

If the current is not high, a simple cooling fan can be used additionally with a heat sink. But it the current is high, a temperature sensor should be used with the switching MOSFET, IGBT, or BJT. If the temperature is higher than the limit even when the cooling system and heat sink is used the charger circuit should be cut off the switching device until it is cool. This way the charger circuit can be saved from burn out.

MOSFETs and heat sink
Cooling Fan

Also, for small and moderate rated charger circuits, this temperature sensor can be used to operate the cooling system at different speeds to reduce dust collection inside of the system. A cooling system with forced air will collect dust inside of the charger if it runs most of the time. But a smart cooling system can reduce this effect if a temperature monitoring system is available onboard.

Protecting circuits for battery:

Like the input protection, we should provide protection in the output line where the battery is connected. This protections are for

  • Overcurrent
  • Short circuit
  • Wrong polarity and
  • Reverse discharge protection.

Overcurrent and short circuits at the output can be solved using a DC fuse. A suitable rated DC fuse is enough for this purpose.

10A DC fuse

And for the wrong polarity and reverse discharge can be eliminated using a diode.


Diodes are different in current and voltage ratings and sizes. A suitable one should be selected. Some of these diodes may need a heat sink and extra cooling systems depending on the output current. But note that, diodes should not be connected directly in parallel. If the parallel connection is non-avoidable then it should maintain proper current sharing.

Temperature sensing for the battery:

Temperature sensor at battery body

We have seen that if the battery temperature is high, it will reduce battery life. You can read the previous article on this.

That is why a temperature sensor should be introduced for the battery. But for small systems, we can regulate the current in a way to maintain this issue. In large systems, batteries are monitored carefully to reduce damage.

Features for users:

Thus far, we have seen protection circuits. But these are not enough for a battery charger circuit. There should be proper control, indication, and an alarming system to make the device userfriendly.

That is why an input setting should be introduced. This could be either an analog or digital interface. A variable resistor with a knob or some buttons can be used for this purpose.

For indication, LEDs, analog or digital meters, or even LCD displays can be used. But it is up to the designer what type of indication will be used in the system.

For an audio alarming system, a simple buzzer can be used. Any fault condition can be alarmed buzzing this device.


The control circuit:

There is no limited way to design a control circuit but this control circuit should have the following features to design a good battery charger circuit.

  • Analog voltage sensing
  • PWM or pulse generation
  • Proper speed of operation
  • Enough I/Os to combine all sections

Whether the circuit is analog or digital it has to sense the voltage from different sensors (voltage, current, temp.). So the circuit should have this feature. Then the switching may be PWM-based or pulse-based so there has to be a feature to generate that PWM or pulse. Then the operating speed should not be so slow that it takes a long time to respond. A faster response is always beneficial. And in the end, there should be enough Input/Outputs so that all other circuits can be connected with the control circuit.


So we have seen the basic block for a battery charger circuit and an updated block for the same system. Whether it is basic or advanced, we should always design/select a suitable battery charger circuit for operation. A good battery charger can extend the battery life as well as save lots of money in the end.

I hope this project was helpful to you. If you make one for yourself, it will be a great pleasure for me. Anywhere you need help, let me know. Please share this project and subscribe to my blog. Thank you.


Mithun K. Das; B.Sc. in EEE from KUET. Blog: https://labprojectsbd.com


Asimi · September 11, 2020 at 7:03 pm

Thanks you for the new update. I really learnt something tangible today. Your blog is always wonderful. May God continue to increase your Knowledge. Pls sir. There is a question I would like to asked you from previous post on sinewave program. How did you get or calculate the “fb_constant = 0.8” to increase or decrease duty cycle. I have been thinking over and over how did you calculate. Pls. I will be looking forward to your response.

    Mithun K. Das · September 12, 2020 at 3:39 am

    Thanks. It is not so complex that it will take a long time to understand. Here I just presented an example code for learning. You should modify yourself according to your requirement. fb_constant = 0.8 is taken as initial value. check replacing it by any thing from 0 to 1.0 to understand how it works. I hope you’ll get your result as well as learn about it.

      Asimi · September 13, 2020 at 2:30 am

      Ok. Thank you sir.

djalltra · October 25, 2020 at 12:47 pm

feedback constant 0.8 means 80% it represents the percentage increment is decrement value

djalltra · January 16, 2021 at 9:46 am

can you please make a smart battery charger using full bridge switching similar to the ones found in inverters

Leave a Reply

Your email address will not be published. Required fields are marked *