Post Reply

[TOOL] LG-P970 ROM COVERTER Automatic converter from KDZ to BIN/FLS + ROOT

OP jes0411

4th June 2012, 10:02 PM   |  #1  
OP Senior Member
Thanks Meter: 200
 
372 posts
Join Date:Joined: Nov 2011
More
I have developed a tool based in LGExtract 0.2.1 from navossoc.
http://forum.xda-developers.com/show....php?t=1566532

It can convert KDZ roms to BIN/FLS automatically in a double click for flashing with SmartFlashTool.

I added LGExtract.exe, extract.exe (to extract .cab file) and a batch that do all the process, in one executable. CWM injection based on cygwin.

Only works with P970 (Optimus Black) and P920 (Optimus 3D) roms and maybe other models with same files structure (several bin files and one fls file). It doesn't work with P990 (Optimus 2x) roms.

Instructions:

Have to put the exe and kdz rom in same folder and execute the program, it shows a cmd window asking which kdz to convert. Type number and tap enter.




Then it does the extraction of kdz, cab and wdb, merge bin files and clean up. At the end it ask for patch bin file with CWM.



If type "n" (without quotes) and tap enter conversion has end. Have to tap any key to close cmd window.



After that you have a folder named as kdz with bin and fls to flash with smartflashtool.

Instructions to patch bin with CWM:

Conversion of kdz to bin/fls is the same.
At the end of conversion can choose to inject CWM or not. To inject it type "y" (without quotes) and tap enter.



It continues CWM injection.
It shows several options and have to type latest one and tap enter (normally it shows 2 options like in this case and have to type "2").



It ask what kind of CWM to inject; "n" for normal and "t" for touch (without quotes) and tap enter.



It injects cwm and finally it shows file was succesfully converted, the folder that contains bin and fls files (in this case folder and bin file are renamed to [PATCHED]) and what type of cwm was injected. Tap any key to close cmd window.



It's ready to flash with smartflashtool. Before flash it, download superuser.zip and copy to sd card. when flash ends, phone is rebooted in recovery, it's recommended to do wipe data, chiefly if install different rom version or if you flash it to solve problems to avoid bootloop or other errors (if flashed same version to root do wipe cache and dalvik, it isn't necessary to do wipe data). Next install zip from sdcard and install superuser.zip. Then reboot system now and phone is ready with the rooted rom. Can install busybox and an app to reboot in recovery like rom manager.

Tested with V20Q and V20S with cwm in my OB from Zeus, CM10 and ICS without problem.

Version 1.1:
Fix incompatibility issue in Windows XP
It has a false positive in Anivir (Avira antivirus).
Virustotal analysis:
https://www.virustotal.com/file/f6b7...c762/analysis/

Version 1.2:
The folder and bin/fls files are renamed to kdz filename.
Now compatible with Optimus 3D P920 kdz roms and maybe with other models with the same type of bin files extracted from wbd. It doesn't compatible with Optimus Dual P990 because the extraction of wdb generates diferent files.

Version 1.3:
Works with several kdz files in the folder and can choose one of them to convert.
New compiler, fix detection of some antivirus.
New icon, thanks to Ilko.

Version 2.0
Added posibility to patch bin with CWM recovery to root the rom, only for P970, I haven't add CWM for other devices.
Can choose the type of CWM to inject (touch or normal).

Version 2.1
Replaced old method to inject CWM (based on cygwin) with recovery.exe from navossoc.
Improved script thanks to navossoc.
I'll edit the tutorial when I have more time.

Credits:

All credits to navossoc and XDA team who develop LGExtract and recovery.exe and thanks for modify the script to use recovery.exe.
To Pacos1 who realizes it doesn't work in Windows XP and false positive in Antivir.
To t0g3 for improve the script adding the posibility to choose kdz file.
To Ilko for the new compiler, his help and the new icon.

Download:

Mediafire
Box
Last edited by jes0411; 2nd December 2012 at 05:17 AM. Reason: Updated tutorial with latest version of rom converter (2.1)
The Following 83 Users Say Thank You to jes0411 For This Useful Post: [ View ]
4th June 2012, 10:06 PM   |  #2  
cakebomb's Avatar
Senior Member
Flag Viersen
Thanks Meter: 474
 
259 posts
Join Date:Joined: Nov 2011
Donate to Me
More
Thanks, cause I hate lg kdz updater, smartflashtool is much better and easier.
I can make a graphic interface for this, if you want. But I don't know if it's very useful.
cakebomb.
The Following User Says Thank You to cakebomb For This Useful Post: [ View ]
4th June 2012, 10:16 PM   |  #3  
OP Senior Member
Thanks Meter: 200
 
372 posts
Join Date:Joined: Nov 2011
More
Quote:
Originally Posted by cakebomb

Thanks, cause I hate lg kdz updater, smartflashtool is much better and easier.
I can make a graphic interface for this, if you want. But I don't know if it's very useful.
cakebomb.

A graphical interface can be useful to select kdz file, the program do this automatically if there is a kdz in the same folder but it doesn't work if there are more than one and has to choose the correct bin files to merge. But I don't know how to do this, I am a noob in batch and have no idea of programming.
I think it can be possible if we can choose the output folder for LGExtract and include a variable for it in the script.
Last edited by jes0411; 4th June 2012 at 10:24 PM.
The Following User Says Thank You to jes0411 For This Useful Post: [ View ]
4th June 2012, 10:50 PM   |  #4  
omr911's Avatar
Senior Member
Thanks Meter: 1,505
 
333 posts
Join Date:Joined: Sep 2011
Thanks
The Following User Says Thank You to omr911 For This Useful Post: [ View ]
4th June 2012, 11:28 PM   |  #5  
ErnuB's Avatar
Senior Member
Thanks Meter: 102
 
431 posts
Join Date:Joined: Apr 2011
More
Is it possible to root and modify a rom in KDZ or BIN/FLS? It would be awesome to develop new roms based on stock.
I heard spain rom V20Q has some old bugs fixed but we still have no deox version of this or any rom based on it
The Following User Says Thank You to ErnuB For This Useful Post: [ View ]
5th June 2012, 05:57 AM   |  #6  
t0g3's Avatar
Senior Member
Thanks Meter: 308
 
678 posts
Join Date:Joined: Aug 2011
More
Quote:
Originally Posted by jes0411

A graphical interface can be useful to select kdz file, the program do this automatically if there is a kdz in the same folder but it doesn't work if there are more than one and has to choose the correct bin files to merge. But I don't know how to do this, I am a noob in batch and have no idea of programming.
I think it can be possible if we can choose the output folder for LGExtract and include a variable for it in the script.

IMO, I think it would be great if folder name that created is same as kdz file name, instead just "BIN"
Last edited by t0g3; 5th June 2012 at 06:01 AM.
5th June 2012, 11:57 AM   |  #7  
OP Senior Member
Thanks Meter: 200
 
372 posts
Join Date:Joined: Nov 2011
More
Quote:
Originally Posted by ErnuB

Is it possible to root and modify a rom in KDZ or BIN/FLS? It would be awesome to develop new roms based on stock.
I heard spain rom V20Q has some old bugs fixed but we still have no deox version of this or any rom based on it

The better way to root a v20 kdz is injecting cwm when flashing.
http://forum.xda-developers.com/show....php?t=1512203

Quote:
Originally Posted by t0g3

IMO, I think it would be great if folder name that created is same as kdz file name, instead just "BIN"

Yes, but it's LGExtract what create BIN folder, navossoc would have to modify his program to do that.
Last edited by jes0411; 5th June 2012 at 12:01 PM.
5th June 2012, 08:22 PM   |  #8  
OP Senior Member
Thanks Meter: 200
 
372 posts
Join Date:Joined: Nov 2011
More
Updated to v1.2.

Quote:
Originally Posted by t0g3

IMO, I think it would be great if folder name that created is same as kdz file name, instead just "BIN"

I didn't realize to add a ren command to do that. Now in v1.2 the folder name is the same as kdz filename.
The Following User Says Thank You to jes0411 For This Useful Post: [ View ]
8th June 2012, 08:42 PM   |  #9  
Senior Member
Flag São Paulo
Thanks Meter: 219
 
179 posts
Join Date:Joined: Jul 2011
Quote:
Originally Posted by jes0411

The better way to root a v20 kdz is injecting cwm when flashing.
http://forum.xda-developers.com/show....php?t=1512203



Yes, but it's LGExtract what create BIN folder, navossoc would have to modify his program to do that.

Who choose that name for the folder was LG.
I just use the same path and filename that are inside of the wdb container.

I made a tool for patch the bin file and overwrite the recovery with CWM, but I never released it.

I didn't merge files because I never find a pattern for it. Some models are totally different from others.
So, I just made the tool, you extract and do choose what to do with the files.

[]'s
The Following 2 Users Say Thank You to navossoc For This Useful Post: [ View ]
8th June 2012, 11:15 PM   |  #10  
Ilko's Avatar
Senior Member
Funky town
Thanks Meter: 466
 
880 posts
Join Date:Joined: May 2007
More
  1. create new texte file in the same folder of 7za, lgextract and your FW, then paste the following
  2. search/replace all occurrences of "V20O" by your FW version (case sensitive)
  3. save it as name.cmd or name.bat then open the file you've just created. you can reedit it later by opening it with a any text editor (or right clic > edit)

you'll obtain a folder named of the FW you've indicated with the required binaries to use with smartflash. Easy as can be

Code:
@echo off
title LGX

echo.
echo.
echo      -[ Extraction process started ]-
echo.
echo.
echo Extracting cab file
echo -------------------
echo.
lgextract.exe -kdz V20O_00.kdz
echo.
echo.
echo Extracting WDB/dll files
echo ------------------------
echo.
7za.exe e -y V20O_00.cab 
echo.
echo.
echo Extracting binary files
echo -----------------------
echo.
lgextract.exe -wdb V20O.wdb lgp970.dll
echo.
echo.
echo Merging and cleaning
echo --------------------
echo.
del lgp970.dll, V20O.wdb, V20O_00.cab
ren "BIN" "V20O"
cd V20O
ren "LGP970_CP.fls" "0_LGP970_CP_FLS.fls"
copy /b "LGP970_AP[*].bin" "1_LGP970_AP_BIN.bin"
del "LGP970_AP[*].bin"

echo.
echo.
echo      -[ Firmware is now ready to be flashed via SmartFlash ]-
echo.
echo.
timeout 10
if you're too lazy, browse my shares and download it

The Following User Says Thank You to Ilko For This Useful Post: [ View ]
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Top Threads in Optimus Black Android Development by ThreadRank