customized battery script for nicer output