optimize the battery script