[SCRIPT/MOD] Deodexed files for Bell (06/05/11) - Atrix 4G Android Development

If you are looking for how to get back to stock Bell, go HERE.​
Disclaimer: I have not tested this on anything but my phone. This is a development section of a hacking website. Make backups. Know what you are doing.​
Credits:
Brut.all for apktool
edgan for 2nd-init
designgears for aroot inspiration.
xda for being a source of info.
​
Requirements:
Windows 7 or Ubuntu 10.10+ (10.10 and 11.04 tested)
Java installed. (For applymods, it uses apktool)
Running Phone, not in recovery mode, etc.
Tips:
Don't factory reset please if something goes wrong, it just erases your personal settings, it doesn't write to the system partition. It also deletes your data partition, making it harder to get back to stock.
Early usb mode, turn your phone on while holding down the lower volume button, when it says fastboot, release and press volume down repeatedly until it says early usb enumeration, then press up volume. It takes 30 seconds or so before adb is ready.
​
Version 9:
Download it here.
What's new:
Added support for 2nd-int (WIP, tested on stock Bell only)
shsu updated to allow a super user to become a super user, acts like sh in that case.
fixed linux install_recovery.sh and uninstall_recovery.sh scripts to use shsu instead of remaining using su. Ditto with ApplyMods.sh
Boot animation now smaller, using jpegs instead of png files, no difference in appearance.
​
Version 8:
Download it here.
What's new:
Added full phone backup and full restore phone options to the menu. It will download a backup if there is none found.
root script more universal, tries psneuter first, then gingerbreak.
Early usb recovery updated, now uses a tmpfs for system, also mounts /sdcard and /sdcard-ext.
Deodexed French 2.1.1 files incorporated.
Misc fixes
​
Version 7:
What's new:
New Menu script for windows and linux in the top folder, double click Menu and enter options.
ApplyMods and other scripts updated to use /data/local/tmp/system, this means I can update system.tar.gz and add folders to be copied into system.
Early USB enumeration recovery option. (experimental but useful as is)
Fixed bugs in windows scripts. Can't get user input from bat file while in a parenthesis block apparently.
Bloat backed up to sdcard now
root and unroot scripts updated with more prompts for rebooting phone.
​
Version 6:
What's new:
Support for Telstra 1.4.2.
ApplyMods can create signed update.zips now, Create_update.bat updated. both using basic ready made scripts in main bin folder instead of creating them on the fly, CR LF issues.
Updated root and unroot scripts, more fool proofing, has to be Bell stock firmware (psneuter doesn't work on telstra).
Includes basic boot animation, and mod for Bell apn on telstra firmware. (Have to reset to default under access point names in settings.)
transparent status bar, yellow tinted white for text color, matches front buttons somewhat.
​
Version 5.1:
Features:
Works under Linux and Windows 7
Includes root and no ads scripts
Patch system for applying modifications.
What's new:
New scripts for doing mods, fixes issues with patch 9 images.
Updated root and unroot scripts, more fool proofing.
New RestoreSystemPartition script
Custom apktool for more [hopefully] bug free installations.
How to use:
Extract archive, keeping folder structure intact.
run a command prompt/terminal (There is a link to one in the windows folder)
run root.bat or root.sh from the linux or windows folders, depending on which one you are using.
Turn the phone off after that is done and turn it back on again.
The rest of the scripts shouldn't be run with psneuter affecting the phone.
run ApplyMods.bat (.sh) [OPTIONAL] This applies webtop hack and translucent status bar, translucent notification drop down, etc. Select update system.tar.gz.
run install_bell_deodex.bat or .sh
System image of stock Bell.
Mirror of above​
Cheers!

Very nice! Looks good!

Will try this when I get home
Sent from my Motorola Olympus

So what is the benefit of this? Will I be able to theme my device with some of the themes that are available? Or should I play it safe and wait for a bell. Sbf to leak before I try anything and brick my phone again lol thanks in advance
EDIT: i see that you have included soft_brick.bat is it the same as this one http://forum.xda-developers.com/showthread.php?t=982859 because that one did not work for me thanks again
Sent from my MB860 using XDA Premium App

cool, i'll try this tomorrow when i don't still have a ****load to do and only 5 hours to sleep
nice to see a Bell dev here!

Also I just wanted to say major props for the crazy awesome idea of doing over-the-air download and installation. Really smart and original.

Atrices, just so you know
NFHimself said:
Hi,
(What is the plural of Atrix?)
Click to expand...
Click to collapse

Can I run this on my mac? Sorry relatively new to adb
Sent from my Motorola Olympus

you could run it on a mac, just had to edit the script a bit.

Hi,
So what is the benefit of this? Will I be able to theme my device with some of the themes that are available? Or should I play it safe and wait for a bell. Sbf to leak before I try anything and brick my phone again lol thanks in advance
Click to expand...
Click to collapse
I wouldn't try theming with ATT files, I would take what was done to them and apply them myself to the deodexed files here. There may or may not be differences that are not obvious. I am never really sure if there is any benefit to this stuff, it's fun to do, about it.
EDIT: i see that you have included soft_brick.bat is it the same as this one http://forum.xda-developers.com/showthread.php?t=982859 because that one did not work for me thanks again
Click to expand...
Click to collapse
The soft_brick.bat script is specific to the folders I am using for transferring data to /system/app and /system/framework. It tries to get root via psneuter, mounts system read write, deletes dalvik-cache files, and tries to copy the files already on the phone to the right folders. It could be that just one file caused the phone to crash mid copy and copying it again will fix things. This avoids trying to do a usb data transfer of all the files which you don't have time to do otherwise. I was also thinking that install-recovery.sh would be a good place to do this, (and then clobber it later with the init.d hack) but I couldn't find setprop and I wasn't in need enough to select a file to use as a semaphore.
Can I run this on my mac? Sorry relatively new to adb
Click to expand...
Click to collapse
It would be easier to do it all from a sh script really, and that would likely be more compatible with a Mac.
Also I just wanted to say major props for the crazy awesome idea of doing over-the-air download and installation. Really smart and original.
Click to expand...
Click to collapse
Thanks!
Cheers!

maledyris said:
Atrices, just so you know
Click to expand...
Click to collapse
Thanks, a lot, really, 10 chars..

How do I recover from a softbrick from this? Thanks.

Before anything is done, all the files are extracted to /data/local/tmp/app and /data/local/tmp/framework. If you run into problems put the phone into fastboot/early usb enumeration mode (see here) and run soft_brick.bat (.sh for linux)
Quote:
A soft brick, in this case, is when you make a bad edit to your framework files and the phone won't fully boot and starts flashing a red LED at you.
There is one catch, you only get about 1-2min to do all of this before the phone reboots on its own. If that happens, do SuperOneClick steps again and continue where you left off. Better yet, build a script to do it all for you
Power off your device
Enter Fastboot:
Hold Volume down + power until you see Fastboot at the top left
Use volume down to scroll down to "Early USB Enumeration" (only shows one item at a time, if you pass it, keep going down, up selects)
Press Volume up to select​

This is the message I get when i run the batch file.
This is of course when invoking Early USB Enumeration.
Wait for the count down to finish ...
'TIMEOUT' is not recognized as an internal or external command,
operable program or batch file.
clearing Dalvik cache..
rm failed for /data/dalvik-cache/[email protected]*.dex, No such file or directory
rm failed for /data/dalvik-cache/[email protected]*.dex, No such file or director
y
rm failed for /data/dalvik-cache/[email protected]*.odex, No such file or directory
rm failed for /data/dalvik-cache/[email protected]*.odex, No such file or directo
ry
reinstalling apps
cp: cannot stat '/data/local/tmp/app/*': No such file or directory
reinstalling framework..
cp: cannot stat '/data/local/tmp/framework/*': No such file or directory
done.

The timeout message means you are running a version of windows without timeout, see adeo thread.
The lines for rm just mean there are no files to delete in the Dalvik-cache, which is normal, you should see that the second time around.
The cp lines are saying that there are no files in /data/local/tmp/app (/framework).
So, that's unusual, in order to get soft bricked using my script you would to have copied files from /data/local/tmp to /system, and if you are bricked would be unable to delete the files afterword.
sequence:
cd /system
cp /data/local/tmp/app/* app/
sync
reboot now
**brick**
So, how are the /data/local/tmp/app files being deleted?

No clue. I'm not sure what to do here? Is my phone permanently bricked? Any other way to recover from this? The one thing that could have gone wrong is I tried installing from my behind my works firewall. Maybe I could not download the proper files.

No, you are soft bricked, you only made a change (that I know of) in system files.
Were you rooted before you tried this?
If you copy the soft_brick.bat files and change the last line to be adb.exe shell ls -R /data/local/tmp, what do you get?
Basically, it sounds like to need to get the files copied over to data/local/tmp, how they are missing/inaccessible is odd. So, create a script to copy the files over bit by bit, might take a while but it should be able to be done.
EDIT:
Do this:
from command prompt:
adb.exe shell ./data/local/tmp/psneuter
wait a few seconds
type this:
adb shell ls -l -R /data/local/tmp
if psneuter fails, it isn't in /data/local/tmp, which is also odd.

I was rooted before this. So I should attempt all these commands while Early USB Enumeration right? That doesn't give me much time Lol.

OK, here's the output.
C:\bell_deodex>adb.exe shell ./data/local/tmp/psneuter
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
property service neutered.
killing adbd. (should restart in a second or two)
C:\bell_deodex>adb shell ls -l -R /data/local/tmp
/data/local/tmp:
-rwxr-xr-x root root 585731 2011-01-09 02:02 psneuter
-rw-r--r-- mot_tcmd mot_tcmd 4 2011-03-30 21:00 ap_tcmd.pid
C:\bell_deodex>^A

And sorry to be a pain. How would I create the script? What are the files that need to be copied? Are they included in your script?

Related

[GUIDE] All Tattoo questions and answers see here (from A to Z)!

Hi,
this thread is meant as a starting point for every kind of questions. I will write everything I know into this thread and update it (hopefully) frequently
Here are the topics handled for now (if you have any other questions you want to have answered you can PM me, so I can try to handle it if I know the solution and add this to my to do list in point 5!!! ):
1. How can I root my phone
1.1 General information/Basic adb-commands
1.2 Do I have to create a goldcard?
1.3 Tools you need
1.4 The automated way
1.5 The manual way (recommended by the author)
1.6 Problems and (hopefully good) solutions
1.7 References
2. Flashing images/ROMs
2.1 What is a recovery image
2.2 What is a boot image
2.3 How to flash/tools needed
2.3.1 Creating a Goldcard
2.4 Where can I get an overview of the existing ROMs?
2.5 Problems during flashing and solutions
2.6 References
3. Information about the Tattoo/Useful stuff
3.1 How to install busybox?
3.2 Can it perform multitouch?
3.3 How to increase battery life?
3.4 Using own ringtones for calls/sms
3.5 How to disable data transfer with a custom ROM?
3.6 How to make the Tattoo ring louder?
3.7 How to replace the home screen?
3.8 Disabling xxx-synchronisation with Google-servers
3.9 Backing up apk's and data to your PC
3.10 How to enable more languages on my mobile?
3.11 How to manually delete system apks? Alternatively with GUI?
4. Dev-Goodies
4.1 Modifying update.zips and resigning them
4.2 Modifying resources in apk-files and resigning them
4.3 Installing apks via adb for getting exact error codes if installation fails
4.4 Everything related to ROM cooking
5. Things I will do better in this thread due to user request
Please note: I won't be giving tutorials about Android-apps usage beside the one mentioned in my tutorial!
Let's start now:
1. How can I root my phone?
1.1 General information/Basic adb-commands
Rooting a phone enables you to do things, which normally aren't possible for the average user like:
- Removing apps which were preinstalled by the provider (like Orange, Vodafone, etc.). My Tattoo had Vodafone apps for buying music and other sh*t, which was installed on the system partition (to which a "normal" user has no rights to write to, including deleting).
The Tattoo was successfully rooted by a bunch of guys here, namely -bm-, mainfram3 and Coburn64 (maybe, I don't remember quite correctly ). Also the Tattoo was the first phone having a security mechanism hindering a user to mount the filesystems as read/write, which had to be overridden by remapping the read only memory region to a read/write one. This is done by the module Tattoo-hack.ko, also made by mainfram3. He also created the first boot.img, which enabled su directly from adb and loading Tattoo-hack directly from boot on.
A few words about adb:
ADB is a tool for communicating from the PC with the mobile phone. For this a service is running on the phone enabling the communication via Terminal Emulator. Here are the most useful adb-commands:
Code:
adb push localFileFromPC /path/on/mobilephone
-> pushes a file "localFileFromPC" to a specified location on the phone
adb pull /path/to/file pathFromPC
-> receives a file from the phone and stores it to "pathFromPC"
adb remount
-> This is only possible in custom ROMs, remounts the file system to r/w automatically
adb shell "command"
-> executes "command" and returns to the computer shell
adb shell
-> opens a shell session on the phone (from here on you have to be very careful! Also you can execute now normal linux commands like rm, mv, ls, chmod and so on, but not cp (this can done through busybox)). You will have to use this more often, so get used to it ;)
1.2 Do I have to create a goldcard?
I read this question quite often. For rooting, you don't need it, but for SIM-locked phones you can't flash custom unbranded ROMs (I think).
A guide to create a goldcard follow this link: http://forum.xda-developers.com/showpost.php?p=5179788&postcount=1 (thanks to MiSSigNNo to this point)
1.3 Tools you need
A complete set of tools can be found here Feel free to mirror it:
http://rapidshare.com/files/403766494/Tattoo.rar.html
This package contains:
- adb binaries for Windows (sorry Linux users )
- su (Please note: use the su-binary attached in this post, not the one in the archive!!!!!)
- m7 exploit
- Amon_RA recovery.img
- mainfram3 boot.img
- flash_image binary
- tattoo-hack.ko
1.4 The automated way
This method was created by maverixx and can be found here. This basically consists of a package doing everything you need by itself. It roots the phone and flashes maverixx recovery.img, which (no offense) I don't like as much as I like Amon_RA's one!). Just click the batchfile and it does the rest (you have to connect your phone via USB to your PC though ).
If you want to use the automated way, but flashing Amon_RA's recovery, just replace the recovery.img from maverixx' package with the recovery.img provided in my archive file (see 1.3 for the link).
In my time here I noticed quite a few users experiencing problems either with a fully functional su or with the recovery image not flashing certain update.zip packages. It seems to be a matter of luck.
1.5 The manual way (recommended by the author)
I personally like what is done when and how, that's why I recommend the manual way. So let's get down to business Let's see if you know all the adb-commands I wrote here:
1. Let's say you have everything unpacked into C:\Tattoo
2. In your terminal (on your PC) type:
- adb shell "mkdir /data/local/bin" (if it returns an error it means that the directory already exists, just proceed)
- adb push m7 /data/local/bin/
- adb push su /data/local/bin/
- adb push flash_image /data/local/bin/
- adb push tattoo-hack.ko /data/local/bin/
- adb push recovery.img /sdcard
- adb push boot.img /sdcard
3. We have every needed file on the phone now. Type now (we are still in your terminal):
- adb shell
$ cd /data/local/bin
$ chmod 766 m7 (I don't retain this step as mandatory, so if this process fails, just proceed)
$ while ./m7 ; do : ; done
lots of text until you see something like "wrote shell code", press enter 2 or 3 times enter to see:
#
4. Then perform this:
- # export LD_LIBRARY_PATH=/system/lib
- # export PATH=/system/bin
- # insmod ./tattoo-hack.ko
- # mount -o rw,remount /dev/block/mtdblock5 /data
- # mount -o rw,remount /dev/block/mtdblock3 /system
- # cat ./su > /system/bin/su
- # chmod 4755 /system/bin/su
- # chmod 755 ./flash_image
Click to expand...
Click to collapse
Questions?
1.6 Problems and (hopefully good) solutions
Q: How do I execute my command line tool?
A: On your Windows host, go to Start->Run...->type "cmd"
Q: Where is my adb? When I type it in my shell it says that it was not found!
A: The adb binary is found in the archive I supplied above or in the Google SDK. As my archive-file is quite smaller than the Google SDK you should take mine. Let's suppose your adb binary is unpacked in C:\Tattoo, then type:
Code:
Your\Current\Location> cd C:\Tattoo
C:\Tattoo> adb <command>
Q: adb says "error: device not found" when I try to launch the shell on the phone!
A: Connect the phone with the usb cable and make sure the sd card is not mounted as drive on your PC!!!
Q: When I want to copy something the phone returns that "cp" is not found! Also when I try to move a file, it says "cross-link device".
A: Well, copying from one partition to another is only possible either via busybox or via
Code:
cat file > /location/filename
Example:
cp /data/su /system/bin
is realized by typing
cat /data/su > /system/bin/su
Also make sure that system is r/w!!!
Q: flash_image returns write errors when flashing recovery/boot image!
A:
For boot: Try to redo the flash procedure
For recovery: Note that you can't flash the same recovery.img as the one already installed, so install another recovery.img first (like maverixx) and then Amon_RA's again. If it still doesn't work reboot, remount the partitions r/w, insmod tattoo-hack.ko and retry flashing.
Q: How can I unroot my device?
A: Just delete su from /system/xbin and restore the old boot.img. Alternatively see here for retrieving a stock ROM to flash it on your phone.
PM me with more questions and I'll post them with the possible solution.
1.7 References
- Zecanilis EXCELLENT Root-Recovery-Flash images thread
- maverixx' One-click root method+recovery thread
- Coburn64's Newbie guide for manual rooting (recommended reading!)
2. Flashing images/ROMs
2.1 What is a recovery image
A recovery image is not only useful to flash custom ROMs on your device. It also enables you to backup your entire phone contents to restore it completely in case of a brick, if anything should happen...especially SIM-locked mobiles should be backed up as soon as possible. Also many recovery image modders add several non-standard features like mounting the SD card while in recovery mode or enabling adb support, etc.
2.2 What is a boot image
The boot image not only contains the kernel which brings up your Tattoos, it only can be modified to load up modules enabling ext2/3 support, loading camera, remapping read only code to an r/w area (tattoo-hack.ko), etc. Without a working boot.img, don't even bother trying to boot the phone (maybe if you do a logcat it returns something useful to solve this problem )
2.3 How to flash/tools needed
Execute steps 1 to 4 in topic 1.5 first!
5. Now comes the hard part:
- # ./flash_image boot /sdcard/boot.img
- # ./flash_image recovery /sdcard/recovery.img
it can be that flash_image reports errors in the last step (recovery.img step), but another user said it would be still working to boot to recovery...but to be sure (if you got the error!!!) flash maverixx recovery.img and then again the one I supplied in my archive (Amon_RA)
Reboot once and when you connect with adb to your phone you should see the difference
Click to expand...
Click to collapse
2.3.1 Creating a Goldcard
This is a post I took from MiSSigNNo, kudos to him:
Creating the Gold Card:
[...]
4. We need the android-sdk tools, we can find them here: http://developer.android.com/sdk/index.html download them, and unzip in a folder maybe in C:\androidtools
5. Go the the Command line (Start->Execute->write cmd and OK), and there you should find where you unzip the android-sdk tools, example cd c:\androidtools\tools
6. Run this command "adb shell cat /sys/class/mmc_host/mmc1/mmc1:*/cid" if you had the microSD in the drive you will find a long number like:
532600bd227d9c0347329407514d5402
7. Go to this page to reverse it: http://hexrev.soaa.me/ and copy the code reversed:
In our example it will be: 00544d5107943247039c7d22bd002653
8. Go to this page to generate your GoldCard image: http://revskills.de/pages/goldcard.html
And put your reversed number and you email. You will receive an email with a file called "goldcard.img"
9. Now you need an Hex editor like HXD. Download it from: http://download.cnet.com/HxD-Hex-Edi...html?tag=mncol
10. Exactly the same as the instructions I pasted above:
11. Install and launch HxD Hex Editor program. (make sure you use "Run as Administrator" under Vista and win 7)
12. Go to Extra tab > Open Disk. Under Physical disk, select Removable Disk (Must be your SD card), uncheck “Open as Readonly), click OK. (BEWARE, MUST BE UNDER PHYSICAL DISK NOT LOGICAL DISK, THIS MISTAKE MADE ME BIG PROBLEMS)
13. Go to Extra again, Open Disk Image, open up goldcard.img which you’ve saved/unzipped earlier.
Now, you should have two tabs, one is your removable disk, the other is goldcard.img. Press OK when prompted for “Sector Size” 512 (Hard disks/Floppy disks), click OK.
14. Click on goldcard.img tab. Go to Edit tab > Select All, edit tab again > copy.
15. Click on the “removable disk” tab. Select offset (line) 00000000 till offset (line) 00000170 (including the 00000170 line), click on Edit tab and then Paste Write.
16. Click on File > Save. now you can exit the program. You now have a gold card.
[...]
Click to expand...
Click to collapse
2.4 Where can I get an overview of the existing ROMs?
Look it up here (Excellent work liderzre)
2.5 Problems during flashing and solutions
Q: HEEEEELLLPPP! flash_image says that it couldn't write to some memory addresses! What can I do?
A: Don't panic. First make sure to have loaded tattoo-hack.ko, remounted system and data to r/w and then try again with another recovery.img (either maverixx or Amon_RA). Flashing the same recovery.img again WON'T WORK!!!! That's why you have to take a little detour by first flashing another recovery image.
Q: How do I boot to recovery??
A: Type in your command line while the phone is plugged in:
Code:
adb shell "reboot recovery"
. If this doesn't work, turn off your phone, hold down the home-button and press the power-button. Then when the Tattoo logo can be seen, release the home button and the recovery screen should be seen
2.6 References
- Zecanilis EXCELLENT Root-Recovery-Flash images thread
- maverixx' One-click root method+recovery thread
3. Information about the Tattoo/Useful stuff
3.1 How to install busybox?
Load the busybox binary here (select the one with arm6 at the end). Put this binary onto your data or system partition (I suggest /system/xbin) and now there are two ways to install/enable it. See below
Method 1 (will extract EVERY FEATURE, but consumes A LOT of your disk space so be careful or switch to method 2)
Do this in your command line:
Code:
adb remount (make it r/w if not done already)
adb shell "mkdir /system/xbin" (create dir if it doesn't exist)
adb push busybox /system/xbin (please make sure to have busybox in the same directory as adb ;) )
adb shell
cd /system/xbin
./busybox --install
Method 2 (saves your precious disk space )
Do this in your command line
Code:
/system/xbin/busybox --install -s /system/xbin
3.2 Can it perform multitouch?
Nope, the Tattoo has a resistive touch screen, which is known to be NON-multitouch...newer generation or high-end phones usually have capacitative screens. My suggestion is not taking the Nexus One anymore, since their touch screen type supports only 2 fingers at once, while phones like the Samsung Galaxy S have a SUPER responsiveness and sensibility (and of course 10 fingers support).
3.3 How to increase battery life?
Okay, here are little tips how to increase battery life - mine holds 7 to 8 days and I surf, call ppl and sms almost every day:
1. Flash either fyodor 0.6.4.2 or Abyzou 2.1.9 - my favourite is fyodor ones (if I still would have a Tattoo, of course )
2. Download APNd roid from the market or here and disable your 3G Internet connection (for activating it, just start the program again!)
3. If you see that you have NO RECEPTION AT ALL in one place (at work for instance), turn off your phone as this will DRASTICALLY decrease battery life because the phone tries constantly to search for a network it can log on to.
4. Try to keep your phone in normal temperature areas (between 20 and 27 degrees celsius = 68 - 80.6 degrees fahrenheit)
5. Kill unneeded apps automatically (there are quite a few apps doing this)
3.4 Using own ringtones for calls/sms
Create a folder called "media" on the root of your SD card and a sub-folder called "audio" there you have to create one folder called "notifications" for SMS and "ringtones" for call sounds. Place every desired track into these folders and reboot your phone. You should see the entries now when choosing ringtones. Alternatively just load "Ringo Pro", a really powerful tool also able to display SMS pop-ups and much more.
3.5 How to disable data transfer with a custom ROM?
As already explained above, load APN droid from the market or here.
3.6 How to make the Tattoo ring louder?
There is a little app called "Louder Volume Hack" enabling your phone to ring much louder than normally. You can load it on any popular w*rez-site Unfortunately I cannot enter the link to the app here or PM it. Any questions requesting a link to this app will be deleted instantly, so don't bother trying and use Google. There are several buttons displayed, but for better visibility I suggest enabling the Widget and hacking the system there. Also please note that ROOT access is required!! Refer to section 1 to root your phone.
3.7 How to replace the home screen?
There are two ways to do it. Method 1 is the easier one, but runs the Google Launcher and the replacement laucher in parrallel, which implies more CPU usage and battery drain. Method 2 is the more brutal one, but enables you to run just one launcher.
Method 1:
Install the replacement home app and press the home button. A dialog should appear asking you which Home Launcher should be used.
Method 2:
Put your home replacement apk onto the root of your SD and make sure you have busybox installed and /system mounted as writeable. Rename the Home replacement apk to Launcher.apk and fire up adb shell:
Code:
mv /system/app/Launcher.apk /system/app/Launcher.apk.old && mv /system/app/Launcher.odex /system/app/Launcher.odex.old && cp /sdcard/Launcher.apk /system/app && chmod 755 /system/app/Launcher.apk
Should be a pretty generic approach
3.8 Disabling xxx-synchronisation with Google-servers
Go to settings, data synchonisation and disable the entries you don't want to have synch'ed with Google. Since it's long time ago since I did this (remember that I don't own a Tattoo anymore) the procedure can be slightly different from ROM to ROM.
3.9 Backing up apk's and data to your PC
By popular request, here a topic about how to backup apk's and their corresponding data manually (can be done separately, too if you want just one of the two). Doing it with the tar command HOPEFULLY preserves also all permissions!!! Check it:
Hit up adb shell and make sure have busybox:
Code:
for the apks
# tar -cvf /sdcard/dataAppsBackup.tar /data/app
for the data
# tar -cvf /sdcard/dataDataBAckup.tar /data/data
If you want to decompress these files again do:
Code:
# tar -xvf /sdcard/dataAppsBackup.tar -C /data
# tar -xvf /sdcard/dataDataBackup.tar -C /data
Note that these files won't be compressed! If you want to save some disk space on your SD then add the parameter 'z' (without the quotes) in the tar arguments (e.g. tar -cvfz for compressing and tar -xvfz for decompressing)
3.10 How to enable more languages on my mobile?
There is an app called MoreLocale in the market enabling you to select more languages. Download it, it's free
3.11 How to manually delete system apks? Alternatively with GUI?
For deleting manually you only need root-access. With GUI you need RootExplorer (buy it or do what you need to do to get this app-but with these features I would suggest to buy the app ).
Note: I do not take any responsibility if you delete the wrong apk and you lose any functionality of the phone. Do this only if you know what you're doing!
The manual way:
Connect the phone via USB, fire up adb shell and type:
Code:
insmod /LOCATION TO [URL="http://TATTOOHACK.KO/tattoo-hack.ko"]TATTOOHACK.KO/tattoo-hack.ko[/URL]
mount -o rw,remount /dev/block/mtdblock3 /system
cd /system/app
rm NAMEOFAPK.apk
The GUI way:
Install RootExplorer, open it, navigate to /system/app and press the little "Mount R/W" button at the top of the screen and begin deleting
4. Dev-Goodies
4.1 Modifying update.zips and resigning them
See this thread and get enlightened
4.2 Modifying resources in apk-files and resigning them
Same procedure as above:
1. Extract the file with WinRAR/WinZIP, delete the contents of META-INF and start modifying what you have to modify
2. Pack everything again into a ZIP file and sign it with the signapk.jar file (can be found somewhere in the forum or here). The syntax of how to use this can be found in the last link (yes, it's only 10 KB ).
4.3 Installing apks via adb for getting exact error codes if installation fails
Prerequisites: Either know the exact path to the apk or put it into the same directory as your adb executable and hit up your command line:
Code:
adb install /path/to/apk/file.apk
OR
adb install file.apk (implies that apk is located in same dir as adb)
4.4 Everything related to ROM cooking
Check this link (thanks to Decad3nce) and this one (thanks to mxlaser).
5. Things I will do better in this thread due to user request
- Nothing
The end for now.
Note: If you think that my thread is good, then please rate it with 5 stars
Changelog:
Version 1.0
- Initial draft
Version 1.1
- Added complete topic 1 now
- Fixed layout and some typos
Version 2.0
- Added complete topic 2 and half of 3
Version 2.1
- First prototype with all topics finished (will rework parts which are not quite understandable)
Version 2.2
- Added new question to 1.6
Version 2.3
- Added section 4.4 -> Everything related to ROM Cooking DUDEEEESSSSS
Version 2.4
- Added 3.11 How to manually delete system apks? Alternatively with GUI?
Version 2.5
- attached working su file - thanks to lovenemesis for this
Version 2.6
- added some mirrors for the Tattoo.rar archive - thanks to emb0re for providing some space
Version 3
- added topic about creating gold cards (2.3.1)
hi
very good initiative stuck
Great work
Very intuitive guide for beginner.
Though as an experienced and new android application developer, it really took me a whole afternoon to understand every step of the whole process. I am sure this guide would save many others wonderful Saturday afternoon.
Nice Work
Great Work From You Sir. This Will Be Useful for Beginners I Think This Will Save Lot Of Our Time's. And Mods Too
Thanks for the feedback...I hope that I can fill many topics tomorrow
P.S.: Indeed this is meant for the many unexperienced users who desperately want to flash custom ROMs but don't know how to do it...this also spares a lot senseless thread-posts I hope...^^
Dude
SSj Man Can You Add Tutorial Abt How to get the Apk file which i download from market in my mobile. if that is possible
3. We have every needed file on the phone now. Type now (we are still in your terminal):
- adb shell
$ cd /data/local/bin
$ while ./m7 ; do : ; done
lots of text until you see something like "wrote shell code", press enter 2 or 3 times enter to see:
#
Click to expand...
Click to collapse
For me I need to add execute permission for m7 before expolit, with
Code:
chmod 766 m7
.
jagan_3400 said:
SSj Man Can You Add Tutorial Abt How to get the Apk file which i download from market in my mobile. if that is possible
Click to expand...
Click to collapse
You mean getting the apk from your mobile on your PC for example?
lovenemesis said:
For me I need to add execute permission for m7 before expolit, with
Code:
chmod 766 m7
.
Click to expand...
Click to collapse
Hm, normally when you push the file via adb it will have user permissions, which includes execution...but I will add it to exclude any possible error...thanks for the info.
It might be worth to mention this in 3.1 Busybox installation:
Code:
adb push busybox /system/xbin/
I accidentallly use "adb push busybox /system/xbin" without the ending "/". Well, you know the rest part of the story...
Hmm, probably this one first, at least for the stock HTC ROM
Code:
adb shell "mkdir /system/xbin"
PS: Kind of weird for its name xbin, not the usual sbin on desktop linux. ;-)
TheSSJ said:
You mean getting the apk from your mobile on your PC for example?
Hm, normally when you push the file via adb it will have user permissions, which includes execution...but I will add it to exclude any possible error...thanks for the info.
Click to expand...
Click to collapse
Maybe it's because I am using a Fedora box, which the default permission for files in $HOME does not include execution.
lovenemesis said:
Hmm, probably this one first, at least for the stock HTC ROM
Code:
adb shell "mkdir /system/xbin"
PS: Kind of weird for its name xbin, not the usual sbin on desktop linux. ;-)
Click to expand...
Click to collapse
You're right, I added it already in the guide, thanks for the feedback. Well, /system/xbin isn't a "normal" directory indeed, but it was created for extra executables which normally aren't shipped in stock ROMs (like busybox).
4. Then perform this:
- # export LD_LIBRARY_PATH=/system/lib
- # export PATH=/system/bin
- # insmod ./tattoo-hack.ko
- # mount -o rw,remount /dev/block/mtdblock5 /data
- # mount -o rw,remount /dev/block/mtdblock3 /system
- # cat ./su > /system/bin/su
- # chmod 4755 /system/bin/su
Click to expand...
Click to collapse
I suppose after this step the stock ROM is rooted. Right?
But in Android Terminal Emulator gives me $ still. "su" reports an link_image error, which basically said about missing libbinder.so library.
Is it normal or I need to push an libbinder.so to /system/lib as well?
BTW: "adb shell " gives me # straightly.
Regards,
Hmm, I pushed another "su" binary to overwrite the one in Tattoo.rar. And now it works fine in Android Terminal Emulator.
Here is the su binary I use:
View attachment su.zip
Oops, Titanium Backup still refuses to work despite of working "su" binary.
What else should I do?
market not working
hi
i dont know why but the Market does not work for me can u give any solutions for the same im just not able to log in it keeps saying error i also tried with google mail and gmail id but no luck any suggestion pls
few questons kindly answer
hi
i have afew questions can u kindly answer
1. is wipe a must before flashing a new rom
i have flashed the Modoco rom and it was mentioned that this was not needed but i have read in many threads asking to do the same before flashing
2.to bring back contacts after flashing new rom can i use
a. backup pro or titanium backup
b. can i just use the out look sync and get back my contacts from my PC
3. if i restore the stock rom and latter on want to try one of the cooked roms do i need to do the rooting again ie does flashing stock rom remove the rooting
Note : i have been a WM user new to AM is why im asking such questions in the WM i have one app pim backup which would get back all my contacts in 1 min and when flashing any WM it will automatically wipe all the data from the phone this does not seem to be the case with AM is why i have asked above Questions
thanks in advance
lovenemesis said:
Oops, Titanium Backup still refuses to work despite of working "su" binary.
What else should I do?
Click to expand...
Click to collapse
Titanium Backup needs Busybox and su to work. If Titanium Backup tells you that it found BusyBox, then try to copy "su" to the following to locations:
/system/bin and /system/xbin
I think with the first it should work then.
haree said:
hi
i dont know why but the Market does not work for me can u give any solutions for the same im just not able to log in it keeps saying error i also tried with google mail and gmail id but no luck any suggestion pls
Click to expand...
Click to collapse
Do you use MoDaCo ROM or did u switch now to another? Normally the phone asks for log-in credentials when going online. When you enter them correctly, the login window should disappear and you should be able to access market...I know this sounds stupid, but check if you entered you PW correctly!
haree said:
hi
i have afew questions can u kindly answer
1. is wipe a must before flashing a new rom
i have flashed the Modoco rom and it was mentioned that this was not needed but i have read in many threads asking to do the same before flashing
2.to bring back contacts after flashing new rom can i use
a. backup pro or titanium backup
b. can i just use the out look sync and get back my contacts from my PC
3. if i restore the stock rom and latter on want to try one of the cooked roms do i need to do the rooting again ie does flashing stock rom remove the rooting
Note : i have been a WM user new to AM is why im asking such questions in the WM i have one app pim backup which would get back all my contacts in 1 min and when flashing any WM it will automatically wipe all the data from the phone this does not seem to be the case with AM is why i have asked above Questions
thanks in advance
Click to expand...
Click to collapse
1. As I told you via PM already: If the ROM is based on the same source ROM (HTC stock in your case) then a wipe is NOT required, but if you switch android version (AOSP, Vanilla, FroYo, Eclair) then you HAVE TO wipe.
2.
a) I had only problems with Titanium backup concerning restoring contacts. I would suggest using MyBackup Pro
b) Well, if you can sync to outlook, then I suppose yes, but I really doubt that these features are implemented in custom ROMs...
3. Well, if you mean restoring the NAND-backup and then flashing another cooked ROM (which are all rooted by default ), then no - you don't need to re-root. Only if you would flash the original/official HTC ROM which comes shipped as exe-file, but I don't see the sense in flashing this one...use your NAND-backups
TheSSJ said:
Titanium Backup needs Busybox and su to work. If Titanium Backup tells you that it found BusyBox, then try to copy "su" to the following to locations:
/system/bin and /system/xbin
I think with the first it should work then.
hi
thanks buddy for patiently answering all my Q
i got it now but i dont know why this Bl***dy market does not work what every i try ie when the net is on and ur browsing u see the E on ur phone screen and then the 2 white arrows flash this it self does not happen when i try to log in to market
just dont know what is wrong
right now im using Modoco and happy with it seems to be real fast and everything is working on this ROM
Click to expand...
Click to collapse

[How To] Recover from a soft brick

A soft brick, in this case, is when you make a bad edit to your framework files and the phone won't fully boot and starts flashing a red LED at you.
There is one catch, you only get about 1-2min to do all of this before the phone reboots on its own. If that happens, do SuperOneClick steps again and continue where you left off. Better yet, build a script to do it all for you
Power off your device
Enter Fastboot:
Hold Volume down + power until you see Fastboot at the top left
Use volume down to scroll down to "Early USB Enumeration" (only shows one item at a time, if you pass it, keep going down, up selects)
Press Volume up to select
Wait for ADB to enable, run "Shell Root" from SuperOneClick, wait until it says you have root.
Enter adb shell from command line, You should have root(#) access:
adb shell
Mount the system directory as read/write:
mount -o rw,remount /dev/block/mmcblk0p12 /system
Make a new directory on /data for your recovery files: (sdcard wont be mounted yet)
mkdir /data/recover
Exit adb shell:
exit
Push your known working files to the new directory:
adb push /path/to/local/file.ext /data/recovery
Enter adb shell from command line:
adb shell
Copy your newly pushed recovery files to their proper location:
cp /data/recover/services.jar /system/framework
cp /data/recover/framework.jar /system/framework
cp /data/recover/famework-res.apk /system/framework
Reboot:
reboot now
Thanks! Extremely happy you are deving for this phone
What's the best way to backup my stock partitions before I keep playing with those files?
Titan Backup works for that?
Or just a tar cf /mnt/sdcard/systembackup.tar /system , works?
Thanks in advance.
uskr said:
What's the best way to backup my stock partitions before I keep playing with those files?
Titan Backup works for that?
Or just a tar cf /mnt/sdcard/systembackup.tar /system , works?
Thanks in advance.
Click to expand...
Click to collapse
I would just use the tar solution, much easier to deal with.
You can also use ADB, adb pull /system system
Also, the retail dump I did matched my phone dump bit for bit, as long as you have that you should be fine.
Thanks! I am messing around with the APKs and scripts to get the webtop to work without the dock. So I wanted to make sure I was covered.
designgears said:
I would just use the tar solution, much easier to deal with.
You can also use ADB, adb pull /system system
Also, the retail dump I did matched my phone dump bit for bit, as long as you have that you should be fine.
Click to expand...
Click to collapse
I already did both adb pull of system and tar, but how did you do the retail dump?
lpsi2000 said:
I already did both adb pull of system and tar, but how did you do the retail dump?
Click to expand...
Click to collapse
tar dump as root of system
One last question.
Once I deodex my /system/app, should I just do a adb push app /system/app and then rm /system/app/*.odex ?
I am used to use the update.zip trick on the captivate. But I am not sure how to proceed on this phone.
uskr said:
One last question.
Once I deodex my /system/app, should I just do a adb push app /system/app and then rm /system/app/*.odex ?
I am used to use the update.zip trick on the captivate. But I am not sure how to proceed on this phone.
Click to expand...
Click to collapse
push apps, then push framework, reboot, then delete all the odex files, reboot
from system do something like; find . -name "*.odex" -exec rm {} \;
designgears said:
push apps, then push framework, reboot, then delete all the odex files, reboot
from system do something like; find . -name "*.odex" -exec rm {} \;
Click to expand...
Click to collapse
Unrelated to this, I could sware yesterday I got to the recovery screen where I was able to wipe stuff and also be able to use update.zip. Although I did not use and update files but saw the option there. Today I am looking everywhere but the recovery screen does not come up with the options. I only see exclamation point and the droid. May be I am going nuts but can anyone confirm this.
lpsi2000 said:
Unrelated to this, I could sware yesterday I got to the recovery screen where I was able to wipe stuff and also be able to use update.zip. Although I did not use and update files but saw the option there. Today I am looking everywhere but the recovery screen does not come up with the options. I only see exclamation point and the droid. May be I am going nuts but can anyone confirm this.
Click to expand...
Click to collapse
tap at the bottom right of the screen right above the search button
designgears said:
tap at the bottom right of the screen right above the search button
Click to expand...
Click to collapse
ahha, thank you. Now I know I am going crazy. I used it yesterday to wipe when the system was unstable on me after playing around with the framework. I am must have stumble on that by accident. I am wondering if this documented yet somewhere around here.
Also too bad we cannot get root from there yet.
Well thank you for this. So when it boots to run, does it do a sys check to verify files are the same size or what? Anyway went to my local AT&T store and they swapped it out for me.
realawill said:
Well thank you for this. So when it boots to run, does it do a sys check to verify files are the same size or what? Anyway went to my local AT&T store and they swapped it out for me.
Click to expand...
Click to collapse
No, I just made a bad edit and it was FC hell
IT DOES NOT WORK WITH ME
I have been trying this trick for many times. The device restart and SuperOneClick hanging without any result.
designgears said:
No, I just made a bad edit and it was FC hell
Click to expand...
Click to collapse
Crazy....mine just would not reboot. But good to know that there is a way to recover. Love the phone but hate Motorola. Wish that it was easy as the Cappy.
Cool stuff. I may snatch the framework off the phone in stock form and make a batch package for this so folks can easily just double click to restore their framework and system app folder.
Good work DG...
I never get past that initial... Starting RSD protocol support screen. Is that fast boot? If so I'm a retard...
EDIT: I need the face palm sticky. It's not Volume UP...it's Volume Down. Reading comprehension for the loss...
azy8000 said:
IT DOES NOT WORK WITH ME
I have been trying this trick for many times. The device restart and SuperOneClick hanging without any result.
Click to expand...
Click to collapse
I have done this several times now, it works
I soft bricked my Atrix earlier this morning, and used this to recover. The time limit is a serious pain!
I ended up needing to separate /system into 5 separate pushes of 30MB each in order to get them done in time.
Oddly, after restoring everything, the phone is no longer associated with my motoblur account, and I can't add it.
Also, I think there my be some files in /system that are unaccounted for by the filesystem, as there is 70MB more than what is present.
Edit:
Restoring the system fixed both above problems.

[MOD] Fully deodexed/zipaligned App and Framework

You will have to manually install it via adb push or adb shell.
Below is the link for a package that contains /system/app and /system/framework fully deodexed and zipaligned (not signed). It's the Stock version, I didn't remove any apk or framework.
Use at your own risk!
Backup your /system before upgrade!
I did notice speed increase and better memory utilization.
http://www.usk.bz/android/system-deodexed.bz2
EDIT: Here is a quick howto do it. Do some research, speacially on the "Recovering from a software brick" thread posted by Designgears. You may need it, in ase you don't execute this right.
Warning: Do those steps carefully! If you get any error as a return for a command you did, stop immediately and post here with the error to make sure it's safe to continue or what you should do before continue.
1. Download the file system-deodexed.bz2 (it's a tar.bz2)
2. uncompress it with tar zxf system-deodexed.bz2. You will get a folder called "system" with two other folders inside(app and framework).
3. First push it to the device to a safe location (your internal sdcard):
Code:
adb push system /mnt/sdcard/deodexed/system
4. Now open an adb shell and backup the folders you will mess with to the sd card, in case you need to recovery them
Code:
adb shell
$ su
# mkdir /mnt/sdcard/original_system
# mkdir /mnt/sdcard/original_system/app
# mkdir /mnt/sdcard/original_system/framework
# cp /system/app/* /mnt/sdcard/original_system/app
# cp /system/framework/* /mnt/sdcard/original_system/framework
5. Now the tricky part, you will get force closes on the device screen, because you will do this with the system running, don't worry for now. It should clear up once you are done. (Thx for the tip!) Lets update the system with the deodexed files. While still on the adb sheel as root, from the previous step, continue with these commands:
Code:
# stop
# mount -o rw,remount /dev/block/mmcblk0p12 /system
# cp /mnt/sdcard/deodexed/system/framework/* /system/framework
# cp /mnt/sdcard/deodexed/system/app/* /system/app
# rm /system/framework/*.odex
# rm /system/app/*.odex
6. Once you are done, exit the adb shell and do a reboot:
Code:
adb reboot
It should take a little longer to reboot, its normal for the first time. Then you should have normal boot speeds.
I recommend do this on a clear system, or that you do a factory reset once you reboot. The reason for that is that sometimes you get some data corruption during the force closes (corruption on the configuration files, not user data). But a factory reset fixes that.
If all go well, you have a deodexed system and are ready to use some Mods!
Have fun!
[ Known issues ]
- None! Please report if you notice anything!
http://forum.xda-developers.com/showthread.php?t=961382
Hey, here is a fully working on I did over the weekend.
Thanks! I didn't see it before. Will still compare with mine to see which package I messed up.
uskr said:
Thanks! I didn't see it before. Will still compare with mine to see which package I messed up.
Click to expand...
Click to collapse
usually packages with sound files get messed up for whatever reason when deodexing
designgears said:
usually packages with sound files get messed up for whatever reason when deodexing
Click to expand...
Click to collapse
Are you still planning on posting your mod version with steps? I am asking because I want to take look before making I own edits if necessary. I figured you may have it the way I want and it would less work for me either way.
designgears said:
usually packages with sound files get messed up for whatever reason when deodexing
Click to expand...
Click to collapse
Do you use an automated script to deodex them? or manually do one by one? The BOOTCLASSPATH dependencies sometimes give me some headache.
Also, do you mind to share which zip compression level do you use to repackage them?
Thank again!
designgears said:
usually packages with sound files get messed up for whatever reason when deodexing
Click to expand...
Click to collapse
Actually, I just tried yours and it has the same problem. Can you try to add the "Social Status" motorola widget to your MotoBlur and tap it to Setup your account and see if it starts something?
Mine doesnt start the Setup intent and I can see a Java exception on adb logcat.
uskr said:
Actually, I just tried yours and it has the same problem. Can you try to add the "Social Status" motorola widget to your MotoBlur and tap it to Setup your account and see if it starts something?
Mine doesnt start the Setup intent and I can see a Java exception on adb logcat.
Click to expand...
Click to collapse
Nevermind. Neither were bugged. I installed the deodexed without a data wipe and something got corrupted on the /data (some configuration file or something). I did a factory data reset and everything is working!
Not to play with changing some apks!
Hi guys,
I don't have an Atrix for now, so maybe it's just a dumb question. Sorry if it is.
With the Defy, if you push files and your phone won't reboot because you messed with something, you're screwed, as we don't have a true custom recovery. (you need a booting system to be able to get to the bootstap custom recovery, which you can't get into if your system is messed and the phone doesn't boot).
So when we are in that case with a Defy, our only option is to reflash a Motorola signed sbf file using RSD lite, root again, install again bootstrap recovery,... and try again ;-).
I guess it has to be the same with the Atrix (as the bootloader is locked as in the Defy)
So my question is:
- Are there already Atrix sbf files out there to recover a soft-bricked Atrix?
- If not, how do you recover it if you messed with the system files and the Atrix won't boot into a working system (of at least a state where you can get root shell though adb).
adlx.xda said:
So my question is:
- Are there already Atrix sbf files out there to recover a soft-bricked Atrix?
- If not, how do you recover it if you messed with the system files and the Atrix won't boot into a working system (of at least a state where you can get root shell though adb).
Click to expand...
Click to collapse
If you only messed only with /system/app or /system/framework folders/files, designgear posted how to recovery those files using the stock, that you can also download a tar with all the /system files from this forum.
Updated the post with a short howto.
If you get a software brick, search the forum for a post from designgears about how to recovery from a software brick.
As per the link below - I type "stop" once in the adb shell and it allowed me to transfer everything over without corrupting everything.
http://forum.androidcentral.com/mot...cks/30539-how-manually-deodex-your-phone.html
slhawkins said:
As per the link below - I type "stop" once in the adb shell and it allowed me to transfer everything over without corrupting everything.
http://forum.androidcentral.com/mot...cks/30539-how-manually-deodex-your-phone.html
Click to expand...
Click to collapse
Thx. Added to the howto!
uskr said:
Thx. Added to the howto!
Click to expand...
Click to collapse
Add the following to your instructions otherwise you will get an error message
You need the below line before the others
# mkdir /mnt/sdcard/original_system
The below are in your original instructions but the above is needed prior to the below
# mkdir /mnt/sdcard/original_system/app
# mkdir /mnt/sdcard/original_system/framework
lpsi2000 said:
Add the following to your instructions otherwise you will get an error message
You need the below line before the others
# mkdir /mnt/sdcard/original_system
The below are in your original instructions but the above is needed prior to the below
# mkdir /mnt/sdcard/original_system/app
# mkdir /mnt/sdcard/original_system/framework
Click to expand...
Click to collapse
Thanks! Updated.
I want to try this but i dont have linux to uncompress the file. possible to recompress it in something like zip or rar format?
NguyenHuu said:
I want to try this but i dont have linux to uncompress the file. possible to recompress it in something like zip or rar format?
Click to expand...
Click to collapse
Extract it to the file with no extension.
Open winrar.
Drag drop this file into that (u'll find the zipped up contents)
Drag drop these to ur desktop or anywhere u want them
NguyenHuu said:
I want to try this but i dont have linux to uncompress the file. possible to recompress it in something like zip or rar format?
Click to expand...
Click to collapse
push the file to sdcard of the device and using tar there after all it is also a linux system
diablo009 said:
Extract it to the file with no extension.
Open winrar.
Drag drop this file into that (u'll find the zipped up contents)
Drag drop these to ur desktop or anywhere u want them
Click to expand...
Click to collapse
great! thanks.
uskr said:
I recommend do this on a clear system, or that you do a factory reset once you reboot. The reason for that is that sometimes you get some data corruption during the force closes (corruption on the configuration files, not user data). But a factory reset fixes that.
Click to expand...
Click to collapse
Hi all,
I just did deodexed my atrix. Thanks much for the wonderful work~!!!
Mine has handful of apps installed prior to deodex. I was wondering what would be implication for not having clean system after deodex.

[HOW TO] Debrand boot animations without flashing new ROM

** Requires ROOT+Busybox and either Terminal or a capable File Manager
So you don't feel like flashing a new ROM and losing all your data, but your carrier's boot up and shutdown branding is getting on your nerves? Here is what you do, the basic idea is the same as putting on a new boot animation
I'll assume you're using a Terminal and bootsamsung.qmg for the rest of this, the other files follow the same method
Copy stock boot and shutdown animations onto your SD card, I'll call the path to this location %sd%. A copy of the stock files in the attached archive.
Open terminal and become root
Code:
su
You may need to remount your /system partition as writable, if you're connecting via ADB, adb.exe may crash here - that's fine, just re-connect the USB cable and you shouldn't need to repeat this step again
Code:
mount -o remount,rw [COLOR="RoyalBlue"]/system[/COLOR]
Copy bootsamsung.qmg from %sd% to /system/media/,
Code:
busybox cp -f "[COLOR="RoyalBlue"]%sd%[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]" "[COLOR="RoyalBlue"]/system/media/[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Set the permissions of the file to 644,
Code:
chmod [COLOR="red"]644[/COLOR] "[COLOR="RoyalBlue"]/system/media/[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Get rid of the SD card copy if you don't want it anymore,
Code:
rm -f "[COLOR="RoyalBlue"]%sd%[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Clean up any overriding animations, I had this happen for my shutdown animation where my carrier had a shutdown directory in /system/media/video/ which contained another copy of shutdown.qmg, so check for the existence of these and remove them, e.g.
Code:
if [ -f [COLOR="RoyalBlue"]/system/media/video/[/COLOR][B][COLOR="Purple"]bootsamsung[/COLOR]/[COLOR="Green"]bootsamsung.qmg[/COLOR][/B] ]; then
rm -f [COLOR="RoyalBlue"]/system/media/video/[/COLOR][B][COLOR="Purple"]bootsamsung[/COLOR]/[COLOR="Green"]bootsamsung.qmg[/COLOR][/B]
fi
Reboot and see what happens!
Extra notes: Always keep backups of original files. If you can't get past the boot animation, restore the backups.
paulie-uk said:
** Requires ROOT+Busybox and either Terminal or a capable File Manager
So you don't feel like flashing a new ROM and losing all your data, but your carrier's boot up and shutdown branding is getting on your nerves? Here is what you do, the basic idea is the same as putting on a new boot animation
I'll assume you're using a Terminal and bootsamsung.qmg for the rest of this, the other files follow the same method
Copy stock boot and shutdown animations onto your SD card, I'll call the path to this location %sd%. A copy of the stock files in the attached archive.
Open terminal and become root
Code:
su
You may need to remount your /system partition as writable, if you're connecting via ADB, adb.exe may crash here - that's fine, just re-connect the USB cable and you shouldn't need to repeat this step again
Code:
mount -o remount,rw [COLOR="RoyalBlue"]/system[/COLOR]
Copy bootsamsung.qmg from %sd% to /system/media/,
Code:
busybox cp -f "[COLOR="RoyalBlue"]%sd%[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]" "[COLOR="RoyalBlue"]/system/media/[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Set the permissions of the file to 644,
Code:
chmod [COLOR="red"]644[/COLOR] "[COLOR="RoyalBlue"]/system/media/[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Get rid of the SD card copy if you don't want it anymore,
Code:
rm -f "[COLOR="RoyalBlue"]%sd%[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Clean up any overriding animations, I had this happen for my shutdown animation where my carrier had a shutdown directory in /system/media/video/ which contained another copy of shutdown.qmg, so check for the existence of these and remove them, e.g.
Code:
if [ -f [COLOR="RoyalBlue"]/system/media/video/[/COLOR][B][COLOR="Purple"]bootsamsung[/COLOR]/[COLOR="Green"]bootsamsung.qmg[/COLOR][/B] ]; then
rm -f [COLOR="RoyalBlue"]/system/media/video/[/COLOR][B][COLOR="Purple"]bootsamsung[/COLOR]/[COLOR="Green"]bootsamsung.qmg[/COLOR][/B]
fi
Reboot and see what happens!
Extra notes: Always keep backups of original files. If you can't get past the boot animation, restore the backups.
Click to expand...
Click to collapse
Hello, I'm interested in debranding my verizon s5. I'd love to get rid of the Verizon screen at bootup. I read through your directions and it seems that you are suggesting overwriting the animation with the stock that you provided. All good. It is the use of the terminal that I am completely unfamiliar with. I tried using adb.exe in a command window inside of windows 7 and it didn't even like the first command 'su' My phone is rooted with a custom rom and busybox in developer mode. Could you help me out with what terminal to use and how to connect etc. to enter the commands? I have a decent filemanager installed but It doesn't let me write to system. Thanks for this post.
Eaglebiker said:
Hello, I'm interested in debranding my verizon s5. I'd love to get rid of the Verizon screen at bootup.
Click to expand...
Click to collapse
My first comment must be to say I have a G900F, the international version of the phone and it's using a stock ROM with a few tweaks, e.g. root. A custom ROM will have changed the system partition already so this method shouldn't be applicable there - if it shows a carrier logo on a custom ROM then it's in another partition, not system
Eaglebiker said:
I read through your directions and it seems that you are suggesting overwriting the animation with the stock that you provided. All good. It is the use of the terminal that I am completely unfamiliar with.
Click to expand...
Click to collapse
I gave terminal instructions so people could do it only using their phone but as you've noticed, it's not the only option
Eaglebiker said:
I tried using adb.exe in a command window inside of windows 7 and it didn't even like the first command 'su'
Click to expand...
Click to collapse
If you are using adb, make sure that adb can gain root - the flag should be somewhere in your superuser's settings - then with your USB connected launch adb into shell mode from your computer. This makes adb act as a terminal
Code:
adb shell
If you see a $ then you are not root and will need to gain root, i.e. run su
If you see a # then you are root and don't need to do that
Eaglebiker said:
My phone is rooted with a custom rom and busybox in developer mode.
Click to expand...
Click to collapse
All good things!
Eaglebiker said:
Could you help me out with what terminal to use and how to connect etc. to enter the commands?
Click to expand...
Click to collapse
The terminal I use is can be found here (though I used v1.0.65). Most custom ROMs already include it so you may find it in your apps already. It's all on your phone so you'd type on your phone's keyboard as normal. You shouldn't have to use this if you want to use ADB.
Every time I wrote a %path% you will need to enter the real path for what you have on your device, e.g. %sd% may be /extSdCard/
Eaglebiker said:
I have a decent filemanager installed but It doesn't let me write to system.
Click to expand...
Click to collapse
What doesn't let you do this? If it's "read only" then you may need to remount the /system partition (my step 3). File managers like the one you get with CM do let you do root things but it needs to be in root mode or prompt mode (see it's settings). To find /system in a file manager, the easiest way is to keep going up until you're at /, then you should be able to go down through [/B]/system[/B]
Eaglebiker said:
Thanks for this post.
Click to expand...
Click to collapse
Thank you for letting me give some meaningful answers in post 3!
The Rom I'm using would be better described as a stock lollipop rom for the 900v with a few tweaks.
I now understand that you can have a terminal on the s5. I've installed the terminal and greatly prefer it. Using a terminal on the s5 hadn't even occurred to me and it sounds much easier then hooking to a computer needlessly. Awesome.
I manage to get su access #. in step 2.
in step 3 I type in the mount command and nothing seems to happen. no errors
in step 4 it tells me the folder or file doesn't exist. I'm certain it does. I can see it in my file manager. in the folder /extSdCard/bootsamsung.qmg and the destination folder is /system/media as well. I've tried it with and without quotes and no joy. Any clue what is going on?

A pure C implementation of 'cuber' using OpenSSL's BigNum library

In case anybody cares, here's a pure C reimplementation of 'cuber.py'
(my own earlier reimplementation of @vortox's signature.py).
This is what I'm using in my '1-Click' bootloader unlock VM...
See 'grep ^gcc' for "build instructions".
Hack, you can probably build this for ARM and run it right on your very HDX tablet... (-;
UPDATE (JanuaryFebruary 2017):
OK; so, @zivimo had built this for ARM, but people still haven't noticed.
I repacked his binary from a .tar.gz to a .zip archive and decided to spell out the instructions for use.
Perhaps, this helps... With the right bootloader in place, and adb/fastboot installed (and working),
the unlock is as easy as follows...
Download and extract unlock.zip (SHA256: e40e3010f8eccfa9cbd1e73eecac30cf799099d183de23b2d256fc3407f143f6e5db0b8d82c8fd2a25a22b0a598014d22a2ec33cef27a8d4b65a36acde08f27a)
to the same directory that holds the adb and fastboot executables (unless you have added them to your PATH)
Click on get_code.bat in the extracted folder
-- optional (but commonly required) step(s) --
fix root (roll back, if you need to), flash vulnerable bootloader
[you'll definitely need to perform at least some of these if the last step fails]
Click on unlock.bat in the extracted folder
The archive also includes .sh variants of the .bat files for convenience.
You could also just click to show the hidden section and cut&paste... (-;
Code:
[STRIKE]unzip cuber.zip[/STRIKE]
adb push cuber /data/local/tmp/
adb shell chmod 0755 /data/local/tmp/cuber
adb shell 'id=$(cat /sys/class/block/mmcblk0/device/{manfid,serial}); echo "$id"; echo 0x${id:6:2}${id:11:8} | /data/local/tmp/cuber > /sdcard/unlock.code'
adb pull /sdcard/unlock.code
adb shell rm /sdcard/unlock.code /data/local/tmp/cuber
adb reboot-bootloader
fastboot -i 0x1949 flash unlock unlock.code
NOTE: download and extract the attached 'cuberunlock.zip' and run the above commands
in the directory where 'cuber' got extracted to.
Nice job! Originally I wanted to use OpenSSL BigNum too, but I hadn't enough time and Python was easier to use
hey,
made a static compile with an arm debian (jessie). seemed the easiest solution to me. compile command:
Code:
# gcc -fPIE -static cuber.c -o cuber -lssl -lcrypto
# strip cuber
# ldd cuber
not a dynamic executable
# ./cuber
Usage: cuber [RSA-bytes] < data > sig
seems to work. arm(!) binary attached.
ok draxie, you pointed me here but something seems to be missing. i downloaded unlock.zip, put the files in my adb directory. when i run get_code.bat, it pushes cuber to the kindle in the right directory, changes permissions (dont see any errors there) but then stops saying the system can't find the specified path. Whats funny is i used es file explorer to check the paths in the script, and they are there so not sure where the hang up is.
chin_bone said:
ok draxie, you pointed me here but something seems to be missing. i downloaded unlock.zip, put the files in my adb directory. when i run get_code.bat, it pushes cuber to the kindle in the right directory, changes permissions (dont see any errors there) but then stops saying the system can't find the specified path. Whats funny is i used es file explorer to check the paths in the script, and they are there so not sure where the hang up is.
Click to expand...
Click to collapse
Did you check all three paths?
/data/local/tmp
/sdcard
/sys/class/block/mmcblk0
The 2nd one _may_ be problematic if you're on SafeStrap.
I don't know why. I'm yet to install that on one of my test
devices to investigate. (Or, was that the 1st... )
The 0 in the 3rd one may actually be a 1 on some systems.
I have a few extra lines in my VM script to work around
that, I can easily add that here as well, if that turns out
to be the issue.
BUT, to try and troubleshoot: how far does the script get?
If it didn't complain with the permissions, the 1st path is probably OK.
Does it print your manfid/serial?
If so, mmcblkX would be right as well.
Any chance that you're on SafeStrap?
Can you push/pull to/from /sdcard?
- - - - -
On a second thought: I've only ever tested this on Linux.
String quoting on Windows may work differently, and could *royally* mess up how that more complex command is interpreted.
I'll test tomorrow; it's like 20 past 1am here. I need to get some sleep.
In the meantime, as a workaround, you could just hard-code your manfid/serial, and replace this line:
Code:
adb shell 'id=$(cat /sys/class/block/mmcblk0/device/{manfid,serial}); echo "$id"; echo 0x${id:6:2}${id:11:8} | /data/local/tmp/cuber > /sdcard/unlock.code'
by the decidedly much simpler:
Code:
adb shell 'echo 0xmmssssssss | /data/local/tmp/cuber > /sdcard/unlock.code'
draxie said:
Did you check all three paths?
/data/local/tmp
/sdcard
/sys/class/block/mmcblk0
The 2nd one _may_ be problematic if you're on SafeStrap.
I don't know why. I'm yet to install that on one of my test
devices to investigate. (Or, was that the 1st... )
The 0 in the 3rd one may actually be a 1 on some systems.
I have a few extra lines in my VM script to work around
that, I can easily add that here as well, if that turns out
to be the issue.
BUT, to try and troubleshoot: how far does the script get?
If it didn't complain with the permissions, the 1st path is probably OK.
Does it print your manfid/serial?
If so, mmcblkX would be right as well.
Any chance that you're on SafeStrap?
Can you push/pull to/from /sdcard?
- - - - -
On a second thought: I've only ever tested this on Linux.
String quoting on Windows may work differently, and could *royally* mess up how that more complex command is interpreted.
I'll test tomorrow; it's like 20 past 1am here. I need to get some sleep.
Click to expand...
Click to collapse
It's all good draxie, i figured out what i was doing wrong with the other procedure, that damn STEP 2, once i did it, everything fell into place. Bootloader unlocked and now just trying to figure out which rom to try first. Thanks again, you guys are great and i know how valuable everyones time is. :good:
I keep hitting road blocks, I am rooted and on Fire OS 4.5.5.2 I click get code a screen flashes up then I click Unlock and my Kindle boots to the Grey Kindle screen with Fastboot underneath and nothing else happens. Same happens when I copy and past the code into ADB. What step am I failing at? Thanks for the help!
pdanforth said:
I keep hitting road blocks, I am rooted and on Fire OS 4.5.5.2 I click get code a screen flashes up then I click Unlock and my Kindle boots to the Grey Kindle screen with Fastboot underneath and nothing else happens. Same happens when I copy and past the code into ADB. What step am I failing at? Thanks for the help!
Click to expand...
Click to collapse
@draxie - I have no experience with this tool; python/gmpy2 works reliably for me. Sorry to pull you in ...
Davey126 said:
@draxie - I have no experience with this tool; python/gmpy2 works reliably for me. Sorry to pull you in ...
Click to expand...
Click to collapse
I am up and running now, unlocked and running kk-fire-nexus-rom-thor-20161017. Play store is also up and running.
pdanforth said:
I am up and running now, unlocked and running kk-fire-nexus-rom-thor-20161017. Play store is also up and running.
Click to expand...
Click to collapse
Did you end up using some other method, or did these scripts work for you in the end?
Either way, others may find useful if you could share whatever worked for you. (-;
Unfortunately, I still haven't had a chance to test these scripts in Windows;
so, I couldn't answer your first call for help in a good way. If there's something
wrong and there's enough interest, I'll be happy to fix it as soon as I can.
draxie said:
Did you end up using some other method, or did these scripts work for you in the end?
Either way, others may find useful if you could share whatever worked for you. (-;
Unfortunately, I still haven't had a chance to test these scripts in Windows;
so, I couldn't answer your first call for help in a good way. If there's something
wrong and there's enough interest, I'll be happy to fix it as soon as I can.
Click to expand...
Click to collapse
@stangri did my unlock file and I used this thread to unlock https://forum.xda-developers.com/kindle-fire-hdx/general/thor-unlocking-bootloader-firmware-t3463982
I had trouble making the Unlock file, once that was done and some help from other users I am now up and running!

Categories

Resources