[RK3288][Android6.0] Ubuntu上制作升级包update.img

Platform: ROCKCHIP
OS: Android 6.0
Kernel: 3.10.92

此方法适用于全新eMMC(MaskRom模式)以及已经刷过系统的(RockUsb模式)板子升级.


1.    编译整个系统。
$ ./1_build_debug.sh
脚本参见: http://blog.csdn.net/kris_fei/article/details/52692393

2.    拷贝所有 Images
$ cp rockdev/rk3288-eng/* RKTools/linux/Linux_Pack_Firmware/rockdev/Images

3.    拷贝loader
$cpockdev/rk3288-eng/RK3288UbootLoader_V2.30.10.bin  RKTools/linux/Linux_Pack_Firmware/rockdev/

4.    修改package-file
# NAME        Relative path #HWDEF        HWDEF package-file    package-file bootloader    RK3288UbootLoader_V2.30.10.bin parameter    parameter resource    Image/resource.img kernel        Image/kernel.img boot        Image/boot.img recovery    Image/recovery.img system        Image/system.img backup        RESERVED

5.    修改parameter
FIRMWARE_VER:6.0.0 MACHINE_MODEL:rk3288 MACHINE_ID:007 MANUFACTURER:RK3288 MAGIC: 0x5041524B ATAG: 0x60000800 MACHINE: 3288 CHECK_MASK: 0x80 PWR_HLD: 0,0,A,0,1 CMDLINE:console=ttyFIQ0 androidboot.baseband=N/A androidboot.selinux=permissive androidboot.hardware=rk30board androidboot.console=ttyFIQ0 init=/init initrd=0x62000000,0x00800000 mtdparts=rk29xxnand:0x00002000@0x00002000(uboot),0x00002000@0x00004000(misc),0x00008000@0x00006000(resource),0x00008000@0x0000e000(kernel),0x00010000@0x00016000(boot),0x00010000@0x00026000(recovery),0x0001a000@0x00036000(backup),0x00040000@0x00050000(cache),0x00002000@0x00090000(kpanic),0x00100000@0x00092000(system),0x00008000@0x00192000(metadata),0x00020000@0x0039A000(radical_update),-@0x003BA000(userdata)
6.    修改mkupdate.sh
#!/bin/bash
pause()
{
echo "Press any key to quit:"
read -n1 -s key
exit 1
}
echo "start to make update.img..."
if [ ! -f "parameter" ]; then
    echo "Error:No found parameter!"
    pause
fi
if [ ! -f "package-file" ]; then
    echo "Error:No found package-file!"
    pause
fi
./afptool -pack ./ Image/update.img || pause
./rkImageMaker -RK32 RK3288UbootLoader_V2.30.10.bin Image/update.img update.img -os_type:androidos || pause
echo "Making update.img OK."
echo "Press any key to quit:"
read -n1 -s key
exit 0

7.    生成update.img
[kris@:~/rk3288/RKTools/linux/Linux_Pack_Firmware/rockdev]$ ./mkupdate.sh
start to make update.img...
Android Firmware Package Tool v1.62
------ PACKAGE ------
Add file: ./package-file
Add file: ./RK3288UbootLoader_V2.30.10.bin
Add file: ./parameter
Add file: ./Image/resource.img
Add file: ./Image/kernel.img
Add file: ./Image/boot.img
Add file: ./Image/recovery.img
Add file: ./Image/system.img
Add CRC...
Make firmware OK!
------ OK ------
********RKImageMaker ver 1.63********
Generating new image, please wait...
Writing head info...
Writing boot file...
Writing firmware...
Generating MD5 data...
MD5 data generated successfully!
New image generated successfully!
Making update.img OK.
Press any key to quit:

8.    插上usb cable线,升级
upgrade_tool从 rk3288/RKTools/linux/Linux_Upgrade_Tool/Linux_Upgrade_Tool_v1.23
Copy过来。
[kris@:~/rk3288/RKTools/linux/Linux_Pack_Firmware/rockdev_bk]$ ./upgrade_tool
List of rockusb connected
DevNo=1    Vid=0x2207,Pid=0x320a,LocationID=31a    Maskrom
Found 1 rockusb,Select input DevNo,Rescan press ,Quit press :1

---------------------Tool Usage ---------------------
Help:             H
Quit:             Q
Version:          V
Clear Screen:     CS
------------------Upgrade Command ------------------
ChooseDevice:        CD
SwitchDevice:        SD
UpgradeFirmware:    UF
UpgradeLoader:        UL
DownloadImage:        DI <-p|-b|-k|-s|-r|-m image> [parameter file]
DownloadBoot:        DB
EraseFlash:        EF
LowerFormat:        LF
----------------Professional Command -----------------
TestDevice:        TD
ResetDevice:        RD [subcode]
ResetPipe:        RP [pipe]
ReadFlashID:        RID
ReadFlashInfo:        RFI
ReadChipInfo:        RCI
ReadSector:        RS  [-decode] [File]
WriteSector:        WS 
ReadLBA:        RL  [File]
WriteLBA:        WL 
EraseBlock:        EB [--Force]
-------------------------------------------------------

Rockusb>uf update.img
Loading firmware...
Support Type:RK32    FW Ver:6.0.00    FW Time:2016-10-25 11:36:04
Loader ver:2.30    Loader Time:2016-09-06 14:29:09
Upgrade firmware ok.

这样就可以开机了。

你可能感兴趣的:(子类__Other)