Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,783,010 Members 44,396 Now Online
XDA Developers Android and Mobile Development Forum

[REL: 02/08][APP] xCharge Reboot Options {NO LONGER SUPPORTED}

Tip us?
 
DooMLoRD
Old
(Last edited by DooMLoRD; 21st May 2013 at 08:05 AM.)
#1  
DooMLoRD's Avatar
Recognized Developer - OP
Thanks Meter 38,229
Posts: 13,054
Join Date: Jul 2010
Location: Noida
Angry [REL: 02/08][APP] xCharge Reboot Options {NO LONGER SUPPORTED}

Hey guys I was able to get a script (now an APP) together to reboot into recovery (xRecovery / FreeXperia Recovery) from within the OS.


firstly i would like to thank Bin4ry & Androxyde for the FlashTool and the option to "reboot into xrecovery from flashtool" as this mod/script is based on that..
and tremendouz and wiedz for inspiration...

DO NOT TRY THIS IF U USE DATA2SD... THIS CANNOT WORK, FOR NOW, ALONG WITH DATA2SD...



new features include:
  1. cleaner layout
  2. new UI
  3. working themes!
  4. and u will be entitled to future upgrades


Screenshots:


On X10:




On Xperia 2011 / Other Androids:




if u like the app please buy the paid app to support our work

P.S.: Older versions are available in 2nd post and will be kept for XDA users...


FOR OLDER VERSIONS (which will be kept FREE) please refer to this thread:
http://forum.xda-developers.com/show....php?t=1085896





<OLD FILES | For Reference ONLY>
The Following 46 Users Say Thank You to DooMLoRD For This Useful Post: [ Click to Expand ]
 
sskeleton
Old
#2  
Member
Thanks Meter 5
Posts: 40
Join Date: Apr 2010
Location: Gdańsk
This is great! Good job
 
lzyllp
Old
#3  
lzyllp's Avatar
Senior Member
Thanks Meter 235
Posts: 534
Join Date: Dec 2010
Location: fuzhou

 
DONATE TO ME
Only 2.1?work with CM7?
 
DooMLoRD
Old
(Last edited by DooMLoRD; 27th May 2011 at 08:44 AM.)
#4  
DooMLoRD's Avatar
Recognized Developer - OP
Thanks Meter 38,229
Posts: 13,054
Join Date: Jul 2010
Location: Noida
Exclamation Only for reference

<OLD FILES>

FOLLOWING INFORMATION IS KEPT ONLY FOR REFERENCE
NO NEED TO USE ANY OF THE FOLLOWING UPDATE.ZIPS








[*] UPDATE: links to a few update.zip files which can be flashed via recovery are below.[*]


(UNIVERSAL FOR ALL XPERIA ANROIDS, ANY RECOVERY)
[ADDED]: Universal flashable update.zip for ALL ROMs / ALL Xperia Android devices with ANY Recovery


(THESE ARE FOR X10 ONLY)
[ADDED]: Flashable update.zip for 2.1 ROMs based on SE stock FW with xRecovery 0.3-release
[ADDED]: Flashable update.zip for 2.1 ROMs based on SE stock FW with xRecovery installed through Flashtool v0.2.8
[ADDED]: Flashable update.zip for 2.2 ROMs based on FreeX10-beta4
[ADDED]: Flashable update.zip for 2.3 ROMs based on CM7RC2 v008 to v010a
[ADDED]: Universal flashable update.zip for ALL ROMs with xRecovery installed through Flashtool beta v0.2.9


[USER TESTS]:
Mortyx10 has reported that the flashable update.zip for 2.2 ROMs based on FreeX10-beta4 works on Wolf CM6 V4.4
Xperia84 has reported that the flashable update.zip for 2.2 ROMs based on FreeX10-beta4 works on Wolf CM6.1.3 V4.5.7


PLEASE MAKE A FULL XRECOVERY/NANDROID BACKUP BEFORE TRYING ANY SYSTEM MODIFICATIONS LIKE THIS



[AUTOMATED WAY] (Difficulty: Medium)


Flashable update.zips

(UNIVERSAL FOR ALL XPERIA ANROIDS, ANY RECOVERY)

Universal flashable update.zip for ALL ROMs / ALL Xperia Android devices with ANY Recovery



<OLD FILES>
(ONLY FOR X10)

Flashable update.zip for 2.1 ROMs based on SE stock FW with xRecovery 0.3-release
Flashable update.zip for 2.1 ROMs based on SE stock FW with xRecovery installed through Flashtool v0.2.8
Flashable update.zip for 2.2 ROMs based on FreeX10-beta4 [Thank you JimmyX10 for helping out with testing this]
Flashable update.zip for 2.3 ROMs ROMs based on CM7RC2 v008 to v010a [Thank you bazji, tremendouz, depulle87, lzyllp for helping out with testing this]
Universal flashable update.zip for ALL ROMs with xRecovery installed through Flashtool beta v0.2.9






[OLD INFO] | [USE ONLY IF THE AUTOMATED WAY DOESNT WORK] (Difficulty: Hard)



Additionally please make certain that u can use flashtool to flash a stock FW incase u run into any problems and that the device is fairly charged >50% battery before trying this.

*** I have tested it to be working on:
2.3 (CM7RC2-v010 & CM7RC2-v010a)
2.2 (freex10-beta4)
2.1 (FW 2.1.0.435) [should also work with other 2.1 FW]
***


* warning *
this requires some advanced knowledge on how to modify system files, all step required are mentioned here, though if u are uncomfortable with it i will be attaching some pre-modified file for vanilla roms, which should work with most custom roms. in case they dont work u can just upload the 'chargemon' file located in /system/bin/ here and i will repost it the necessary modifications.



[MANUAL WAY]


[step 1] Modify boot hijack file 'chargemon'
(not required if u are on 2.1 stock se rom and have used Flashtool 0.2.8 to install xrecovery, in which case these modifications will already be in place)
- this file is located in /system/bin/
- make a backup of this file, on the sdcard, before editing
- i would recommend using Root Explorer to navigate to this file, mount the partition as r/w (click "Mount R/W" in upper right hand corner)
- long press on the 'chargemon' file this will bring up a menu and select "Open in Text Editor"
- find the following lines of text
Code:
	if [ -s /dev/keycheck ]
	then
- and modify it to the following
Code:
	if [ -s /dev/keycheck -o -f /data/local/tmp/flashtool ]
	then

	  # remove 'reboot into xrec' file
	  rm -f /data/local/tmp/flashtool
*** ONLY for those who have offline charging enabled in their roms (if u are uncertain about this just check if there is a file named 'charger' in /system/bin/ , most custom roms will have this feature) i have done some additional thing here, i have moved the placement of the command for the offline-charger file 'charger' to the beginning of this script so that even if anyone get stuck up at boot atleast they will be able to charge the device without getting into the OS. also please check for any other occurrence of the command '/system/bin/charger' anywhere else in the file, if there is another then just put a # in front of it like '# /system/bin/charger' ***
*** if u dont have the /system/bin/charger file then dont bother with the following code ***
Code:
       /system/bin/charger

	if [ -s /dev/keycheck -o -f /data/local/tmp/flashtool ]
	then

	  # remove 'reboot into xrec' file
	  rm -f /data/local/tmp/flashtool
- once u finish editing click on menu button and "Save & Exit"

- now u need to check the permissions of the 'chargemon' file. if u using Root Explorer navigate to '/system/bin/' then "mount r/w" and long press on 'chargemon' file and select 'Permissions'... make sure the permissions are as follows:



- after this i would suggest u restart the device to check if u are able to access xreovery the normal way (repeatedly pressing/tapping 'back' key when u see SE text logo) and if the device boot up into the OS without any issue
- incase everything goes well make a backup of this modified 'chargemon' file too, in case u have any problems put up a post here
* i will also be attaching some pre-modified generic files for vanilla roms, which should work with most custom roms. *



[step 2] the actual Reboot into xRecovery script
- u need to install the following app GScript Lite, our fellow XDA member rogro82 has posted this tool here
- after installing, launch the app, click on menu button, "Add Script"..
- fill up the text boxes as follows:



- u need to enter some name in the smaller textbox and the following into the large textbox:
Code:
touch /data/local/tmp/flashtool
reboot
* some custom roms are not permitting reboot command if SU rights are not there... u need to make sure that the option "Need SU?" is checked (ticked) else the device wont be able to reboot from the script... *

- now save the script
- u can create a shortcut on the homescreen to GScipt Lite and select the reboot into xrecovery script



- if u try running the script a popup for SU permissions might come up, this will only come the first time its run, select "Allow" and then ur device will reboot into xrecovery...
- thats it! now whenever u want to reboot into xrecovery just launch the shortcut!!!


also if anyone could integrate this into the Reboot options in Power menu it would be great for everyone!!!

may be modders/themers can add this into their reboot options of power menu in their themes...





for specific threads of other Xperia android devices go HERE
 
lzyllp
Old
(Last edited by lzyllp; 19th March 2011 at 12:45 PM.)
#5  
lzyllp's Avatar
Senior Member
Thanks Meter 235
Posts: 534
Join Date: Dec 2010
Location: fuzhou

 
DONATE TO ME
Quote:
Originally Posted by DooMLoRD View Post
It will work with all roms!
I can't into the xrecovery and still into system when i run it(J's CM7)
 
The Gingerbread Man
Old
(Last edited by The Gingerbread Man; 19th March 2011 at 01:06 PM.)
#6  
The Gingerbread Man's Avatar
Recognized Contributor
Thanks Meter 3,888
Posts: 8,011
Join Date: Sep 2010
Location: Gloucester
Great idea! This would be even better if you could make it into some kind of apk to be able to do the nessesary changes?


Edit

I misunderstood. So for now reboot to recovery through power menu is still not possible? It would be great if it would be possible to make reboot to recovery possible through an apk or a newer modified recovery menu.

Sent from my X10 using XDA Premium App
The Following User Says Thank You to The Gingerbread Man For This Useful Post: [ Click to Expand ]
 
MrHassell
Old
#7  
Senior Member
Thanks Meter 245
Posts: 391
Join Date: Dec 2010
Location: Melbourne

 
DONATE TO ME
Well done! :) xlnt
You like my work? Feel free to buy me a cool beer
 
DooMLoRD
Old
(Last edited by DooMLoRD; 19th March 2011 at 08:39 PM.)
#8  
DooMLoRD's Avatar
Recognized Developer - OP
Thanks Meter 38,229
Posts: 13,054
Join Date: Jul 2010
Location: Noida
Quote:
Originally Posted by lzyllp View Post
I can't into the xrecovery and still into system when i run it(J's CM7)
hmm i have tested it with freex10-beta4... hmm ok... which version of CM7 rom r u using?
i am flashing CM7RC2 v010 right now for testing it...


in any case upload ur 'chargemon' file from /system/bin/ here... i will do the necessary changes...
The Following User Says Thank You to DooMLoRD For This Useful Post: [ Click to Expand ]
 
DooMLoRD
Old
#9  
DooMLoRD's Avatar
Recognized Developer - OP
Thanks Meter 38,229
Posts: 13,054
Join Date: Jul 2010
Location: Noida
Quote:
Originally Posted by steve.adams.x10 View Post
Great idea! This would be even better if you could make it into some kind of apk to be able to do the nessesary changes?

Sent from my X10 using XDA Premium App
thanks dude....

the thing is i dont know how to make apps (apk)... if someone can create the apk it will be great!!!
 
lzyllp
Old
#10  
lzyllp's Avatar
Senior Member
Thanks Meter 235
Posts: 534
Join Date: Dec 2010
Location: fuzhou

 
DONATE TO ME
Quote:
Originally Posted by DooMLoRD View Post
hmm i have tested it with freex10-beta4... hmm ok... which version of CM7 rom r u using?
i am flashing CM7RC2 v010 right now for testing it...

but as far as i can tell it should work on all roms...

in any case upload ur 'chargemon' file from /system/bin/ here... i will do the necessary changes...
010 i use.I think the xrecovery have some change in CM7.

THREAD CLOSED
Subscribe
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes