Related
I got a XDA new ROM which is 4.00.01. It's a BIN file. 32 MB. I don't know how to flash it. Anyone has ideas?
What's the exact size in bytes?
I have seen .bin files which start with the string 'B000FF'
you can use
Code:
perl splitrom.pl yourfile.bin -wo outfile.nb1 -t nb1
to convert it to nb1.
you can find splitrom.pl in the mkrom distribution archive.
splitrom understands several types of romimages.
Can I convert to NBF file? So that I can use PROGRAM A to install. Size is 33,555,995 bytes. It start with B000FF.
you must make sure there is either a bootloader in your .bin file,
or you get a bootloader from another source.
you can extract a bootloader from another nbf file using
Code:
perl splitrom.pl yournbf.nbf -wl bootloader.nb0
you must make very sure that your nbf really contains a bootloader, if it doesn't and programme a overwrites it with junk, you will have your self a brand new hightech paperweight.
a safer way to burn unknown images, is via an sd card + xdarit + bootloader mode.
What is the command to convert to NBF once I got the bootloader? When I try to extract the bootloader, I got the following message: "80000000 - 80040000 -- bootloader 0 files 1 modules". Does that mean no bootload information inside the NBF file?
that means you are looking at a file containing just a bootloader, no OS.
Code:
perl splitrom.pl yourfile.bin -rl bootloader.nb0 -wo outfile.nbf -t nbf -n PW10A1-ENG-3.17-001
to convert .bin + bootloader to .nbf
you can check the result again using
Code:
perl splitrom.pl outfile.nbf
Sorry about having so many questions. How can I make sure that the nbf really contains a bootloader? I use the NBF file from O2 UK RUU 3.17.03 to extract bootloader which under PROGRAM A folder. Can I use "perl splitrom.pl yourbin.bin -wl bootloader.nb0" to
extract the bootloader from my BIN file? I use UltraEdit to view the BIN file, I notice some information about bootloader 5.22 (not 5.17). The person give me this ROM said it's the PPC 2003 final. Actually I was given a HTC tool to flash the BIN file. But when I load the bin file, it checks my SD card and tells me invalid card. So I cannot flash directly.
well, that is a difficult question. in an ideal world we would have ready a list of bootloaders, and md5sums of these. for easy idendification. but not done that yet. su currently I look at the binary. and see if I see this line in the hexdump:
0000060: 4543 4543 0010 0a8c 0000 0000 0000 0000 ECEC............
and at about 0001580 there should be some lines with '*' and 'init debugserial...'
then it at least resembles something that looks like a bootloader, and not accidentally an os image. ( yes, that is a mistake we made fore you, leading us to abother intersting development : jtag flashing
5.22 is the latest I saw too.
so does your .bin file start with 'b000ff' ? can you maybe upload this file to
ftp://xda-developers.com ?
actually we noticed that somehow for recent roms the bootloader was not flashed by programme A. even though we managed to overwrite it with crap with one of our own experiments. possibly a different version of programme A. we have not researched this yet.
I would be interested in that htc program too.
you can only extract a bootloader from your .bin file if it contains one. .bin files may contain any memory region. so I don't know if yours does.
I saw the following information. So I believe it has bootloader.
0000060: 4543 4543 0010 0a8c 0000 0000 0000 0000 ECEC............
about 0001580 there should be some lines with '*' and 'init debugserial...'
I've done the following. I don't know if I'm right.
1. I run "perl splitrom.pl yourfile.bin -wl bootloader.nb0 -t nb0" to extracted the bootloader.
2. Run "perl splitrom.pl yourfile.bin -wo outfile.nb1 -t nb1" to extract OS.
3. Run "perl splitrom.pl yourfile.bin -rl bootloader.nb0 -wo outfile.nbf -t nbf -n PW10A1-ENG-4.00-001" to get NBF file. I got error message said romimage already has bootloader. So I run "perl splitrom.pl yourfile.bin -wo outfile.nbf -t nbf -n PW10A1-ENG-4.00-001" to convert to NBF file directly. I dont' know if this the right command to convert BIN to BNF file, but I didn't see any error.
4. I run "perl splitrom.pl outfile.nbf" to check and below is the result.
rommap: 80000000-81f00000
no xipchian found
no operator rim found
80000000 - 80040000 -- bootloader 0 files 1 modules
80040000 - 8015c5c8 -- kernel 5 files 5 modules
80180000 - 80376bd0 -- kernel 10 files 14 modules
80380000 - 8064306c -- kernel 20 files 36 modules
80670000 - 80be66a8 -- kernel 107 files 88 modules
80c80000 - 8102ce98 -- kernel 11 files 36 modules
81050000 - 813ef114 -- kernel 95 files 44 modules
81400000 - 815d2238 -- kernel 34 files 7 modules
815f0000 - 8171bc7c -- kernel 56 files 19 modules
817c0000 - 81adf390 -- kernel 109 files 40 modules
81980000 - 81925800 -- bitmap :30000be5 .. 010000ea
I tried to upload the file to your FTP. But no permission. Please PM your MSN Messenger ID, so that we can discuss more baout this ROM.
Thanks
I don't have msn, but you can find me on irc in #xda-developers on ircnet
( if you don't know a server: irc.nl.uu.net )
3: yes, that should work.
if you want to replace the exsisting bootloader, you can type "perl splitrom.pl outfile.nb1 -rl bootloader.nb0 -wo outfile.nbf -t nbf -n PW10A1-ENG-4.00-001"
4: ah, ppc2003 roms have a different structure splitrom cannot yet find
the xipchain in its new location. that is why it says 'kernel' on all lines.
also the bitmap it mentions is not the bitmap.
another issue may be that the nbf it creates has the wrong size, since
the xipchain in ppc2003 roms is in a location which was not originally
present in nbf files, I am not sure if programme a can write it correctly.
forgot to tell you the password: user=xdaftp pass=xdaftp
Replacing a corrupted bootloader via ActiveSync
I have a T-Mobile PPC Phone on which I have installed the AT&T radio stack and the XDA-Developers 1.1 ROM. All works well except for the fact that I appear to have corrupted the bootloader. The device now jumps directly into Windows CE and ignores any keys which I press when performing a soft reset.
From reading the rest of this thread it seems that I may be able to replace my corrupted bootloader via ActiveSync if I prepare an image file correctly. Is this true, or am I misunderstanding the ActiveSync upgrade process? As I can't reload from SD card, I'd be grateful for some expert advice before I go ahead - I can't afford to get it wrong!
Thanks,
Malcolm
Hi,
I've already upload the PPC2003 for XDA to your FTP. Please check your private message for the password for the ZIP file.
Thanks
since I have no chance to get sources for all kitchen tools, so i'v decided to write new svn repository with all tools
command:
svn co http://lrk-python.googlecode.com/svn htc-python
todo:
fdi - decompession of cabbed files - with help of cabsdk.exe ported to linux
xip - full port
tools witch are found working:
nbh2dbh
dbh2nb
osextract - on windows 32
part-os
target: linux-x64
usage - and what be discovered
steps:
ln -s uour file.nbh rom.nbh
xe1-nbh2dbh.py - converts rom.nbh to tempfile.dbh
xe2-bdh2nb.py - converts tempfile.dbh (from previus step) to : ) other formats, where one of them is *OS*
softlink this file to windows.nb
xe3-osextract -will decmpose windows.nb to partitions
- and here im flying
25 - sys partition
others - are xips - in simple case
am - seeking for volunters to do the other steps to fully decompile/recompile xip and friends
Hello all,
Since jockyw2001 was so nice to release Rose hardspl I spent the time finding official ROM's to test them out. In the process I extracted the radios from each & did a rebuild with pof's yang 1.1 using the following process:
Code:
1. Grabbed yang 1.1 from XDA
2. Extracted yang to a folder
3. Extracted RUU_signed.nbh from an official ROM exe file into yang folder using winrar
4. Opened CMD & went to yang folder
5. Ran yang -X RUU_signed.nbh (To extract all files)
6. Ran yang -F REBUILT_RUU_signed.nbh -t 0x301,0x200,0x600,0x400 -f 00_GSM_0x301.nb,01_SPL_0x200.nb,02_MainSplash_0x600.nb,03_OS_0x400.nb -s 64 -d ROSE***** -c 11111111 -v 1.00.000.0 -l WWE (To test SignMaxChunkSize. If rebuilt NHB is same size as original then we're golden otherwise I would have tried 1024 per the instructions)
7. Renamed 00_GSM_0x301.nb to GSM.nb (This step may not be necessary but I wanted to be safe & was pretty sure the original filename was GSM.nb)
8. Ran yang -F RADIO_RUU_signed.nbh -t 0x301 -f GSM.nb -s 64 -d ROSE***** -c 11111111 -v 1.00.000.0 -l WWE
9. Copied RADIO_RUU_signed.nbh to folder with CustomRUU.exe, renaming it to RUU_signed.nbh
10. Ran CustomRUU.exe to flash to phone & test, confirming it went on OK, had signal & radio version matched
NOTES: I set version to 1.00.000.0 to hopefully make it obvious this wasn't a full ROM but the fact it's 22MB should be pretty good indicator. I set Device ID/model to ROSE***** so it should go on any Rose. CID was set to 11111111 as shown per examples in yang instructions. Language was set to WWE although not sure that matters.
These radios are all from official shipped rom's that I found on XDA without anything changed other than using the procedure above. I tested them all on my S740 (installed & made sure I had a signal with TMobile SIM but no further testing was done) but USE AT YOUR OWN RISK. I can't be held responsible if you bork your phone or lose your data. The included CustomRUU.exe shouldn't require a hard reset but I'd highly recommend you backup just in case.
Here are the radio files:
S740RoseRadioAsia_12.23.30.06H_0.24.30.24 7.92MB
S740RoseRadioEurope12.23.30.06H_0.24.30.24 7.92MB
S740RoseRadioOrange_12.29.30.09H_0.29.30.22 8MB
S740RoseRadioRus_12.23.30.06H_0.24.30.24 7.92MB
S743RoseRadioBrightPoint_12.29a.30.12H_0.29.30.33 7.95MB
Hope these prove useful to someone.
Bill
** Super big thanks to jockeyw2001 for hardspl, pof for yang & to everyone else who posted up official roms to make this possible! **
good job!
2 roms came from me
With a little help of jockyw2001 I'm soon uploading non-brand us rom and hopefully u can extract it's radio and add it to your list
Soz, shout out to sasiskas for posting up 2 of the roms I used.
Yeah that would be cool but I've not been able to do radio from dump yet.. I did a rebuild of a Touch Dual NEON rom from a dump awhile back and it wasn't too fun but once you get the process down it's not so bad I suppose but it was rom only, no radio.
Hi Bill, thanks for your continued efforts.
One thing, and this is going to make me sound very thick, but I can't get the installer to run.
It reports that it fails to initialise. Should this be run on the phone or on a PC.
lol, told you i'd sound stupid, lol
Hey Jerry-S,
You plug the phone into USB & run the flasher on the computer which uses active sync to update the phone, just like flashing any ROM.
Btw, in case you are not caught up I am pretty sure your phone needs jocky's hardspl installed 1st. I say that because that gets installed the same way as these radios & if you're lost doing the radio odds are you didn't do the hardspl yet.
Bill
mods please sticky the thread
I don't know why, but a file CustommRUU.exe is not working on my computer. It is said "initialization error" when I start it.
why should i install this rom to a perfectly working phone?
gives it advantages, or stability?
wuwa said:
why should i install this rom to a perfectly working phone?
gives it advantages, or stability?
Click to expand...
Click to collapse
yes it is definitely to boost device performance....
On which of RadioROM, you can select the COM port to work with GPS?
Newbie doubt
Hello
I'm new in these things, so I would like to help.
Will soon acquire an HTC S743, but has two problems. One is that language is not in Portuguese, the other is the FM radio does not work, the icon does not even appear to turn it on.
Did any of the roms posted here I solved the problem? and even now, like flashing my HTC S740?
I await response
João Serra
Hi everybody! I bought some weeks ago a Shift and my first priority is to change the language from Italian to English. But before going ahead in flashing a new rom I thought it is wise to make a back-up of the original rom.
So in my attempt to dump the original italian rom of my Shift I've come to an error status I don't know how to overcome, therefore any help would be very much appreciated:
Following pof's How to dump HTC Shift ROM at
http://forum.xda-developers.com/showthread.php?t=382609
I downloaded itsutils, unzipped on the pc and placed all the itsutils files in the c:\users\HTC User folder, (as I just did not know how to change the path in cmd to go to the c root with the itsutil folder).
Further on, with the WinMob connected to Vista with USB Tool, I introduced the first command line for pdocread
pdocread.exe -w -d FLASHDR -b 0x800 -p Part00 0 0x31f000 Part00.raw
and I got the answer
Copying c:\users\HTC User\itsutils.dll to WCE:\Windows\itsutils.dll (which I think it's OK) and then
rapi reinitializing (is it normal?)
and then
ERROR: CeProcessConfig – r=002349d0 ce=00000002 le=00000000 hr=80070005
– Access is denied
I have no idea on what the cause of the error could be, probably I must have done something wrong and I am stuck at this first dump step.
Can somebody please help me further to get unstuck?
Thank you very much!
Are you connected using activesync?
Also, try this guide:
http://forum.xda-developers.com/showthread.php?t=427507
and use pdocread -l first.
thaihugo said:
Are you connected using activesync?
Also, try this guide:
http://forum.xda-developers.com/showthread.php?t=427507
and use pdocread -l first.
Click to expand...
Click to collapse
THANK YOU THAIHUGO for taking the glove of answering me on this dead forum, I really need help! I find it fantastic that you are still so active, maybe in time some other senior members will take again the challenge to support the newcomers.
Yes, WM was connected to Vista side using the USB Tool and the Windows Mobile Device Center.
Looking back, I think I opened cmd as user and not as admin (now I know how to do it), this might have been the mistake, I will try again this afternoon.
1. So far I understood that the main reading process is running under Vista using the command lines and the itsutils, which is ok.
Does it matter where the unzipped folder <itsutilsbin-20100324> is placed? I mean should it be placed obligatory in the root of the c:\ drive?
If YES, how do I do that in the cmd line, I mean change the directory? Normally the cmd screen opens to the folder c:\users\HTC User when starting as user and to c:\Windows\system32 when doing it as administrator. Is it wise to copy all the itsutils files to system 32?
Of all those itsutils files, which are the absolutely necessary files to do the dump? Are these pdocread.exe and itsutils.dll only? This is because I'd like to handle as less files as possible to the system 32 folder.
2. If I got this right, the link that you pointed to shows for the Raphael ROM how to do the dump entirely on the WM side and should be applicable to the Shift WM as well if not managing it from Vista side, is that what you were trying to say?
3. Is this way of dumping the rom covering also the radio part and the bootloader, I mean all the 4 raw files contain the whole initial memory of the WM?
Sorry to raise such beginners question, but I did not find these things explained in any of the Shift threads and without answers I cannot progress with this dump job and furtehr proceed with flashing a custom rom in English. I did search in the Shift forums and googles for answers, but maybe I did not use the right keywords.
Looking forward to receive the enlighting answers, thanks in advance!
Admin cmd mode should help yes.
1) it doesn't matter where your zip is. Just uncompress the files somewhere in a folder (c:\itsutils if you want), open you command line in admin mode, navigate from system32 folder to the itsutils folder and try again with the pdocread -l then the command from POF post.
2) do not use raphael numbers. I linked to the post for the general procedure. Proper numbers are in the POF post.
3) you will not have the radio, nor the bootloader. But you have to jump if you want to use custom roms. Bootloader is available somwhere, and radio also I think.
Still getting errors
thaihugo said:
Admin cmd mode should help yes.
1) it doesn't matter where your zip is. Just uncompress the files somewhere in a folder (c:\itsutils if you want), open you command line in admin mode, navigate from system32 folder to the itsutils folder and try again with the pdocread -l then the command from POF post.
Click to expand...
Click to collapse
Thank you again Thaihugo!
I gave it another try to pof's commands as you recommended this time first with pdocread -l and it doens't work, BUT I'm getting the similar error messages. While accessing cmd as administrator and running the cmd line from c:\itsutils:
pdocread.exe -l
rapi reinitializing
and then after about 35 sec
ERROR: CeProcessConfig – r=002349d0 ce=00000002 le=00000000 hr=80070005 – Access is denied
At different runs I got different addresses for r and ce, but the same for le and hr (no idea what those mean).
It doesn't change if launching as administrator or user.
I even downloaded a previous version of itsutils directly on the Vista computer and unzipped it with Total Commander and the result is the same.
Have also tried another command from pof with the same error result:
pmemdump.exe 0x8c000000 262144 SPL.nb
Of course the WM side was connected to Vista via USB Tool and I also checked if from the Vista side the WM folders were accessible.
I'm completely stuck, don't know what to do further, please help!!!
Thank you!
P.S. Have copied the itsutils.dll to the Windows folder in WM via e-mail, just like in the liberalization process in order to avoid copying it via Active sync (as recommended for Raphael). This time at the first run of the pdocread.exe I was asked to accept installing itsutils.dll on the WM side, which I did.
But I'm still getting the error messages when launching pdocread.exe -l, this time running very fast in a few seconds and after 4 turns it stops with the final message
ERROR loading itsutil.dll - probably denied by policy restrictions
Does it ring any bell to you?
My guess is that I have to relax the security policy on the WM side, but I don't know how.
I am amaized that nobody raised all these before.
I've finally done it! HowTo......
OK, I finally managed to dump the ROM thanks to the support of Thaihugo and the info in various threads on this forum (with credit to the authors), I have now the ROM and bootloader dump files, but not the radio rom.
There were several detailed steps important for beginners that were not included in POF's thread "How to dump HTC Shift ROM" at http://forum.xda-developers.com/showthread.php?t=382609 that prevented me to do the dump from the first go.
In order to spare other newcomers time, here they are:
-On the WinMob side change the Security Policies setting by installing a registry editor like PHM Registry Editor, TotalCommander, etc. (I used the cab files downloaded in Vista and moved to WinMob via the Windows Mobile Device Center);
Go to HKLM\Security\Policies\Policies and change the valuename '00001001' from dword:2 to dword:1. Save the change and soft reset your WM device.
If in doubt check this: http://forum.xda-developers.com/showthread.php?t=427507
Note: After finishing the dump operation do not forget to revert back to the initial dword:2 value
-Download itsutils from POF's site to Vista and unzip the package to a new folder "c:\itsutils".
-To be on the safe side disconnect all network connections (3G modem, wifi, BT, LAN) and all USB external devices.
-Connect the WinMob side of the liberated Shift to Vista using the USB Tool and check in the Windows Mobile Device Center that the folders and files of WinMob are indeed accessible from Vista
-Open the command line screen and go to the folder where you unzipped the itsutils tool by typing "cd c:\itsutils" (without the quotes).
-From within the folder itutils type the command "pdocread -l" (without the quotes).
At this point, with pdocread.exe started, go to the WinMob side and
you will find a message asking you to accept installing the itsutils.dll on the WM side, say Yes to it and wait until it is instelled.
Then go back to Vista side and carry on as described in POF's thread mentioned above by:
- using "pdocread.exe -l" to list the NAND PARTITIONS (which have to do also with the radio side as I understood from one of cmonex posts)
- using "pdocread.exe -w -d FLASHDR -b 0x800 -p Part00 0 0x31f000 Part00.raw" and the other 3 commnads to generate the 4 raw files in the same folder c:\itsutils; keep them for reconstructing the original ROM
- using "pmemdump.exe 0x8c000000 262144 SPL.nb" to dump the bootloader file to the same folder c:\itsutils; keep that too.
That's it for now.
I have to deal further with dumping the radio rom, but I don't know how to do it, I must search the forums.
A big THANK YOU to all who helped me!
I never dumped a Radio. I think the experts keep this as secret because it's quite dangerous. Isuggest you have a look at your radio version and try and fin the same radioin the forum already dumped.
Otherwise, there are roms for each radio, so you could just simply apply the one that works wth your radio. No phone call though if you don't use the right one.
thaihugo said:
I never dumped a Radio. I think the experts keep this as secret because it's quite dangerous. Isuggest you have a look at your radio version and try and fin the same radioin the forum already dumped.
Otherwise, there are roms for each radio, so you could just simply apply the one that works wth your radio. No phone call though if you don't use the right one.
Click to expand...
Click to collapse
Thank you again Thaihugo, it seems that you are the only senior left on duty on this dead forum....yet the counter shows 238 views of this thread. Hm, strange....Anyway, thank you for all the good hints given one way or another during the past days, I wouldn't have made it without it.
I got the message, I will not bother with dumping the Radio. I know that a particular Rom is matched with a certain radio. I will flash one of your roms, most probably Age of Reasons and the associated radio. I am not looking for tens of programs on the WM side, it is enough to have the basic things in English and instant-on. I will let you know!
Good morning family!
It's my very first time posting in this subforum, but I think this tutorial was actually something needed, since all threads everyone can found while Googling are quite old (like, from the Xperia S times ), and also I'm quite tired of infinite threads like this and this, so...
Today I bring you an extensive and unified guide on how to extract ANY SYSTEM FILE from a FlashTool's Firmware (FTF), whether it's from the userdata.sin or from the system.sin.
Since this is going to be a guide for all OSes, there are some programs you'll need in general,
Latest version available of FlashTools (for SIN dumping purposes).
A reader tool for the extracted image, which can be:
An EXT4 reader / mounter.
An Unyaffs2, if you're using this guide for an old device (like the already mentioned Xperia S, and older).
Some cups of coffee, and lots of patience [IMPORTANT].
But, some of them will be platform specific, so the thread will split in:
2nd post: WINDOWS
3rd post: LINUX
4th post: OSX
Here you've a video tutorial showing the whole process for the 3 OSes:
If you're enjoying it, don't forget to press Thanks button and rate this thread!
WINDOWS GUIDE
Step 1 - Extract the SIN we need
Using your favourite archive manager (WinRAR, 7-Zip, etc), open the FTF you want to extract the files from. (FYI: an FTF is just a Zip file with renamed extension)
Now copy/extract the SIN you want to unpack to a folder of your preference.
Step 2 - Dump the SIN
I'll take into account you already had installed Flashtools and Java JRE, in which case I highly encourage you to update both to the latest version available.
Now, open Flashtools. Click on Tools, Sin Editor. Hit the [...] and locate the SIN you previously extracted. Now, hit the [Extract Data] button. After a couple of minutes the bar should start running.
Once finished, you can have 2 kind of files: a .yaffs2 or a .ext4/.ext3/.ext2 file, which require different procedures on how to see it's contents.
Step 3.a - Convert the file to a readable format - UnYaffs2
If the file you get is a .yaffs2 format file, you're going to need to extract it. For doing so, you need this tool, which contains a executable and a cygwin dll.
Extract this .rar contents to the very same folder where you placed the SIN, and thus, where the .yaffs2 is located.
Now, while you're in that folder press the shift key in your keyboard, and while you keep pressing it, right click on a blank space in that folder. In the menu choose Open a Command Prompt here.
To end the proccess, type
Code:
unyaffs2.exe [COLOR="DarkOrchid"]<the-name-of-the-yaffs2>[/COLOR]
Where <the-name-of-the-yaffs2> you must type the file name of the yaffs2 (e.g. system.yaffs2)
The files will get extracted and you'll be able to pick the ones you need.
Step 3.b - Mount the image - Linux Reader
There're many many tools to mount a EXT format image in Windows, but in this case, I'll use the Diskinternals Linux Reader, since it's free and it's compatible with all 3 possible formats you can encounter: .ext4/.ext3/.ext2.
Download it from here and install it. (It must be this version, since newer ones are broken.)
Once done, you should be perfectly able to double-click-to-mount the EXT file Flashtools generated without any trouble.
LINUX GUIDE
Step 1 - Extract the SIN we need
Using your favourite archive manager (Ark, Peazip, etc), open the FTF you want to extract the files from. (FYI: an FTF is just a Zip file with renamed extension)
Now copy/extract the SIN you want to unpack to a folder of your preference.
Step 2 - Dump the SIN
I'll take into account you already had installed Flashtools and Java JRE, in which case I highly encourage you to update both to the latest version available.
Now, open Flashtools. Click on Tools, Sin Editor. Hit the [...] and locate the SIN you previously extracted. Now, hit the [Extract Data] button. After a couple of minutes the bar should start running.
Once finished, you can have 2 kind of files: a .yaffs2 or a .ext4/.ext3/.ext2 file, which require different procedures on how to see it's contents.
Step 3.a - Convert the file to a readable format - UnYaffs2
If the file you get is a .yaffs2 format file, you're going to need an extra tool to extract it. For doing so, you are going to need the unyaffs2 tool.
You can download a pre-compiled binary from here, or you can compile your own using GCC with the source code, the header and the code below inside a Terminal (Ctrl+Alt+T to open it).
Code:
gcc -o unyaffs unyaffs.c
Once you've a working UnYaffs2 binary, just copy it to the very same folder where you placed the SIN, and thus, where the .yaffs2 is located, and type in a Terminal (Ctrl+Alt+T to open it).
Code:
cd [COLOR="DarkOrchid"]<file-route-of-the-sin>[/COLOR]
./unyaffs2 [COLOR="Blue"]<the-name-of-the-yaffs2>[/COLOR]
Where <file-route-of-the-sin> is where the SIN was located, and where <the-name-of-the-yaffs2> you must type the file name of the yaffs2 (e.g. system.yaffs2)
The files will get extracted and you'll be able to pick the ones you need.
Step 3.b - Mount the image
Since we're already in Linux, mounting a EXT image is not that hard. Just mount it using this commands in a Terminal (Ctrl+Alt+T to open it).
Code:
cd [COLOR="DarkOrchid"]<file-route-of-the-sin>[/COLOR]
mkdir android
sudo mount -t ext[color="RED"]*[/color] -o loop <name-of-the-image> android/
Where <file-route-of-the-sin> is where the SIN was located, where <the-name-of-the-image> you must type the file name of the ext image (e.g. system.ext4), and finally, where ext*, replace * with the version number of the EXT image you're mounting, usually, ext4
Now, once finished, to unmount it, type in a Terminal.
Code:
sudo umount android
rm -fr android
OSX GUIDE
Step 1 - Extract the SIN we need
Using your favourite archive manager (UnRarX, ZipEg, etc), open the FTF you want to extract the files from. (FYI: an FTF is just a Zip file with renamed extension)
Now copy/extract the SIN you want to unpack to a folder of your preference.
Step 2 - Dump the SIN
I'll take into account you already had installed Flashtools and Java JRE, in which case I highly encourage you to update both to the latest version available.
Now, open Flashtools. Click on Tools, Sin Editor. Hit the [...] and locate the SIN you previously extracted. Now, hit the [Extract Data] button. After a couple of minutes the bar should start running.
Once finished, you can have 2 kind of files: a .yaffs2 or a .ext4/.ext3/.ext2 file, which require different procedures on how to see it's contents.
Step 3.a - Convert the file to a readable format - UnYaffs2
If the file you get is a .yaffs2 format file, you're going to need an extra tool to extract it. For doing so, you are going to need the unyaffs2 tool.
You can download a pre-compiled binary from here, or you can install your own using Brew. From a Terminal (Command+Space, then type in Terminal) type the following commands.
Code:
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null 2> /dev/null #This is just to Install Brew for the first time. If you already have it, it's not needed.
brew install unyaffs
If you chose using the UnYaffs2 binary, copy it to the very same folder where you placed the SIN, and thus, where the .yaffs2 is located.
If you chose the Brew installation, just continue.
Now, type in a Terminal (Command+Space, then type in Terminal).
Code:
cd [COLOR="DarkOrchid"]<file-route-of-the-sin>[/COLOR]
unyaffs2 [COLOR="Blue"]<the-name-of-the-yaffs2>[/COLOR]
Where <file-route-of-the-sin> is where the SIN was located, and thus, where the yaffs2 file is located; and where <the-name-of-the-yaffs2> you must type the file name of the yaffs2 (e.g. system.yaffs2)
The files will get extracted and you'll be able to pick the ones you need.
Step 3.b - Mount the image - Ext4FUSE
There're many many tools to mount a EXT format image in OSX, but in this case, since we don't need RW access, but just RO, I'll use ext4fuse, since it's free and it's more than compatible with our needs.
To install it you'll need Brew. To get things ready, type the following commands in a Terminal (Command+Space, then type in Terminal).
Code:
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null 2> /dev/null #This is just to Install Brew for the first time. If you already have it, it's not needed.
brew tap homebrew/fuse
brew install Caskroom/cask/osxfuse
brew install ext4fuse
If you're on OSX Yosemite, El Capitan, or Leopard, you may need an extra command to add yourself to the Operator group, so that you can have readonly permissions to the disks.
Use it only if you get an error while trying to access the mounted EXT image later.
Code:
sudo dscl . append /Groups/operator GroupMembership [COLOR="red"]<your-user>[/COLOR]
Where your user <your-user> is your username.
Now, to mount the ext4 image, type in a Terminal (Command+Space, then type in Terminal).
Code:
mkdir android
ext4fuse [COLOR="DarkOrchid"]<path-to-the-ext4-image>[/COLOR] android
Where <path-to-the-ext4-image> you must type in the full path where the SIN was located, and thus, where the EXT4 image is located.
Use this as reference.
Reserved
In case I need it
Great job! Keep up the good work!!
Well. great guide.
Just a note, Microsoft officially released Bash on Ubuntu on Windows yesterday. Try it. It's a full fledged Linux subsystem but unfortunately only available to Windows Insiders. It would be the best alternate to cygwin.
Boot.img
How can i extract the boot.img
or is this applicable to every single .sin file present in the .ftf file
serajr said:
Great job! Keep up the good work!!
Click to expand...
Click to collapse
Thank you, I appreciate your words
mfbcool said:
Well. great guide.
Just a note, Microsoft officially released Bash on Ubuntu on Windows yesterday. Try it. It's a full fledged Linux subsystem but unfortunately only available to Windows Insiders. It would be the best alternate to cygwin.
Click to expand...
Click to collapse
I know, I saw the demonstration in the //build/, but since it hasn't been released for all yet (I guess it'll be for Redstone 2?), I didn't saw it necessary to be included.
sandeep.sethi said:
How can i extract the boot.img
or is this applicable to every single .sin file present in the .ftf file
Click to expand...
Click to collapse
No, this is only applicable for system.sin, userdata.sin, cache.sin and probably modem.sin.
However, if many of you request it, I could try making another for the kernel (boot.img)... But remember, every device doesn't have the same way/method to unpack the kernel, so making a generic tutorial for all wouldn't be possible
No, this is only applicable for system.sin, userdata.sin, cache.sin and probably modem.sin.
However, if many of you request it, I could try making another for the kernel (boot.img)... But remember, every device doesn't have the same way/method to unpack the kernel, so making a generic tutorial for all wouldn't be possible
Click to expand...
Click to collapse
if u can provide the guide it would be very helpful :fingers-crossed: :fingers-crossed:
This thread got featured in XDA Portal, thank you guys!
I tried extracting Xperia Pro's system SIN (can't remember the exact name but the one with the largest file size) using the latest version of Flashtool but wasn't successful. Like it's not supported yet.