有没有办法自动打开手机电源 [英] Is there a way to auto-power on the phone

查看:194
本文介绍了有没有办法自动打开手机电源的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望做一个自定义计时器应用程序。我希望它可以启动和关闭。我搜索,发现,启动它需要root权限。任何人都可以给我一些线索来完成这个?

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?

编辑:换句话说:它似乎很高兴有一个应用程序自动开机或关机的手机,
确实硬件支持?该应用程序只是为用户设定的时间时,打开手机或
没电了。如何打开手机时,它是断电?如果我们供电
从我们的电话或取出电池,时钟仍然显示了我们一个正确的
当我们接通电源。和闹钟也适用,我们当电源
关了手机。所以我觉得也可以自动开机的
电话

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 it 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.

除非您在Android内核中一个非常非常奇怪,大概神奇的黑客。看看main.c中的/内核/电源/

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

好吧,因为我已经发布了一个答案,这里有关于Android的电源管理功能的一些资源:

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

这篇关于有没有办法自动打开手机电源的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆