Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,769,820 Members 48,264 Now Online
XDA Developers Android and Mobile Development Forum

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

Tip us?
 
jes0411
Old
(Last edited by jes0411; 2nd December 2012 at 05:17 AM.) Reason: Updated tutorial with latest version of rom converter (2.1)
#1  
Senior Member - OP
Thanks Meter 193
Posts: 357
Join Date: Nov 2011
Default [TOOL] LG-P970 ROM COVERTER Automatic converter from KDZ to BIN/FLS + ROOT

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
The Following 80 Users Say Thank You to jes0411 For This Useful Post: [ Click to Expand ]
 
cakebomb
Old
#2  
cakebomb's Avatar
Senior Member
Thanks Meter 473
Posts: 259
Join Date: Nov 2011
Location: Viersen

 
DONATE TO ME
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: [ Click to Expand ]
 
jes0411
Old
(Last edited by jes0411; 4th June 2012 at 10:24 PM.)
#3  
Senior Member - OP
Thanks Meter 193
Posts: 357
Join Date: Nov 2011
Quote:
Originally Posted by cakebomb View Post
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.
The Following User Says Thank You to jes0411 For This Useful Post: [ Click to Expand ]
 
omr911
Old
#4  
omr911's Avatar
Senior Member
Thanks Meter 1505
Posts: 333
Join Date: Sep 2011
Thanks
Omer
The Following User Says Thank You to omr911 For This Useful Post: [ Click to Expand ]
 
ErnuB
Old
#5  
ErnuB's Avatar
Senior Member
Thanks Meter 102
Posts: 429
Join Date: Apr 2011
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: [ Click to Expand ]
 
t0g3
Old
(Last edited by t0g3; 5th June 2012 at 06:01 AM.)
#6  
t0g3's Avatar
Senior Member
Thanks Meter 308
Posts: 678
Join Date: Aug 2011
Quote:
Originally Posted by jes0411 View Post
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"
 
jes0411
Old
(Last edited by jes0411; 5th June 2012 at 12:01 PM.)
#7  
Senior Member - OP
Thanks Meter 193
Posts: 357
Join Date: Nov 2011
Quote:
Originally Posted by ErnuB View Post
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 View Post
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.
 
jes0411
Old
#8  
Senior Member - OP
Thanks Meter 193
Posts: 357
Join Date: Nov 2011
Updated to v1.2.

Quote:
Originally Posted by t0g3 View Post
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: [ Click to Expand ]
 
navossoc
Old
#9  
Senior Member
Thanks Meter 217
Posts: 179
Join Date: Jul 2011
Location: São Paulo
Quote:
Originally Posted by jes0411 View Post
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: [ Click to Expand ]
 
Ilko
Old
#10  
Ilko's Avatar
Senior Member
Thanks Meter 459
Posts: 878
Join Date: May 2007
Location: Funky town
  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: [ Click to Expand ]
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes