Have you considered using one of these?
http://www.modparts.co.uk/boards/381-evolv-dna75-0638183554951.html
This would handle all the complicated TC and battery management. Just an idea.
http://www.modparts.co.uk/boards/381-evolv-dna75-0638183554951.html
This would handle all the complicated TC and battery management. Just an idea.