Restore your Baseband in MT65XX Devices - Android Software/Hacking General [Developers Only]

HOW TO RESTORE YOUR BASEBAND IF YOU LOST IT DURING A FORMAT - MT65XX DEVICES
Thanks go to abdullahi_ for this solution. His original post from another forum can be found below:
https://forum.hovatek.com/thread-116-post-376.html#pid376
Prequisites
Phone Rooted
Smart Phone Flash Tool Backup - Specifically protect_f file (for a Dual SIM phone, maybe different for a single SIM phone)
Linux OS - I used Ubuntu in a virtual machine
Android SDK platform tools for ADB access
From a terminal (CTRL + ALT + T)
Code:
mkdir -p ~/protect_f/f
cd ~/protect_f
At this point copy the file "protect_f" in the ~/protect_f
then continue:
Code:
sudo mount -t ext4 -o loop protect_f f/
Enter your password
then continue:
Code:
cd f
sudo chown -R $USER:$USER *
Copy the files in the f/md folder to a folder on your phone and using a file manager with root access copy the two files into the /protect_f folder or any toher means
NOTE: You will probably get back your cell access immediately. However, please continue to make the permissions and ownership are the same as the original.
Also if you have a dual SIM, one of the files from the protect_f folder will automatically be created in the protect_s folder
To clean up the files on the Linux OS:
Code:
cd ~/protect_f
sudo umount f/
cd ~
rm -rf protect_f
To change permissions and ownership on the files
From an adb shell for your phone:
Code:
su
cd /protect_f
ls -l
Take note of the ownership of the md folder, on the phone I used they were ccci & nvram, in Linux the ownership was 9996 & 9997.
At this point I put the phone in airplane mode, just as a precaution to make sure the rest went smoothly
Code:
cd md
chown ccci:nvram *
chmod 660 *
If you have a DUAL SIM phone, for the second folder....
Code:
cd /protect_s/md
chown ccci:nvram *
chmod 660 *
You can now take the phone off of airplane mode and reboot your phone to be sure it is working,
ALL DONE!

REMOVED

Related

[HOW-TO] change your french orange dream firmware by a custom one...

Thanks to :
• JF for his recovery.img
• Arisme for the analysis of the dumped french orange firmware and his tools to customize the firmware
1) The tools
Unzip all the tools on one folder on your hard disk (c:\ModifDream for example)
SDK here :
http://developer.android.com/sdk/download.html?v=android-sdk-windows-1.1_r1.zip
fastboot here :
http://member.america.htc.com/download/web_materials/ADP/fastboot.exe
other tools here :
http://www.megaupload.com/?d=XMGZSYOM
You must copy thoses files on the microSD card :
- boot-root.img
- systemDEV.img
- dataDEV.img
- libhtc_ril.so (we need this patch from the original french firmware for a compatibility with the radio)
- wlan.ko (we need this patch from the original french firmware for a compatibility with wifi)
- busybox.asc
- trout-keypad-v3-franch-azerty.kcm.bin (with the ' and the ")
2) Backup of your dream.
We will use the JF recovery :
- Shutdown the dream
- plug it to the PC
- put your dream in fastboot mode
- On the PC, do :
cd\ModifAndroid
fastboot boot recoveryJF.img
- On the dream keyboard do ALT+B to backup your dream
- At the end of the backup do BACK+HOME to reboot
Ok the backup is done (NANDROID folder on your microSD card
3) Patch the boot for permanent root access throw adb
Put the dream in fastboot mode
Plug it to the PC
- On the PC, do :
cd\ModifAndroid
fastboot boot recoveryBoot.img
After the startup of your dream, do on the PC :
adb shell
mount /dev/block/mmcblk0p1 /sdcard
flash_image boot /sdcard/boot-root.img
reboot
4)Install of the new firmware and of all the patchs (ADP firmware)
Put the Dream in fastboot mode and plug it to the PC
- On the PC do :
cd\ModifAndroid
fastboot boot recovery-unyaffs.img
After the startup, do on the PC
adb shell
mount /dev/block/mmcblk0p1 /sdcard
mkdir /tmp/system
mkdir /tmp/data
mount /dev/block/mtdblock3 /tmp/system
mount /dev/block/mtdblock5 /tmp/data
cd /tmp/system
rm -rf * (dont be afraid by the error)
unyaffs /sdcard/systemDEV.img
cd /tmp/data
rm -rf * (dont be afraid by the error)
unyaffs /sdcard/dataDEV.img
cp /sdcard/libhtc_ril.so /tmp/system/lib/
cp /sdcard/wlan.ko /tmp/system/lib/modules/
cp /sdcard/trout-keypad-v3-franch-azerty.kcm.bin /tmp/system/usr/keychars/
cp /sdcard/trout-keypad-v3-franch-azerty.kcm.bin /tmp/system/usr/keychars/trout-keypad-v3.kcm.bin
cp /sdcard/trout-keypad-v3-franch-azerty.kcm.bin /tmp/system/usr/keychars/trout-keypad.kcm.bin
Do on the dream keyboatd ALT + W
After the startup, do on the PC (to have root and busibox) :
cd\ModifAndroid
adb shell
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
dd if=/sdcard/busybox.asc of=/system/bin/busybox
chmod 4755 /system/bin/busybox
cd /system/bin/
busybox cp -s busybox cp
busybox sh
cat sh > su
chmod 4755 su
reboot
OK, that is finished!
After the startup you will have to sign in with your gmail account. To do it you have first to create an APN (MENU and then NEW APN)
5)Back to the orange firmware
If you need to come back to the orginal situtation, just copy system.img and data.img from your NANDROID backup at the root of your microSD Card and copy and rename the boot.img from this backup to boot-orange.img at the root of the card.
Put the dream in fastboot mode
Plug it to the PC
- On the PC do :
cd\ModifAndroid
fastboot boot recovery-unyaffs.img
After the startup, do on the PC :
adb shell
mount /dev/block/mmcblk0p1 /sdcard
mkdir /tmp/system
mkdir /tmp/data
mount /dev/block/mtdblock3 /tmp/system
mount /dev/block/mtdblock5 /tmp/data
cd /tmp/system
rm –rf * (don't be afraid by the error)
unyaffs /sdcard/system.img
cd /tmp/data
rm –rf * (don't be afraid by the error)
unyaffs /sdcard/data.img
On the dream keyboard do ALT + W
Put again the dream in fastboot mode
On the PC do
cd\ModifAndroid
fastboot boot recoveryBoot.img
After the startup do on the PC :
adb shell
mount /dev/block/mmcblk0p1 /sdcard
flash_image boot /sdcard/boot-orange.img
reboot
REMARK
You will find in the zip a tool : unyaffs. With this tool you can extract on your PC image like system.img or data.img. This is really interesting if you need some patch from the orginal firmware. Maybe italian users can use it to get their keyboard layout, update it (with an hex editor) and replace the french layout in this exemple with the italian one
To use this tool : unyaffs system.img or unyaffs data.img with your image on the same folder fo unyaffs
Ah ouais ca a l'air sport comme méthode.
Oh it's seems pretty hard to do .
Are you sure it's working ?????
Vraiment impressionnant... j'espère que cela fonctionne bien
Tous mes espoirs d'avoir un téléphone Dream fonctionnel vont devenir réalité...
Enorme...
Really impressing I hope that it works well
All my hopes to have a functional telephone Dream are going to become reality
Enormous...
Note that it looks complicated because all steps are shown to give a headstart to other modders.
You can build a simple update.zip from those instructions if you want the most "interesting" parts being
a) gaining root by booting an image
b) using unyaffs to restore the original firmware, since no official update.zip exists for it so far
Really Great Job...
I have try this rom...
It's pretty good... YOU'RE THE KING OF THE ANDROID FRENCH PHONE
I have some problems with synchro (no 3G) and the img files are in English...
Could you help me to put this in French ???
Thanks in advance.
Best Regards
ADP firmware is an German/English firmware. You won't find a french firmware with a good google sync...
For the 3G have you created the new APN as described ?
For the APN :
name : orange
apn : orange
user : orange
pwd : orange
MCC : 208
MNC : 01
type : default
It's working....
Do you think it will be possible to made my own Firmware making a build with the French translations ???
Thanks in advance
You could translate the free (i.e. non Google) apps. But it's going to be a lot of work, when Cupcake is coming in a few months.
After i hacked my dream, following all the steps, my calendar app shuts down all the time...so i went back to orange firmware and my calendar is ok, but no synchro as it's expected to do with this firmware.
Anyone has same issue ? ideas ?
Oh, and before i went back to orange firmware, IM app and voice search were activated oO
Anyway, good job guys !
Problem
That finnish but I got a problem I am block by google account, my sim card is not reconize. I was maybe forget an step, but wich one ?
please help me
thx for that job
have you created the new apn as described ?
yes
yes I create orange apn like describe but It never ask me pin code ;-(
hum hum.. have you done the line cp /sdcard/libhtc_ril.so ...
I think yes, because I just copy/paste all command line, so that one were paste (I hope), if not what can I do ?
thx
i am surfing with my dream so it is not easy to write a specific process... so do again the step 4 and, please. do it line after line to be sure that all is ok...
ok I will try now to do step 4 and tell you if it is good. Or I will go on orange rom
thx geek78
is it normal
/tmp/system # rm –rf *
rm: cannot remove '–rf': No such file or directory
rm: app: is a directory
rm: bin: is a directory
rm: etc: is a directory
rm: fonts: is a directory
rm: framework: is a directory
rm: lib: is a directory
rm: lost+found: is a directory
rm: media: is a directory
rm: sounds: is a directory
rm: usr: is a directory
rm: xbin: is a directory
/tmp/system #
no, do again rm -rf * (dont forget the space after -rf)
yes It is what I do (I just copy and paste) so I keep space, but you said don't worry with error ;-)
The error is maybe here because all the process is ok, just an error in this command line.
I retry
thx
It smelt very good, you are a king, ****ing process, who do what you ask him ;-)
It first view all is good, I just need to do some configuration.
Thanks geek78 and have good night
See yu

[DUMP] Sidekick 4G Partition + Kernel Source (Bootloader, Recovery, etc)

Credit to sofauxboho for performing dumps.
Partition Dump
http://gititbit.ch/sk4g2 - partition dump
Code:
bml1 256 KB contains boot.bin (262144 bytes), Primary Boot Loader (low-level hardware initialization)
bml2 256 KB contains PIT file first 512 bytes
bml3 10240 KB /dev/block/stl3 /efs
bml4 1280 KB contains Sbl.bin (1310720 bytes) Secondary Boot Loader (loads the Linux kernel and passes the necessary arguments)
bml5 1280 KB contains Secondary Boot Loader (for recovery, ect)
bml6 5120 KB param.lfs /mnt/.lfs j4fs
bml7 7680 KB contains zImage and initramfs
bml8 7680 KB empty - on Epic 4G and Fascinate, contains recovery.bin
bml9 293376 KB factoryfs.rfs ( /system RFS Partition) /dev/block/stl9
bml10 137216 KB dbdata.rfs ( /dbdata RFS Partition) /dev/block/stl10
bml11 35840 KB cache.rfs ( /cache RFS Partition) /dev/block/stl11
bml12 12800 KB modem.bin
EDIT: It has come to my attention that the Super One Click works, no need for a script.
More Mirrors
http://gititbit.ch/sk41 - Sidekick 4G system dump
http://gititbit.ch/sk4g1 - Sidekick 4G Info Dump
dev.txt
devblock.txt
efs.txt
mount.txt
partitions.txt
proc.txt
Kernel + Platform Source
http://gititbit.ch/sk4g5 - SGH-T839_OpenSource.zip
Now for custom roms...
SK4G development chat can be found at irc.freenode.net #sk4g
hey, sorry i'm not super code-savvy.... do i simply place the .rar file on my sd card, or open it with say, 7zip, and copy the autoroot folder over? i'm getting 'unable to chmod, operation not permitted' the second way, and 'not found, no such directory, etc' when i place the .rar file on my sd card. both of these are appearing after the first line with chmod 755 etc.
Use winrar to extract the .rar then place the extracted folder onto the sdcard.
dasmoover said:
Use winrar to extract the .rar then place the extracted folder onto the sdcard.
Click to expand...
Click to collapse
ok, think i did that, but am still getting 'operation not permitted'..... perhaps i'll hold off and see if someone else has success with it?
Hmm...
Should line 14 specify the su file rather than the containing directory?
It currently reads:
Code:
cp su /system/xbin/ && chmod 4755 /system/xbin/
But perhaps it should read:
Code:
cp su /system/xbin/ && chmod 4755 /system/xbin/su
Updated the script in the main download.
yogi2010 said:
hey, sorry i'm not super code-savvy.... do i simply place the .rar file on my sd card, or open it with say, 7zip, and copy the autoroot folder over? i'm getting 'unable to chmod, operation not permitted' the second way, and 'not found, no such directory, etc' when i place the .rar file on my sd card. both of these are appearing after the first line with chmod 755 etc.
Click to expand...
Click to collapse
Im getting this when I try the lines too.
When I copied the autoroot folder to my SK4G, the contents of the folder were already set to 775, so there should be no need to chmod (though I also get the permission error when trying to chmod them).
The bigger issue is that my device doesn't have the cp command. I'd assume it would be in /system/bin along with things like ls and mv, but it's not.
Huh. That's odd. You guys are using the newer download, right?
Do you have any idea which chmod command is erroring out? I'm wondering if it's the chmod on the rage...bin in line 9 or the chmod on su in line 14.
Unfortunately I can't test without wiping my SK4G back to unrooted, which I would rather not do as it's my primary handset.
If you don't know which line is causing the trouble, could you try copying the kit but then entering each line manually?
sofauxboho said:
Huh. That's odd. You guys are using the newer download, right?
Do you have any idea which chmod command is erroring out? I'm wondering if it's the chmod on the rage...bin in line 9 or the chmod on su in line 14.
Unfortunately I can't test without wiping my SK4G back to unrooted, which I would rather not do as it's my primary handset.
If you don't know which line is causing the trouble, could you try copying the kit but then entering each line manually?
Click to expand...
Click to collapse
No I was usin the old link didn't try new one yet. Still says same thing on new version
Sent From SK4G
sofauxboho said:
Huh. That's odd. You guys are using the newer download, right?
Do you have any idea which chmod command is erroring out? I'm wondering if it's the chmod on the rage...bin in line 9 or the chmod on su in line 14.
Unfortunately I can't test without wiping my SK4G back to unrooted, which I would rather not do as it's my primary handset.
If you don't know which line is causing the trouble, could you try copying the kit but then entering each line manually?
Click to expand...
Click to collapse
I tried the newer download. All of the chmods error because my user doesn't own those files or already have write permissions for any of them. I don't have read, write, or execute permissions for /data/local/tmp either, so I can't list or copy to that location. But, separate from that, there is no cp command, so I can't copy anything anywhere.
jarrodlombardo said:
When I copied the autoroot folder to my SK4G, the contents of the folder were already set to 775, so there should be no need to chmod (though I also get the permission error when trying to chmod them).
The bigger issue is that my device doesn't have the cp command. I'd assume it would be in /system/bin along with things like ls and mv, but it's not.
Click to expand...
Click to collapse
Ah, right! That's why I used cat instead of cp when I rooted mine.
Try this:
Code:
#!/bin/sh
#autoroot script for sidekick v0.1
#chmod 755 autoroot.sh
echo "Copying binaries to /data/local/tmp/"
cat su > /data/local/tmp/su
cat Superuser.apk > /data/local/tmp/Superuser.apk
cat rageagainstthecage-arm5.bin > /data/local/tmp/rageagainstthecage-arm5.bin
cd /data/local/tmp/
echo "I'm about to chmod rageagainstthecage-arm5.bin"
chmod 755 rageagainstthecage-arm5.bin
echo "Executing exploit, please wait"
./rageagainstthecage-arm5.bin
sleep 20
echo "Attempting to spawn root shell"
sh
whoami
echo "Attempting to mount /system read-write"
mount -o remount,rw /dev/block/stl9 /system
echo "Attempting to copy and chmod su"
cat /data/local/tmp/su > /system/xbin/su && chmod 4755 /system/xbin/su
echo "Attempting to copy Superuser.apk"
cat /data/local/tmp/Superuser.apk > /system/app/Superuser.apk
sleep 5
mount -o remount,ro /dev/block/stl9 /system
#add root entry to passwd and group
echo "root::0:0:root:/data/local:/system/bin/sh" > /etc/passwd
echo "root::0:" > /etc/group
echo "autoroot completed succesfully."
I've also added a bunch of echoed comments to help us track where things go wrong if it doesn't work.
sofauxboho said:
Ah, right! That's why I used cat instead of cp when I rooted mine.
Try this:
Code:
#!/bin/sh
#autoroot script for sidekick v0.1
#chmod 755 autoroot.sh
echo "Copying binaries to /data/local/tmp/"
cat su > /data/local/tmp/su
cat Superuser.apk > /data/local/tmp/Superuser.apk
cat rageagainstthecage-arm5.bin > /data/local/tmp/rageagainstthecage-arm5.bin
cd /data/local/tmp/
echo "I'm about to chmod rageagainstthecage-arm5.bin"
chmod 755 rageagainstthecage-arm5.bin
echo "Executing exploit, please wait"
./rageagainstthecage-arm5.bin
sleep 20
echo "Attempting to spawn root shell"
sh
whoami
echo "Attempting to mount /system read-write"
mount -o remount,rw /dev/block/stl9 /system
echo "Attempting to copy and chmod su"
cat /data/local/tmp/su > /system/xbin/su && chmod 4755 /system/xbin/su
echo "Attempting to copy Superuser.apk"
cat /data/local/tmp/Superuser.apk > /system/app/Superuser.apk
sleep 5
mount -o remount,ro /dev/block/stl9 /system
#add root entry to passwd and group
echo "root::0:0:root:/data/local:/system/bin/sh" > /etc/passwd
echo "root::0:" > /etc/group
echo "autoroot completed succesfully."
I've also added a bunch of echoed comments to help us track where things go wrong if it doesn't work.
Click to expand...
Click to collapse
Type this into terminal right?
Actually, I whipped up a modified version of dasmoover's tool with my changes:
http://notfine.com/android/sk4g/autoroot-V01b-sfb.zip
Unzip that and copy the "autoroot" folder to your SD card.
Next, eject your SK, turn off USB Storage mode, and unplug it from your computer.
Then follow dasmoover's instructions (I've cleaned them up slightlly):
1. Place autoroot folder on sdcard
2. Install the Terminal Emulator app from the Marketplace
3. Open the Terminal Emulator app and type the following commands exactly, one at a time, hitting enter at the end of the line:
Code:
chmod 755 /sdcard/autoroot/autoroot.sh
./sdcard/autoroot/autoroot.sh
If the sdcard is mounted as noexec, follow these steps:
1. Place autoroot folder on sdcard
2. Install the Terminal Emulator app from the Marketplace
3. Open the Terminal Emulator app and type the following commands exactly, one at a time, hitting enter at the end of the line:
Code:
cat > /sdcard/autoroot/autoroot.sh /data/local/tmp/autoroot.sh
chmod 755 /data/local/tmp/autoroot.sh
cd /sdcard/autoroot/
./data/local/tmp/autoroot.sh
Click to expand...
Click to collapse
All credit to dasmoover, btw! Thanks, and I hope you don't mind me modifying and repackaging your tool. Just trying to help get it working.
BTW, here are some good goodies on how this root exploit works for the technical and curious:
I'd read this one first: http://intrepidusgroup.com/insight/2010/09/android-root-source-code-looking-at-the-c-skills/
And this one second:
http://dtors.org/2010/08/25/reversing-latest-exploid-release/
How did you get rid of the $ sign and get a # ? When I type the first line with the ca it sayd directory can't be found.
Sent From SK4G
I copied the new cat version onto my device and did the following:
$ chmod 755 /sdcard/autoroot/autoroot.sh
Unable to chmod /sdcard/autoroot/autoroot.sh: Operation not permitted
$ cat /sdcard/autoroot/autoroot.sh > /data/local/tmp/autoroot.sh
Cannot create /data/local/tmp/autoroot.sh: permission denied
So, I'm still stuck since /data/local/tmp isn't writable. (Also, you'll note I fixed the small error in the cat line I used.)
Ace42 said:
How did you get rid of the $ sign and get a # ? When I type the first line with the ca it sayd directory can't be found.
Sent From SK4G
Click to expand...
Click to collapse
So, the # means root. The $ means not root. The whole point of this is to get the #, which indicates a root prompt.
If it says the directory can't be found then either the command was typed incorrectly or the files are in the wrong place. The files have to be in the exact right places with the exact right names.
Download my modified version:
http://notfine.com/android/sk4g/autoroot-V01b-sfb.zip
Unzip it, and it should give you a folder called "autoroot". Inside that should be four files:
autoroot.sh
rageagainstthecage-arm5.bin
su
Superuser.apk
Make sure there is only a folder named "autoroot" with those four files inside. If there is another directory inside it won't work. If the names are at all different it won't work.
Copy this "autoroot" folder to the top level of your SD card. There should be other folders there like Music, DCIM, Playlists, and Android. Maybe some others. Make sure it's at the very top level, along with these other directories.
Here, take a look at my directory structure:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
(Yes, I'm on a Mac, but your SK and Android don't care. File locations work the same on Windows or Linux or whatever. Also, I may have some folders you don't have. That's ok.)
Next, eject your SK, turn off USB Storage mode, and unplug it from your computer. **I forgot this part earlier! It's important.**
Then open up Terminal Emulator an your SK4G. Type:
Code:
cd /sdcard/autoroot
Then type:
Code:
ls
This should list the same four files above. If it does, you're ready to start the instructions I posted previously.
If it doesn't, type:
Then type:
Code:
ls /sdcard/
Let me know what it says.
jarrodlombardo said:
I copied the new cat version onto my device and did the following:
$ chmod 755 /sdcard/autoroot/autoroot.sh
Unable to chmod /sdcard/autoroot/autoroot.sh: Operation not permitted
$ cat /sdcard/autoroot/autoroot.sh > /data/local/tmp/autoroot.sh
Cannot create /data/local/tmp/autoroot.sh: permission denied
So, I'm still stuck since /data/local/tmp isn't writable. (Also, you'll note I fixed the small error in the cat line I used.)
Click to expand...
Click to collapse
Yeah, I've confirmed this problem.
Folks, this thing won't work right now. We need a location that is both writable and allows execution. Any ideas?
(To confirm, you can still root by using adb to manually put these files at /data/local/tmp/ For some reason, adb has rights to this location. However, the standard Terminal Emulator does not. This is only a hang-up for on-device rooting, not rooting in general.)
sofauxboho said:
Yeah, I've confirmed this problem.
Folks, this thing won't work right now. We need a location that is both writable and allows execution. Any ideas?
Click to expand...
Click to collapse
I've poked around some and not found anywhere yet. :/

[q] how to deox any firmware manually? [q]

How to deox any firmware manually?
download htc kitchen.
put your ROM in the original update folder.
run menu file
select option "Deodex ROM"
If you want deodex a running phone you need a rooted phone and:
1-Download xUltimate
xUltimate v2.3.3
Extract xUltimate to a folder
2-Install JDK
Download JDK
3-Connect phone to PC, open main.exe in xUltimate folder
Select option 5.
Process will take along time.
After that, copy 2 folder done_app and done_frame to SDcard
Remember Disconnect USB on phone after copy
4-go to xUltimate folder press combo key: ctrl + shift + mouse right to jar folder. Select open command window here
A CMD is open copy an paste all commands below
Code:
adb shell
Code:
su
Code:
stop
Code:
mount -o rw,remount -t rfs /dev/block/stl12 /system
Code:
rm /system/app/*.odex
Code:
rm /system/framework/*.odex
Code:
cp /sdcard/done_app/* /system/app/
Code:
cp /sdcard/done_frame/* /system/framework/
if cp command doesnt work you need addition command before use cp
Code:
ln -s /system/xbin/busybox /system/xbin/cp
And start your phone after done
Code:
start
zcop said:
If you want deodex a running phone you need a rooted phone and:
1-Download xUltimate
xUltimate v2.3.3
Extract xUltimate to a folder
2-Install JDK
Download JDK
3-Connect phone to PC, open main.exe in xUltimate folder
Select option 5.
Process will take along time.
After that, copy 2 folder done_app and done_frame to SDcard
Remember Disconnect USB on phone after copy
4-go to xUltimate folder press combo key: ctrl + shift + mouse right to jar folder. Select open command window here
A CMD is open copy an paste all commands below
Code:
adb shell
Code:
su
Code:
stop
Code:
mount -o rw,remount -t rfs /dev/block/stl12 /system
Code:
rm /system/app/*.odex
Code:
rm /system/framework/*.odex
Code:
cp /sdcard/done_app/* /system/app/
Code:
cp /sdcard/done_frame/* /system/framework/
if cp command doesnt work you need addition command before use cp
Code:
ln -s /system/xbin/busybox /system/xbin/cp
And start your phone after done
Code:
start
Click to expand...
Click to collapse
Step 4 isnt working,, I have disconnected the usb still there is no "open command window here" comming,,, i am on windows xp.....

Samsung Galaxy S insert SIM CARD problem

Hi,
Can you please help me how I can CODE in my mobile ( SAMSUNG GALAXY S - GTI9003)
I m happy to see the solution given by you.. but dont know how to code on ADB shell in my device
Thanks in advance
vssvaas
01binary01 said:
I think every issue to do with losing the baseband has a slight twist, I'm beginning to think not every problem can use the same solution.
I've fixed mine, using similar lines as the posting in http://forum.xda-developers.com/showthread.php?t=1261948
As I couldn't get 7Zip to edit/modify the tar file without the file getting corrupt.
Finally I resorted did the unpacking and re-tarring via my Mac (with android sdk installed) to preserve id's etc.
** The following is just a simple guide, which worked for me, I made sure I had plenty of power on the phone and kept original states of my efs directory **
On my phone via 'adb shell'
Code:
$ su
# mkdir /sdcard/efsbck
# cd /
# busybox tar zcvf /sdcard/efsbck/orig-broke-efs.tar.gz efs
# exit
$ exit
On my mac
Code:
cd <where-ever-your-android-sdk-is>/platform-tools/
adb pull /sdcard/efsbck/orig-broke-efs.tar.gz
mkdir mod
sudo su
cd mod
sh-3.2# #*Note the 'p' on the tar to preserve the original id's etc on various files
sh-3.2# gunzip -c ../orig-broke-efs.tar.gz | tar xvpf -
sh-3.2# cd efs
sh-3.2# ls -ltra | grep nv_data
-rwx------ 1 1001 1001 32 31 Dec 2010 .nv_data.bak.md5
-rwx------ 1 1001 1001 2097152 31 Dec 2010 .nv_data.bak
-rwx------ 1 1001 1001 32 21 Sep 00:46 nv_data.bin.md5
-rwx------ 1 1001 1001 2097152 21 Sep 00:46 nv_data.bin
sh-3.2# rm nv_data.bin.md5
sh-3.2# rm nv_data.bin
sh-3.2# cp -p .nv_data.bak nv_data.bin
sh-3.2# cp -p .nv_data.bak.md5 nv_data.bin.md5
sh-3.2# cd ..
sh-3.2# tar cvf - efs | gzip -c - > mod-efs.tar.gz
a efstar: getpwuid(1001) failed: No such file or directory
a efs/.files
...
...
sh-3.2# ../adb push mod-efs.tar.gz /sdcard/efsbck/mod-efs.tar.gz
Then 'adb shell' back to the phone. I checked the tar file list was ok and wasn't corrupt.
Code:
$ su
# cd /sdcard/efsbck
# busybox tar ztvf mod-efs.tar.gz
Then for the final run, butt clenching bit, still on the phone via 'adb shell'
Code:
$ su
# cd /sdcard/efsbck
# umount /efs
# mke2fs /dev/block/mmcblk0p1
# mount -w -t ext4 /dev/block/mmcblk0p1 /efs
# ls /efs
lost+found
#
# busybox tar zxvf mod-efs.tar.gz -C /
# ls /efs
... check that the nv_data.bin is there ... and has radio radio id's
# exit
$ exit
Then after a reboot - Phone was still in 'airplane mode' - But went into settings - checked baseband - it was visible rolleyes ! , went to wireless network 'Flight Mode' was correctly green 'ticked', undid. And got my signal back.cool
I also had to re-activate data network settings for my GPS to sort itself out.
The procedure worked for me, I can't say it'll work for everyone.
Click to expand...
Click to collapse

[GUIDE] How to restore logd to your device/fix adb logcat read failure or empty logs

A few days ago, I flashed a zip onto my phone that set SELinux to permissive. However, there was a problem: it deleted logd, which is essential to adb logcat. Considering I'm an Android developer, that isn't a good thing! It took me a bit to figure out how to get it back, so I'm making this guide to share with you guys to help whatever poor soul has to fix this next.
Note that these steps were designed with Linux in mind, though they might be adaptable to Cygwin/OSX with some effort.
Also, make sure you delete any SELinux permissive scripts from init.d/su.d first!
Prerequisites
The OTA or custom rom zip that your device is currently running
adb
simg2img (available in the Ubuntu software repositories)
sdat2img (available here)
Instructions
Put your OTA/custom ROM zip file in a new folder and unzip it (this example is using the Pure Nexus ZIP):
Code:
mkdir restore_logd
cp pure_nexus_hammerhead-7.0-20161025-HOMEMADE.zip restore_logd
cd restore_logd
unzip pure_nexus_hammerhead-7.0-20161025-HOMEMADE.zip
Now, look for a file named either system.new.dat or system.img.
If you have system.img, then run:
Code:
simg2img system.img system.raw.img
If you have system.new.dat AND system.transfer.list, instead run:
Code:
sdat2img.py system.transfer.list system.new.dat system.raw.img
Either way, you should now have a file named system.raw.img. Next, mount it:
Code:
mkdir system_mnt
sudo mount -t ext4 -o loop system.raw.img system_mnt
This will mount the system image onto the system_mnt folder.
Plug in your device to your computer and make sure USB debugging is enabled, then run:
Code:
adb push system_mnt/bin/logd /sdcard/logd
adb shell
You should now be in a shell connected to your device. Inside, run:
Code:
su
mount -o rw,remount /system
cp /sdcard/logd /system/bin/logd
chmod 755 /system/bin/logd
exit
This will install the logd binary and close the shell.
This next part is very important! Making sure you closed the adb shell and are still inside the directory you created, run:
Code:
ls -Z system_mnt/bin/logd
If the output looks like this:
Code:
? system_mnt/bin/logd
then you have nothing else to do. Otherwise, it might look a bit like this:
Code:
u:object_r:logd_exec:s0 system_mnt/bin/logd
Copy part before the path; in this case, it's:
Code:
u:object_r:logd_exec:s0
Then, run:
Code:
adb shell su root chcon permission /system/bin/logd
replacing permission with the string you copied.
Now you can unplug and restart your device; logd should now be fully working!
Last but not least, run:
Code:
sudo fusermount -u system_mnt
to unmount the system image from your computer.
Enjoy!
Execute command failed while replacing permission
Code:
adb shell su root chcon permission /system/bin/logd
u:object_r:logd_exec:s0
/system/bin/sh: <stdin>[1]: u:object_r:logd_exec:s0: not found

Categories

Resources