How to stop an android device from being charged programmatically?

后端 未结 9 698
醉酒成梦
醉酒成梦 2020-12-23 13:20

Is there an Android API for stop charging even though physically the charging is on?

9条回答
  •  天涯浪人
    2020-12-23 14:01

    Reading previous answers, it looks like there's no way to do this exclusively in software. However, it should be relatively easy to do it with a little hardware help - i.e. by using any Bluetooth- or WiFi-enabled smart electrical switch with open API. The phone could then switch the charger on or off programmatically whenever it feels like it.

提交回复
热议问题