Manual about editing firmware for LiveSuit format * .img The manual will be better for errors and visual design.Who are too lazy to read the video there:
http://youtu.be/8L-NklTuhf8Program which we will need:
imgRePacker ext4 Utils -
ext4_utils_savagemessiahzine.com(Linux only) .zip (56.71 KB)
So do we need such a system Linux OS. I used
Ubuntu It can be set via the virtual machine
Virtualbox or similar.
Note: If you use a virtual machine, check whether your processor supports virtualization technology. (ForAMD virtualization (AMD-V) for the Intel VT (Intel Virtualization Technology) can be found with the help of the program CPU-Z CPUID ) 1. unpack the * .img Downloading
imgRePacker , Unpack; a folder with the program is also desirable to throw the firmware that will work.
Run
runner.bat and we see this window:
Drag the firmware file
nazvanie_proshivki.img in the window. Note that the command line can not perceive the Cyrillic alphabet and spaces, so if you have a path to the file has data symbols, the path must be enclosed in quotation marks (
" C: \ New Folder \ name proshivki.img
" ), Press Enter, enter an option, if you want (you can read in the post in the program) with a full list of options. If the option is not needed yet we press Enter again. We wait and get unpacked firmware. All firmware files will be in the folder
nazvanie_proshivki.dump next to the original * .img
When disassembling the firmware of different tablets, the composition of the output folder with the unpacked firmware will be different from the example of me. I judged the firmware for TeXet TM-7025, if you disassemble the firmware from another device, then look for a file
* system.fex it should be the largest in size. To edit the markup:
* Sys * _config.fex The list of files in a folder
At this stage, you can specify the layout of sections through a file
sys_config.fex How to change the layout
the red line in the original is missing, here they are for explanation.
Finds the following lines:
[Part_num]
num = 8
;------------------------------>nanda, known as bootfs before, includes boot.axf u-boot.bin etc ... -What section
[Partition0]
class_name = DISK
name = bootloader -section title
size_hi = 0
size_lo = 16384 -Section size
user_type = 0
ro = 0
;------------------------------>nandb, enviroment for u-boot
[Partition1]
class_name = DISK
name = env
size_hi = 0
size_lo = 2048
user_type = 0
ro = 0
;------------------------------>nandc, kernel and ramdisk
[Partition2]
class_name = DISK
name = boot
size_hi = 0
size_lo = 32768
user_type = 0
ro = 0
;------------------------------>nandd, android real rootfs- Section for the system
[Partition3]
class_name = DISK
name = system
size_hi = 0
size_lo = 307200
user_type = 2
ro = 0
;------------------------------>nande, user data- Data Section, where applications are installed
[Partition4]
class_name = DISK
name = data
size_hi = 0
size_lo = 1065366- The size of this section 1GB
user_type = 2
ro = 0
;------------------------------>nandf, misc
[Partition5]
class_name = DISK
name = misc
size_hi = 0
size_lo = 1024
user_type = 2
ro = 0
;------------------------------>nandg, for recovery
[Partition6]
class_name = DISK
name = recovery
size_hi = 0
size_lo = 32768
user_type = 2
ro = 0
;------------------------------>nandh, android app cache
[Partition7]
class_name = DISK
name = cache
size_hi = 0
size_lo = 200088
user_type = 2
ro = 0
If you change the partition size, be careful not to make the size of through
sys_config.fex less than iso files in _iso folder, you can simply not start flashing.
Translation example
The coefficient for the correct translation of partition size
0,98424038461538461538461538461538
How to translate? Need size to 1GB = 1,024 MB = 1,048,576 * 1024 KB / 0,98424038461538461538461538461538 = 1,065,365.754535418763005441525581 and rounded up to the nearest whole number = 1065366
For a more accurate calculation of translating everything into bytes, and perform actions with them.
307200 kb - system partition size to 295 mb
1065366 kb - data partition size to 1024 MB
200088 kb- cashe size partition 192 mb
2. Go to the unpack System To continue the work we need to Linux, I use Ubuntu.
First you need to stand the required packages for building software, the kernel from source code, Android.
So, put all in one command:
sudo apt-get install git-core gnupg flex bison gperf build-essential zip curl multilib mingw32 tofrodos python-markdown libxml2-utils xsltproc
If suddenly something is not installed, then carefully read what we write terminal, usually offer to replace outdated packages at the same time will show which packages need to be replaced with new ones. All names will be the same in the terminal.
After installing the package we need utility
ext4 Utils .
It is also desirable to set up shared folders, if you are working through a virtual machine.
Setting up shared folders on the example of VirtualBox
We choose the right machine, we press
Customize - Shared folders - We press on the file with a plus sign - Specify the path to the folder with the unpacked firmware and utilities - In the field "Folder Name" specify the name of the folder for the guest. Name is better than dial Latin, and her short, as Ubuntu will have everything to gain hands. (Example: System) Just tick the Auto-hook up.
More complete instructions can be found here
Shared folders for VirtualboxNow we need to connect Ubuntu shared folder. Open Terminal (we press on the top left button in the search bar write "Teriminal") and write the following command:
sudo mount -t vboxsf System / media / sf_System - after
vboxsf specify the name of the folder in which we asked the virtual machine configuration (System), followed by the path of the folder where it will be installed.
And so in the Home folder, create a folder:
Unpack Rewrite it in utility
ext4 Utils Compile utility for converting
ext4_utils NIX-in system with a console command
make . To do this, open a terminal and set the path to the folder
roman @ roman-VirtualBox: ~ $ / home / roman / Unpack / ext4_utils and through the gap write
make . We are waiting for a few seconds after we get compiling a set of tools, including
simg2img and
mkuserimg.sh .
Further in Ubuntu go to the folder with the unpacked firmware, and find there a file
system.fex rewrite it in the folder with the utility
ext4 Utils And rename the file to
system.img Now open a terminal and foot:
./simg2img system.img output.img - for the proper performance of the team you should be in the folder with the utility
ext4 Utils (example:
roman @ roman-VirtualBox: ~ / Unpack / ext4_utils $ ./simg2img system.img output.img )
On the way out we got
output.img with which we will work. This file is an ordinary way and drive on this it should be easy to connect to the system to do this, perform the following oparatsii in a terminal:
sudo mkdir / media / system - this team, we create a system folder
sudo mount -o loop output.img / media / system - this command we mount our disk image (output.img) in the system folder.
Then go to the folder
/ Media / system and we see our entire file system Android. So as online disk image has an attribute "Read Only", and any changes we can not make, then open a terminal and type the following:
sudo nautilus - We will launch the built-in file manager as administrator, then in the open window to the left, displaying the device select our a connected image, right-click Properties, the tab right owner: your_username access set: create and delete files on the "Edit rights attachments ", and there, too, are putting" Reading and Writing "and" Creating and deleting files "select all the folders and files and copy them to the home folder. Check that all files were in place for this purpose compare the number of files and the size of the image and your new folder. They should match.
3. Assembly. Once you have made any changes to the system of the future, it is necessary to assemble the whole thing back. And so we go.
Copy finished folder in Ubuntu If you have worked in Windows, if you have worked in Ubuntu then copy or move it to your home folder. (In principle, these actions are not important, as long as you know where you have a folder with the retrofit system,)
The write terminal (we should be in the folder with the utility
ext4 Utils ):
./mkuserimg.sh -s / Vasha_modifitsirovannaya papka_s_faylami ./Vash_novyy_system.img ext4 ./temp 400M 400M - Indicates the size of the disk image of the new system.
Always properly specify this option, because if you create a disk image, such as 1GB, and the actual size of your modified folder is 300MB, 700MB is simply not as not to be involved in the device. you need also will change partition size in file
sys_config.fex Otherwise you can get the firmware does not work.
Therefore, first determine the size of the modified list, and rounded to the nearest hundred. (Example folder takes 240Mb ->300MB; 375Mb ->500 MB)
In principle, if you do not want to bother with the size, you can simply specify the partition size
system from file
sys_config.fex Resulting file
Vash_novyy_system.img rename to
Vash_novyy_system.fex.iso and copy it to a folder with the replacement of
_iso in the folder with the unpacked firmware.
Run
imgRePacker drag the folder "Nazvanie_vashey_proshivki.img.dump" in the program window. (Watch out for syntax) Press Enter and get the new firmware.
You can be tested!
You can also read:
ONDA Vi10 Elite - FirmwarePost has been editedAuta - 16.05.15, 08:00Reason for editing: additional