Jump to content

[mod] [2011-03-22] TPT NAND Backup & Partition Tool - alpha3 [Gen1]


Recommended Posts

Guest samjam
Posted (edited)
cool, i tried that 0 padding thing you suggested, samjam, couldn't get it to work with hex, it just printed that number of 0's.

i'm going to release another update in a few days, with a few more options & some error checking.

Weird, on an adb shell I get:

$ printf "%06d\n" 23

000023

$ printf "%06x\n" 23

000017

[edit to fix cut-n-paste bug]

Edited by samjam
Posted (edited)
Weird, on an adb shell I get:

$ printf "%06d\n" 23

000023

$ printf "%06x\n" 23

000017

[edit to fix cut-n-paste bug]

weird, didn't work at all for me in the script, %08s printed 8 0s in front of the number & only the first one on the line worked. store a hex number, with letters, in a variable, like af & then try it. pretty sure i'd still need nested printf statements to pull the full thing off & it doesn't tidy it up much anyway. i think i'll just put it in an if statement, theres just one number that could possibly be 1, 2 or 3 hex digits long, that controls the size of the cache partition.

Edited by wbaw
Guest zaf_4
Posted

I am using CM7 nightly 23 and i am changing all the time...

i want to try it. I have to use only this file? --->blade_backup_alpha1.zip and then i will have extra mb?

My question is that if i ll change my rom again. I will have to do it again so not having probs when i download apk?

Cause that's what i understood.

Guest Schwinni
Posted
I am using CM7 nightly 23 and i am changing all the time...

i want to try it. I have to use only this file? --->blade_backup_alpha1.zip and then i will have extra mb?

That is correct. I just did that yesterday after flashing N23, although I used a self-modded version with SYSTEMPAD=80 instead of SYSTEMPAD=16.

My question is that if i ll change my rom again. I will have to do it again so not having probs when i download apk?

Cause that's what i understood.

That's a good question I also would like to have an answer for.

But I think that depends on the ROM and the installation type.

I think (!!!) that the CM7 installation via Clockwork preserves the partition layout and you do not have to apply blade_backup_alpha1.zip again.

But I'm not sure. Perhaps wbaw can answer that question.

Guest samjam
Posted
That is correct. I just did that yesterday after flashing N23, although I used a self-modded version with SYSTEMPAD=80 instead of SYSTEMPAD=16.

That's a good question I also would like to have an answer for.

But I think that depends on the ROM and the installation type.

I think (!!!) that the CM7 installation via Clockwork preserves the partition layout and you do not have to apply blade_backup_alpha1.zip again.

But I'm not sure. Perhaps wbaw can answer that question.

You are correct.

If you want to change your partition sizes you will need to edit inside the blade_backup_alpha1.zip and re-install it as an update, and then boot with +VOL again,

Posted
Weird, on an adb shell I get:

$ printf "%06d\n" 23

000023

$ printf "%06x\n" 23

000017

[edit to fix cut-n-paste bug]

%06x is converting the input (which it assumes is decimal) to hex. solved by giving it a decimal number & letting it convert to hex. i'm just tidying it up a bit for the alpha2 release.

should i set the default free space on system to 10mb? that should give plenty of room for installing updates to roms.

Guest KelticDaz
Posted (edited)

I'd like to try a 2.2 rom, what's the best way to reverse this procedure?

Edit: sorted it.

Edited by KelticDaz
Guest Frankish
Posted

I've never tried this as i never thought my apps would fit on still. Just done it and with my 70 apps i still have 95mb free. That's nice! Wonder how i would go back to stock partitions...not that i think i ever would.

Guest Rotmann
Posted
I've never tried this as i never thought my apps would fit on still. Just done it and with my 70 apps i still have 95mb free. That's nice! Wonder how i would go back to stock partitions...not that i think i ever would.

You flash the zip in the second post on page 4 :D

wbaw, mind putting that in the first post? Thanks.

Posted

new version soon (maybe later today), it will have more options, including returning to the stock partition sizes.

Guest KelticDaz
Posted
new version soon (maybe later today), it will have more options, including returning to the stock partition sizes.

Nice one! Look forward to using it with the excellent swedish spring 2.2 rom.

Posted
Nice one! Look forward to using it with the excellent swedish spring 2.2 rom.

I'm testing it today ... there will be 3 versions of alpha 2 & a few other options if you want to manually edit it

First version will be with 2mb cache partition & it should automatically patch 2.2 roms

Second version will have a standard sized cache partition

Third version will reset it to stock partition sizes

It'll give you 10mb free space on /system by default.

It'll be faster (only backs up system & userdata).

It'll also have plenty of error checking & improved code.

Features that didn't make it into alpha 2, but are planned to be added in alpha 3 will be full backup mode (including apps2sd) & preserve current partition sizes.

Then it needs a frontend.

I'm open to offers of help, otherwise it's going to take me a while to complete, paid work comes first.

Guest womble_sanfran
Posted (edited)

Good work wbaw, one question though, does the 2nd one that doesnt resize your cache partition (blade_backup_alpha2-cache-auto-10.zip) work on 2.1 (I am still on stock ROM)? My understanding is that it does work and it is just the bit that points the cache somewhere else that only works on 2.2.

EDIT: Also am I right in thinking that this only changes the bare minimum of the firmware that it has to in order to change the partitions? I was considering using the JJ9 TPT a while back but held fire as I didnt want all the hungarian firmware.

Cheers

Edited by womble_sanfran
Posted (edited)

Exactly right, womble. The second version that doesn't resize the cache partition should work for any rom with no extra patches. You will need clockworkmod 3 installed (3.0.0.6 or later).

It only uses the bare minimum .mbn firmware files needed to enable the TPT to work, just 4 small files, only 1 small hidden firmware file is actually modified & flashed to the phone, appsboot.mbn this tells the phone where all the android partitions are (among other things).

Edited by wbaw
Guest womble_sanfran
Posted
Exactly right, womble. The second version that doesn't resize the cache partition should work for any rom with no extra patches. You will need clockworkmod 3 installed (3.0.0.6 or later).

It only uses the bare minimum .mbn firmware files needed to enable the TPT to work, just 4 small files, only 1 small hidden firmware file is actually modified & flashed to the phone, appsboot.mbn this tells the phone where all the android partitions are (among other things).

Excellent, thanks for the reply, I will have a stab at this soon.

Posted

Another small update. It now stores a log file in the /sdcard/image directory. It also now detects if you have one of the newer 'Gen2' blades being sold with 2.2 stock roms in Sweden, Bulgaria, India, Japan & China, it wont work on those types of phones, so it will refuse to run at all on them now, rather than risk causing any damage.

Guest targetbsp
Posted

Awesome job! I've been scared of doing this until now but I just did a manual flash of 148mb* system keeping the cache which has got me a good bit more data space without having to worry about patching roms. Was a simple and painless (and faster than i was expecting) process.

*Out of paranoia I based the 148mb on adding your suggested 10mb cushion to the biggest rom I could find rather than my current rom in case you're wondering. I wanted to play it safe on my first go! :D

Guest jasonXXx
Posted
Exactly right, womble. The second version that doesn't resize the cache partition should work for any rom with no extra patches. You will need clockworkmod 3 installed (3.0.0.6 or later).

It only uses the bare minimum .mbn firmware files needed to enable the TPT to work, just 4 small files, only 1 small hidden firmware file is actually modified & flashed to the phone, appsboot.mbn this tells the phone where all the android partitions are (among other things).

In regaurds to the appsboot.mbn if i then did a complete wipe and installed a diff rom that could fit into the new partition what would happen as it would not have the appsboot.mbn file?

Guest womble_sanfran
Posted (edited)

Thanks for doing this wbaw, I did it just now using the 2nd method (blade_backup_alpha2-cache-auto-10.zip) to preserve my cache partition, it all worked fine and I went from having 39.4MB internal phone storage to 117MB. I am using a stock 2.1 ROM that I have rooted and removed loads of Orange junk so I am glad to now get some extra space back!

Here are before and after DF command outputs....

BEFORE:

C:\fastboot>adb shell df

/dev: 212440K total, 12K used, 212428K available (block size 4096)

/system: 212480K total, 121672K used, 90808K available (block size 4096)

/data: 213120K total, 170392K used, 42728K available (block size 4096)

/persist: 1536K total, 1156K used, 380K available (block size 4096)

/sqlite_stmt_journals: 4096K total, 0K used, 4096K available (block size 4096)

/cache: 42240K total, 20492K used, 21748K available (block size 4096)

/sdcard: 15542880K total, 7824888K used, 7717992K available (block size 8192)

AFTER:

C:\fastboot>adb shell df

/dev: 212440K total, 12K used, 212428K available (block size 4096)

/system: 134272K total, 121676K used, 12596K available (block size 4096)

/data: 291328K total, 170372K used, 120956K available (block size 4096)

/persist: 1536K total, 1156K used, 380K available (block size 4096)

/sqlite_stmt_journals: 4096K total, 0K used, 4096K available (block size 4096)

/cache: 42240K total, 1156K used, 41084K available (block size 4096)

/sdcard: 15542880K total, 8456344K used, 7086536K available (block size 8192)

To anyone else considering this I urge you to do it!

Thanks again wbaw!

Edited by womble_sanfran
Guest That-Guy
Posted

OK am I right in thinking I do it in the following order:

- Flash attached zip

- Install by doing the VOL + Method

- Install ROM of choice (CM7)

or do you do it this way:

- Install ROM of choice (CM7)

- Flash attached zip

- Install by doing the VOL + Method

If its the second method I take it you do it after a fresh install of your ROM before installing Apps etc??

Guest JayGB1982
Posted (edited)

I did it the 1st way a couple of days ago before the new release and it work fine.

Thanks for the extra internal space :D

EDIT* 1st not second lol

Edited by JayGB1982
Guest KelticDaz
Posted (edited)

Tried version 2, but didn't work for me. Image file created on the SD card with that text file you mentioned. It said cache = 41mb, system = 127mb, userdata = 288mb, but the real values are unchanged, ie I still have 208mb user ram. Current rom is Swedish Spring RLS2, LanceH version.

*edit*

Ignore the above, the process works perfectly, just me blanking the last bit of the instructions! D'oh!

Thanks to Womble for pointing it out and thanks again to wbaw for the program!

Edited by KelticDaz
Guest womble_sanfran
Posted
Tried version 2, but didn't work for me. Image file created on the SD card with that text file you mentioned. It said cache = 41mb, system = 127mb, userdata = 288mb, but the real values are unchanged, ie I still have 208mb user ram. Current rom is Swedish Spring RLS2, LanceH version.

Sounds like you did most of the process but you havent done the last step of turning the phone off and then turning it on with the vol + button held.

Guest KelticDaz
Posted
Sounds like you did most of the process but you havent done the last step of turning the phone off and then turning it on with the vol + button held.

Thanks, absolutely right, worked perfectly.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.