开发者

Is there a way to auto-power on the phone

开发者 https://www.devze.com 2023-03-11 14:14 出处:网络
I want to do a custom Timer app. I want it can start up and shutdown. I searched and found that starting it up needs root rights.Can anyone give me some clue to finish this?

I want to do a custom Timer app. I want it can start up and shutdown. I searched and found that starting it up needs root rights. Can anyone give me some clue to finish this?

Edit: in other words:It seems nice to have an app to auto power on or power off the phone, does the hardware support?The app is only for users to set time when to turn on the phone or power off. How to turn on the phone when it is power off? If we power off our phone or take out battery, the clock still show us a correct time when we power i开发者_StackOverflowt on. And the alarm clock also works when we power off the phone. So I think it is also possible to auto-power on the phone


I highly doubt you can do this.

Unless you make a very very weird and probably magical hack in the android kernel. Look at main.c in /kernel/power/

Well since I've posted an answer, here are some resources about android's power management features:

  • Linux Kernel and Android Suspend/Resume
  • Power Mgmt from the android kernel
0

精彩评论

暂无评论...
验证码 换一张
取 消