Lithium battery charging automatic power off system