Charging batteries in series when they are connected in parallel in the circuit

battery-charging

I'm new to electronics and I'm trying to build a charging circuit for NiMH batteries. There are four batteries in total. Two are in series, and the other two are in series. Then these are connected in parallel. I need to be able to switch them all to series when I plug in the USB for charging. I have an idea and please tell me if it will work. If not could you give me a way, thanks.

schematic

simulate this circuit – Schematic created using CircuitLab


The batteries i'm using are the Eneloop xx which are 1.2v so the USB would work because they add up to 4.8v. I was doing research about charging nimh batteries and found out that it is best to charge them in series and not parallel. So if this wont work than could you help me figure out what will switch it to series?

Best Answer

Your circuit doesn't do what you want it to - both batteries are permanently wired in parallel, as is the charger. The diode does nothing.

You probably don't want to charge them in series from USB anyway, because you would need at least 5.6V (1.4V/cell x 4 cells) but you only have 5.0V available. Charging in parallel can be done efficiently with a switch-mode current regulator, or just a resistor to limit current (and perhaps a blocking diode to prevent discharging into the USB port when not powered) if you don't mind a lower charge rate.