Rockchip Customization Tool

  1. Rockchip Flash Tool
  2. Rockchip Customization Tool
  3. Rockchip Factory Tool
  4. Rockchip Firmware Tool

Rockchip Firmware Format¶

The rockchip firmware release_update.img, contains the boot loader loader.img and the real firmware data update.img:

release_update.img

The CM3288 SoM is built around a quad-core ARM-based Rockchip RK3288 processor. To provide the flexibility needed for different builds and projects, CM3288 SoM features 2GB of LPDDR3 dual-channel memory. Powered by an ARM-based Mali™-T764 GPU, this RK3288 SoM allow for a wide range of uses, including Advertising machine, Vending machine. And mass production phase. The tool version will be updated continuously with the SDK update. If you have any questions or needs on the tool, please contact us. Rockchip Linux SDK comes with linux (tools used in the Linux operating system environment) and windows (tools used in the Windows operating system environment) in the tools directory. Apr 23, 2019 I would like to test your Rockchip FWFactoryTool (REVAMPED with 8.x support) as i have a Kingbox K2 rk3229 tv box with 8.10 atv & want to customize the firmware but the old Rockchip FWFactoryTool does not like android 8.1 & cannot read system partition. I have also used RK3xxxfirmwaretools5.99.07.00 it extracts ok but when i try & build.

update.img is packed with multiple image files, described by a control file named package-file. A typical package-file is:

Soundwin Network Inc. Is a solution provider of Rockchip CPU in Taiwan. Soundwin provides both software and hardware customization based on Rockchip CPU, such as Rockchip RK3399 chipset 、 Rockchip RK3288 chipset 、 Rockchip PX30 chipset 、 Rockchip RK3328 chipset 、 Rockchip RK3368 chipset 、 Rockchip RK3399 PRO chipset. Device Brand: rockchip Device Manufact.: rockchip Device Model: rk292xesp8089 Device CPU: RK2928 Device IntName: rk292xesp8089 Device Version: 4.4.2 CUSWVer: rockchip Device Compile: 11/1/2014 2:42:01 AM Device ExtInfo: Q8S.

  • package-file: packing description of update.img, which is also included by update.img.
  • Image/MiniLoaderAll.bin: The first bootloader loaded by cpu rom code.
  • Image/parameter.txt: Parameter file where you can set the kernel boot parameters and partition layout.
  • Image/trust.img: The Arm Trusted Image.
  • Image/misc.img: misc partition image, used to control boot mode of Android.
  • Image/kernel.img: Android kernel image.
  • Image/resource.img: Resource image with boot logo and kernel device tree blob.
  • Image/boot.img: Android initramfs, a root filesystem loaded in normal boot, contains important initialization and services description.
  • Image/recovery.img: Recovery mode image.
  • Image/system.img: Android system partition image.

Unpacking is extracting update.img from release_update.img, and then unpacking all the image files inside.

While repacking, it is the inverse process. It synthesizes the image files described by the package-file, into update.img, which will be further packed together with the bootloader to create the final release_update.img.

Installation of Tools¶

Rockchip Flash Tool

Unpacking Rockchip Firmware¶

  • Unpacking release_update.img:

  • Unpacking update.img:

  • Check the file tree in the update directory:

Packing Rockchip Firmware¶

First of all, make sure system partition in parameter.txt file is larger enough to hold system.img. You can reference Parameter file format to understand the partition layout.

For example, in the line prefixed with “CMDLINE” in parameter.txt, you will find the description of system partition similiar to the following content:

The heximal string before the “@” is the partiton size in sectors (1 sector = 512 bytes here), therefore the size of the system partition is:

To create release_update_new.img:

Customization¶

Customizing system.img¶

system.img is an ext4 file system format image file which can be mounted directly to the system for modification:

Note that the free space of system.img is almost 0. If you need to expand the image file, do adjust the partition layout in parameter.txt accordingly.

The following is an example of how to increase the size of the image file by 128MB.

Before expanding, make sure system.img is not mounted by running:

Resize the image file:


  • 5Step By Step
    • 5.1Building the sources
      • 5.1.3Building rootfs
  • 6See also

This guide provides information which will help you get started with rockchip opensource linux. If you have any questions, please report to us on github project issue page.

We are providing 3 ways to build rootfs including prebuilt Debian, Yocto, Buildroot. You can choose the way you prefer.(Please check the Software Status because different chips have a different support)

You will need below firmware/image for a full Linux OS and flash them to different locations:

  • U-Boot SPL/Rockchip miniloader
    *U-Boot
    *boot(including kernel, dtb and config file)
    *rootfs(Debian, Ubuntu, etc.)

Before starting to develop, please refer to board configandhow-to to choose a most matching config as the foundation.

Note that our development environment is Ubuntu, you can use 16.04 or later version(with downgraded arm gcc).

Debian-9 and Docker-Rockchip are also available.

Ubuntu 14.04 is deprecated, we don't guarantee that Linux SDK can work on it.

Here are some necessary packages for building the project.

If you insist on developing on your own environment, please make sure the version of gcc-arm-linux-gnueabihf and gcc-aarch64-linux-gnu is less than 6.

The rockchip linux SDK source tree is located in multi Git repository hosted by Github. The SDK uses repo to sync down source code.


Create an empty directory to hold your working files.

To initialize Linux SDK source tree, you need to get repo first

Basic Linux SDK(standalone kernel/u-boot/rootfs)

Yocto

Buildroot

Below guides are based on basic Linux SDK, guides for yocto/buildroot could be found in the separate page.

ref : partition, rockusb, boot

We have provide build scripts which essentially wraps the commands, so you can quickly start your development by them.

Please note that those scripts are assumed your directory structure is same with the one created by manifest. We use rk3288-firefly as example. You can change rk3288-firefly to any other board supported(ie. rk3399-firefly)

compile kernel

compile uboot

Pack all parts to a complete image

`s` is size in Mbyte, `r` is your rootfs image (prebuilt debian image) location. Here we use rk3288 as example. You can change it to any other supported chips(ie. rk3399, rk3328).

flash image

eMMC (Ensure the board is in maskrom mode. maskrom, Not rockusb! ):

SD Card:
`d` is your target device

bringup(burn kernel, uboot, gpt)

update kernel

update uboot (armv7)

update uboot(armv8 with miniloader)

Before asking questions, please, read references and follow the setp by setp guide to boot your device.

It's better if you can study those build scripts.

Please refer to AndroidFlashTool(TODO: wiki) for flashing image on Windows. (For the first time, it's recommended to use a linux host, to save the time.)

Building the sources

Rockchip Customization Tool

Building uboot

Installing the build tools and download source

Compile the Uboot

You can get spl/u-boot-spl.bin(if there is) and u-boot.bin when build complete, we will use these files to generate idb.img or uboot.img

See U-Boot page for more detail. Foundation game.

There are two feasible ways to boot to U-Boot.
1. RK SPL bin(DDR.bin, miniloader)
2. U-Boot SPL

See boot option page for more detail.

Building kernel

Compile the kernel:

For ARM v7

For ARM V8

You can get zImage/Image and dtbs when build complete, we will use these files to generate boot.img for boot partition.

Rockchip Factory Tool

Tool

See Rockchip kernel for more detail.

Building rootfs

It's recommend to download prebuilt debian image for bringup.

Debian

See debian-guide for detail.

You should get xxx-rootfs.img.

Yocto

See yocto-user-guide for detail.

You should get xxx.ext4 rootfs image.

Buildroot

See buildroot-user-guide for detail.

You should get rootfs.img in this step for the Linux OS.

Booting the Board

Then you can chose a suitable way for you to boot the board with flash all the image to media device.

  • Booting from emmc
    *Booting from sdcard
    *Booting from udisk

Drivers

Display:

  • eDP
    *MIPI-DSI
    *LVDS
    *HDMI
    *HDCP

Rockchip Firmware Tool

Graphic:

  • RGA
    *GPU
    *VOP

USB:

  • DWC2
    *DWC3

Storage:

  • eMMC
    *SD-Card

Audio:

  • HDMI-Audio
    *I2S
    *SPDIF

Connectivity:

  • Wireless
    *Ethernet

Others:

Tool
  • PWM
    *I2C
    *SPI
    *UART
    *Thermal
    *Clock
    *DVFS
    *Suspend/Resume

Customization


Retrieved from 'http://opensource.rock-chips.com/index.php?title=User:Admin&oldid=1699'