Modify the kernel so that the Android system will never sleep and lock the screen

Source: Internet
Author: User

From: http://hi.baidu.com/nignt_yoco/item/b6f173700c3df328d7a89cc3

The procedure is as follows:

1. Change the value of def_screen_off_timeout in the ults. xml file under the/frameworks/base/packages/settingsprovider/RES/values directory to-1, that is

1 <Integer name ="Def_screen_off_timeout">-1</Integer>

The screen will never sleep. (But at last, I burned it onto the board. I didn't know whether it was because I set the display or something at the beginning. I found that the screen would sleep and become dark...)

2. About 191st lines in the keyguardviewmediator. Java file under the/frameworks/base/policy/src/COM/Android/Internal/policy/impl directory are modified as follows:

12345 /** * external apps (like the phone app) can tell us to disable the keygaurd. */ private Boolean mexternallyenabled = false ;


RecompileProgram.


Later I found that the system file was burned and written, as if the kernel was not dormant ~~~ (This is what I need)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.