We don’t use Fritzing.
Ok… Your design is too simplistic. Nice try, but bad design.
You should not be both charging and draining batteries at the same time. You need some kind of switching mechanism in there so that when there is no power applied the 5V DC/DC switcher is powered from the batteries. When power is applied it should isolate the switcher from the batteries and power it direct from the power input. (I guess it would be fine if you could guarantee 100% that you would never charge it while it’s connected to anything, but that’s not going to be very convenient now is it.)
Designing a good efficient switching regulator is a fine art. There are lots of considerations to the component layout with regards to EMI and ripple reduction that you need to take into account. Component selection (not just the switcher itself, but the support components) is also fairly critical, and you have to understand such things as ESR (Effective Series Resistance) etc to get the right components to do the job properly.
I would recommend an off-the-shelf module. Have a google for the term “UBEC”.
As for the actual charging, there are a number of ways of doing it, depending on how fast you want to charge the batteries, and how complex you want the charger to be. If you don’t mind trickle charging the batteries (leaving them plugged in for >16 hours) then you can do it simply with an LM317T in constant current mode set to 1/10th of the mAh of the batteries. If you want to charge faster, then you will need a charge manager. There’s three types, and they work differently and give different quality results.
- Delta-time: These charge at a high current for a pre-set amount of time. They are simple, but if the batteries are partially charged when you start you will risk over-charging the batteries and they may explode.
- Delta-temperature: A thermistor attached to the batteries monitors the temperature. When they exceed a specified threshold (40°C IIRC) it stops charging.
- Delta-voltage: When the batteries are charge the voltage across them forms a distinct characteristic curve, looking a bit like a nipple, and when it sees that voltage curve it terminates the charging.
1 is the simplest but most unreliable. 3 is the most complex but the safest. None of those three give a good quality charge though. The best charge from the point of view of the batteries is an overnight trickle charge (LM317T method mentioned first). Even if you usually recharge with delta-v it is a good idea to every so often recondition your batteries with an overnight trickle charge.