Battery discharge circuit function