how to set battery % in android mobile using adb command?
Asked Answered
F

2

9

If suppose 40% battery is available in my android device, what is the adb command to set the battery % to 30? Using adb command can set battery % only to lower level / higher level also?

Fletafletch answered 23/4, 2018 at 13:34 Comment(0)
D
24

You can use following command:

adb shell dumpsys battery set level 30

Discommodity answered 23/4, 2018 at 14:20 Comment(2)
Using adb command can set battery % only to lower level / higher level also?Fletafletch
Works with Android Terminal emulator, after su - inside x86 emulated terminal on Android 9.Forgo
I
5

Use the following command:

adb shell dumpsys battery set level 30

And use this to reset the level:

adb shell dumpsys battery reset

Incorporable answered 10/2, 2022 at 3:49 Comment(2)
Thanks I set my battery to 420% and could not figure out how to fix it until I saw your postBloodmobile
Love to hear thatIncorporable

© 2022 - 2024 — McMap. All rights reserved.