Awesome battery monitor - close the file within the conditional to avoid errors on non-battery-powered systems.