Jump to content


Photo

[GEN2] Proper Gen2 TPT Generator/Extractor

* * * * - 3 votes

  • Please log in to reply
25 replies to this topic

#1
fonix232

fonix232

    Addict

  • Members
  • PipPipPipPipPip
  • 942 posts
  • Location:Hungary, Debrecen
  • Devices:ZTE Blade [TFT 512RAM]
  • Twitter:@fonix232
FOR EXPERIENCED USERS ONLY!

With a lot of help from my friend CodeNeos and based on cpg's research, I present you, the easy-to-use, informative, Gen2 TPT extractor/generator!

This simple tool makes life easy - not just extract and repack on the blind, see all the information you need!
Everything ordered on a nice UI, easy to use, yet effective, fast, and powerful!

Features:
- Extract any BIN file
- Create a BIN file from MBN and IMG files (partition and partition_zte mbn's are required, tool checks for that)
- See a content of a BIN TPT update without extracting it
- Extract only selected files

Coming:
- Partition editor for Gen2 firmwares
- YAFFS2 browser to go deeper!
- A nice all-in-one GUI

To work, these tools require .Net4!


Attached File  generator.PNG   32.16KB   258 downloads

Attached File  extractor.PNG   40.38KB   271 downloads
Your look may differ from the seen - although should be almost the same as on the pictures.


Changelog:
2011.05.15 - V1.1
- Extractor: Extract selected function

2011.05.15 - V1.0
- Initial release




WARNING
This tool is NOT for beginners, or intermediates. This is to help the life of the developers, so, if you DON'T KNOW what you're doing, STOP NOW. Do NOT even download it.
Also, do NOT mix Gen1 and Gen2 TPT files, only if you know what you're doing! It is EXTREMELY DANGEROUS!
I do not take any warranty if your phone bricks, burns, explodes, barkes from using this tool. You've been warned.

Attached File  Gen2_TPT.zip   24.01KB   1258 downloads -- MD5: 1e4bd2d4e1bec3cc144c8e32943ef34c

Edited by fonix232, 15 May 2011 - 09:55 AM.

  • 3
If you like my work, invite me for a drink or two!

Also, take a look at my Blade-dedicated site too! fonix232.co.cc

#2
wbaw

wbaw

    account closed

  • Banned
  • PipPipPipPipPipPip
  • 1,885 posts
  • Gender:Not Telling
But cpg's tool is much easier to use & will compile for any system. I don't see the point in this at all.

http://android.modac...p...t&p=1693458

  • 0

#3
fonix232

fonix232

    Addict

  • Members
  • PipPipPipPipPip
  • 942 posts
  • Location:Hungary, Debrecen
  • Devices:ZTE Blade [TFT 512RAM]
  • Twitter:@fonix232

But cpg's tool is much easier to use & will compile for any system. I don't see the point in this at all.

http://android.modac...p...t&p=1693458


cpg's tool has no security checks (this one has, and more coming, take a look at the upcoming features), and it's not GUI based. With this, you can see everything about the BIN file, without even extracting it!

  • 0
If you like my work, invite me for a drink or two!

Also, take a look at my Blade-dedicated site too! fonix232.co.cc

#4
hedgepigdaniel

hedgepigdaniel

    Addict

  • Members
  • PipPipPipPipPip
  • 850 posts
  • Gender:Male
  • Location:Sydney, Australia
  • Devices:Galaxy Nexus, ZTE Blade (OLED)
I think this is an excellent idea.
Being able to edit the contents of .img files and editing the partition layout with a GUI would be awesome

I tried it with the China Unicom update. taking the original image.bin, and using this tool to go to TPT files and then back to another image.bin, the two image.bin's are not identical. If i take the TPT files I extracted and then go TPT>image.bin>TPT then the TPT fiels are identical.
If i convert the Comviq TPT files to image.bin and back they are identical, but cefs.mbn is missing. Is this intended/why?

  • 0

#5
fonix232

fonix232

    Addict

  • Members
  • PipPipPipPipPip
  • 942 posts
  • Location:Hungary, Debrecen
  • Devices:ZTE Blade [TFT 512RAM]
  • Twitter:@fonix232

I think this is an excellent idea.
Being able to edit the contents of .img files and editing the partition layout with a GUI would be awesome

I tried it with the China Unicom update. taking the original image.bin, and using this tool to go to TPT files and then back to another image.bin, the two image.bin's are not identical. If i take the TPT files I extracted and then go TPT>image.bin>TPT then the TPT fiels are identical.
If i convert the Comviq TPT files to image.bin and back they are identical, but cefs.mbn is missing. Is this intended/why?


The bin files won't be identical as the file order isn't hardcoded (except for partition.mbn and partition_zte.mbn). But the files in the BIN are identical, just in another order (check cpg's layout, and do a diff on the header, you'll see what I mean!)
Cefs.mbn is missing because a, it isn't flashed by TPT b, it caused the IMEI problem with the EXE downgrade.

  • 0
If you like my work, invite me for a drink or two!

Also, take a look at my Blade-dedicated site too! fonix232.co.cc

#6
hedgepigdaniel

hedgepigdaniel

    Addict

  • Members
  • PipPipPipPipPip
  • 850 posts
  • Gender:Male
  • Location:Sydney, Australia
  • Devices:Galaxy Nexus, ZTE Blade (OLED)

The bin files won't be identical as the file order isn't hardcoded (except for partition.mbn and partition_zte.mbn). But the files in the BIN are identical, just in another order (check cpg's layout, and do a diff on the header, you'll see what I mean!)
Cefs.mbn is missing because a, it isn't flashed by TPT b, it caused the IMEI problem with the EXE downgrade.


OK, makes sense. is cefs.mbn not flashed by an image.bin either?

  • 0

#7
fonix232

fonix232

    Addict

  • Members
  • PipPipPipPipPip
  • 942 posts
  • Location:Hungary, Debrecen
  • Devices:ZTE Blade [TFT 512RAM]
  • Twitter:@fonix232

OK, makes sense. is cefs.mbn not flashed by an image.bin either?


Nope, it is only flashed by the ZTE flashing tool (any EXE installer).

  • 0
If you like my work, invite me for a drink or two!

Also, take a look at my Blade-dedicated site too! fonix232.co.cc

#8
anglergab

anglergab

    Newbie

  • Members
  • Pip
  • 3 posts
Hi!

1. Are the firmware updates distributed in some countries in the form of image.bin files? In Hungary, I haven't heard about image.bin files. You are from Hungary as well, so could you explain a bit about this image.bin format and its usage?
2. Do you think that the amss.mbn from the Hungarian T-Mobile Froyo update exe (sysdy\files) can be put into wbaw's Gen1 -> Gen2 TPT without bricking the phone? (in wbaw's TPT one can find the Swedish radio mbn, I'd like to have the Hungarian one on my Blade).

  • 0

#9
fonix232

fonix232

    Addict

  • Members
  • PipPipPipPipPip
  • 942 posts
  • Location:Hungary, Debrecen
  • Devices:ZTE Blade [TFT 512RAM]
  • Twitter:@fonix232

Hi!

1. Are the firmware updates distributed in some countries in the form of image.bin files? In Hungary, I haven't heard about image.bin files. You are from Hungary as well, so could you explain a bit about this image.bin format and its usage?
2. Do you think that the amss.mbn from the Hungarian T-Mobile Froyo update exe (sysdy\files) can be put into wbaw's Gen1 -> Gen2 TPT without bricking the phone? (in wbaw's TPT one can find the Swedish radio mbn, I'd like to have the Hungarian one on my Blade).


1. The image.bin format is used on already-Gen2 phones (like the chinese Blade, it got an update, that's where from we know the file format). The Gen1-Gen2 transition was an exe as it needed to repartition the modem areas too - that's why it could not be done via a simple TPT. This is basically the same as the normal TPT, just in one file. Usage is same, put into /sdcard/image, pull battery, switch on with holding Menu, VolUp, and Power, a bar will appear, and when finished it'll reboot. Done :unsure:

2. I guess you can but you should ask wbaw about it, if it was changed or not!

  • 0
If you like my work, invite me for a drink or two!

Also, take a look at my Blade-dedicated site too! fonix232.co.cc

#10
hecatae

hecatae

    Hardcore

  • Moderator Team
  • PipPipPipPipPipPip
  • 3,234 posts
  • Gender:Male
  • Location:northampton
  • Devices:Samsung i9305
  • Twitter:@meritez
thank you for this, running official froyo for t-mobile hungary at present, perfect for testing this with

  • 0

#11
ThrashMan

ThrashMan

    Diehard

  • MoDaCo Silver
  • PipPipPipPip
  • 464 posts
  • Gender:Male
  • Location:Miserable old git!
  • Devices:ZTE Blade [UK 512MB TFT]
I have no idea what any of the above means, but I thank you for your (and CodeNeos') work.

  • 0

#12
Jekle

Jekle

    Addict

  • Members
  • PipPipPipPipPip
  • 555 posts
  • Gender:Male
  • Devices:OSF, Galaxy Ace, Ascend G300

Hi!

1. Are the firmware updates distributed in some countries in the form of image.bin files? In Hungary, I haven't heard about image.bin files. You are from Hungary as well, so could you explain a bit about this image.bin format and its usage?
2. Do you think that the amss.mbn from the Hungarian T-Mobile Froyo update exe (sysdy\files) can be put into wbaw's Gen1 -> Gen2 TPT without bricking the phone? (in wbaw's TPT one can find the Swedish radio mbn, I'd like to have the Hungarian one on my Blade).

I replaced the amss.mbn and amsshd.mbn yesterday but make sure you keep them together, I think the Hungarian amss gives me 1-2 bars in a dead spot (before) I had the Swedish one and I got no signal, it's well worth doing.

  • 0

#13
t0mm13b

t0mm13b

    Hardcore

  • MoDaCo Silver
  • PipPipPipPipPipPip
  • 1,784 posts
  • Gender:Male
  • Location:Ireland
  • Devices:GT-S8500,Zte Blade,SE ST15i
  • Twitter:@t0mm13b
Just like to voice my input into this:

I think you should revert back to using Windows 2 Forms instead of WPF which is a disgusting code bloat and slow and a hog. Not alone that - targetting .NET 4 is overkill - should realistically target .NET 2 at the minimum for those who may not have the horsepower to run WPF apps. Thing is, personally, I would not download the .NET 4 runtime just to run your app. Always aim for the minimum spec for the wider audience and not just for you and your own machine which has more horsepower than the average blade hacker, a good chance that the average blade hacker runs on a Linux platform :unsure:

Just my 2cents :)

  • 0
try{ not_laugh; }catch{ FAIL; }finally{ laugh; }

#14
wbaw

wbaw

    account closed

  • Banned
  • PipPipPipPipPipPip
  • 1,885 posts
  • Gender:Not Telling

Just like to voice my input into this:

I think you should revert back to using Windows 2 Forms instead of WPF which is a disgusting code bloat and slow and a hog. Not alone that - targetting .NET 4 is overkill - should realistically target .NET 2 at the minimum for those who may not have the horsepower to run WPF apps. Thing is, personally, I would not download the .NET 4 runtime just to run your app. Always aim for the minimum spec for the wider audience and not just for you and your own machine which has more horsepower than the average blade hacker, a good chance that the average blade hacker runs on a Linux platform :unsure:

Just my 2cents :)


I agree, cpg's tool was much better. It just needs a simple android gui frontend really. The code he posted compiles easily for any platform, you just need gcc.

There's a good chance that somebody that wants to run this has a zte blade, so something that runs on the zte blade would be the obvious choice.

Edited by wbaw, 15 May 2011 - 04:39 PM.

  • 0

#15
hedgepigdaniel

hedgepigdaniel

    Addict

  • Members
  • PipPipPipPipPip
  • 850 posts
  • Gender:Male
  • Location:Sydney, Australia
  • Devices:Galaxy Nexus, ZTE Blade (OLED)
Ok, this program has much steeper and more specific requirements than cpg's code. But its requirements are hardly out of this world - I would say most people's computers run windows and wouldn't have a problem with this. I find that getting all the .net runtimes becomes inevitable after a while anyway. This program is distributed in compiled form, which makes life much easier for alot of people who don't have a compiler handy, and it has a GUI, which makes it much more convenient to use. If it supports automatic partition layout editing (and potentially automatic manipulation of anything else that can be done by editing a .mbn) then it has a lot of capabilities that cpg's tool doesn't. A simple GUI based tool could replace compiling your own program, running it from the command line, learning about the structure of .mbn files, and hex editing them. Besides all that, cpg's tool is still there for anyone to use, if they prefer it.

  • 0

#16
fonix232

fonix232

    Addict

  • Members
  • PipPipPipPipPip
  • 942 posts
  • Location:Hungary, Debrecen
  • Devices:ZTE Blade [TFT 512RAM]
  • Twitter:@fonix232

Ok, this program has much steeper and more specific requirements than cpg's code. But its requirements are hardly out of this world - I would say most people's computers run windows and wouldn't have a problem with this. I find that getting all the .net runtimes becomes inevitable after a while anyway. This program is distributed in compiled form, which makes life much easier for alot of people who don't have a compiler handy, and it has a GUI, which makes it much more convenient to use. If it supports automatic partition layout editing (and potentially automatic manipulation of anything else that can be done by editing a .mbn) then it has a lot of capabilities that cpg's tool doesn't. A simple GUI based tool could replace compiling your own program, running it from the command line, learning about the structure of .mbn files, and hex editing them. Besides all that, cpg's tool is still there for anyone to use, if they prefer it.


I'm working on the partition editor, and a YAFFS2 image manager too (I would need a C# version of it though). And yes you're right, most of the peole use Win7 now (and who doesn't, they don't have a PC powerful enough to extract a firmware fast, and repack it too). And on Win7, .Net4 is already available.
The UI isn't that slow or a hog, as you said, wbaw, it is actually pretty fast, and works better than my first initial WinForms one. Faster, too, and has easier control (like, in WinForms, I can not make that nice message pop up, or disable the whole screen easily while extracting. WPF is also a lot more versatile, I've added the extract selected part without a hassle, while with WinForms I would have had to work for hours to get it properly working. So, it stays as-is.
When the whole code is ready, I will publish the sources, and then you can make any UI for it - but with some limitation. The code will be published in GPL - with some appendix of mine, including the licensing of the apps based on this code: everything related must be GPL licensed too (or atleast open source). So wbaw if you do not like the UI, do better, noone will stop you.

  • 0
If you like my work, invite me for a drink or two!

Also, take a look at my Blade-dedicated site too! fonix232.co.cc

#17
tcpaulh

tcpaulh

    Addict

  • Members
  • PipPipPipPipPip
  • 999 posts
  • Gender:Male
  • Devices:Coolpad F1, Moto G, G300
  • Twitter:@tcpaulh
Hmm, now I like wbaw and I like fonix232 as well, but which one is better? There's only one way to find out...

  • 0

How To Provide Error Logs

 

There's a problem on KitKat with text wrap / reflow not working. Issue raised here. Please Star and Reply if you think it's a stupid regression


#18
hecatae

hecatae

    Hardcore

  • Moderator Team
  • PipPipPipPipPipPip
  • 3,234 posts
  • Gender:Male
  • Location:northampton
  • Devices:Samsung i9305
  • Twitter:@meritez
anyone made an image.bin yet?

  • 0

#19
fonix232

fonix232

    Addict

  • Members
  • PipPipPipPipPip
  • 942 posts
  • Location:Hungary, Debrecen
  • Devices:ZTE Blade [TFT 512RAM]
  • Twitter:@fonix232

anyone made an image.bin yet?


Yep, me, flashed it, without problem.

  • 0
If you like my work, invite me for a drink or two!

Also, take a look at my Blade-dedicated site too! fonix232.co.cc

#20
Jekle

Jekle

    Addict

  • Members
  • PipPipPipPipPip
  • 555 posts
  • Gender:Male
  • Devices:OSF, Galaxy Ace, Ascend G300
Is a new version coming?

  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users