• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Circuit Ideas for You

Get free circuit ideas online.

  • Home
  • Privacy Policy
  • About
Home » Arduino Battery Charger Circuit

Arduino Battery Charger Circuit

Last updated on 4 December 2025 by Admin-Lavi Leave a Comment

This article show how to make a simple Arduino Battery Charger Circuit.

Charger stop and start charging using MOSFET.

Arduino read battery temperature with TMP36 sensor and decide safe charging.

Circuit is simple and work with basic components.

Arduino Coding:

int tempPin = A1;
int mosfetPin = 9;
float voltage = 0;
float temperatureC = 0;

void setup() {
pinMode(mosfetPin, OUTPUT);
digitalWrite(mosfetPin, LOW);
}

void loop() {
int sensorValue = analogRead(tempPin);
voltage = sensorValue * (5.0 / 1023.0);
temperatureC = (voltage - 0.5) * 100.0;

if (temperatureC < 40) {
digitalWrite(mosfetPin, HIGH);
} else {
digitalWrite(mosfetPin, LOW);
}

delay(500);
}

Code Explanation:

  • tempPin store A1 pin number.
  • mosfetPin store D9 pin number.
  • Arduino read analog value from TMP36.
  • Convert reading to voltage using 5 divided by 1023.
  • TMP36 give 0.5 volt at 0 degree so subtract 0.5.
  • Multiply by 100 to get degree Celsius.
  • If temperature is less than 40C then MOSFET is ON and battery charges.
  • If temperature is more than 40C then MOSFET is OFF and battery stops charging.

Circuit Working:

Arduino Battery Charger Circuit Diagram

Parts List:

Part NameSpecificationQty
Resistors10k ,10Ω 10 watt1 each
CapacitorElectrolytic 1µF 25V1
SemiconductorsMOSFET IRF5101
Temperature Sensor TMP361
Battery Holder AA Size1
Rechargeable Battery NiMH AA1
Arduino Uno1

Arduino get 5 volt from USB power.

Temperature sensor TMP36 give analog voltage to Arduino pin A1.

Arduino read this value.

If temperature is below safe value then Arduino output goes HIGH to gate of IRF510.

IRF510 switches ON and allow current to battery through R2 resistor.

Capacitor C1 make sensor reading clean and stable.

If temperature go high then Arduino output goes LOW and MOSFET switches OFF and charging stops.

Battery connect to circuit using two wires as shown in circuit diagram.

Ground of Arduino, battery, sensor MOSFET all are common.

How to Build:

To build a Arduino Battery Charger Circuit follow the below steps for connections:

  • Assemble all the parts as shown in circuit diagram.
  • Connect Arduino ground to battery ground.
  • Connect resistor R1 to gate pin of MOSFET
  • Connect R2 between battery positive and MOSFET drain.
  • Connect positive pin of capacitor C1 between R1 resistor and gate pin of MOSFET
  • And negative pin of capacitor C1 connect to GND.
  • Connect MOSFET source to ground.
  • Connect sensor TMP36 pins Vcc to 5V, Ground pin to GND, and Vout pin A1 pin of Arduino.
  • Connect MOSFET gate to D9 pin.
  • AA Battery Holder connect one end to Battery positive (+)
  • AA Battery Holder connect one end to Battery negative (–).

Conclusion:

This project is about Arduino Battery Charger Circuit.

Temperature protection make safe charging.

Circuit is easy to build and understand.

Can be improved later with voltage sensing, current sensing, LCD display or solar charging.

This basic design is good for small learning and DIY purpose.

References:

Arduino battery charging circuit

Filed Under: Arduino Projects, Battery Charger Circuits

About Admin-Lavi

Lavi is a B.Tech electronics engineer with a passion for designing new electronic circuits. Do you have questions regarding the circuit diagrams presented on this blog? Feel free to comment and solve your queries with quick replies

Previous Post: « Simple 12V Battery Charger Circuit using TIP41 Transistor
Next Post: USB Powered Small Battery Charger Circuit »

Reader Interactions

Leave a Reply Cancel reply

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

Primary Sidebar




Categories

  • Alarm Circuits (45)
  • Amplifier Circuits (67)
  • Arduino Projects (99)
  • Audio Circuits (114)
  • Automobile Circuits (19)
  • Battery Charger Circuits (65)
  • Free Energy (13)
  • Heater and Temperature Controllers (13)
  • High Voltage (1)
  • Indicator Circuits (45)
  • Inverter Circuits (20)
  • IoT projects (1)
  • LDR Circuits (26)
  • LED and Lamps (148)
  • Meters and Testers (30)
  • Motor Controllers (22)
  • Oscillator Circuits (39)
  • Power Supply Circuits (104)
  • Remote Control Circuits (10)
  • Security and Protection (29)
  • Sensors and Detectors (126)
  • Solar Circuits (29)
  • Timer Circuits (41)
  • Transistor Circuits (87)
  • Transmitter Circuit (17)
  • Tutorials (8)
  • Water Level Controller (6)

Recent Posts

  • 12V Battery Low Voltage Alarm Circuit
  • Low Voltage Alert Circuit for 9V Battery
  • Digital Code Lock Circuit using IC 4017
  • Darkness Activated LED Circuit
  • Fan Start 10 Second Delay Timer Circuit

Recent Comments

  1. TDHofstetter on DIY Variable Power Supply Circuit using Arduino
  2. feathbuff on Simple Micro Ampere Meter Circuit
  3. Admin-Lavi on Simple School Project Multimeter Circuit
  4. choke on Simple School Project Multimeter Circuit
  5. Admin-Lavi on Analog to Digital Converter Circuit using IC 555

Copyright © 2026 | New Circuit Ideas