Rockchip Linux SDK summary

27 篇文章 1 订阅
13 篇文章 0 订阅

http://opensource.rock-chips.com/wiki_Main_Page


http://opensource.rock-chips.com/wiki_Download
Download
We provide prebuilt for all the board we support.

RK3399: https://eyun.baidu.com/s/3qZM8TBm

RK3288: https://eyun.baidu.com/s/3qZt2CIK

RK3328:


http://opensource.rock-chips.com/wiki_Source
Download Update 
refer to https://github.com/rockchip-linux/manifests
Please use old repo which support --no-clone-bundle
Example 

The RK3288 chips

There are two ways to get the code:

(1) Sync to the lastest TOT code:

$ repo init --repo-url=https://github.com/rockchip-linux/repo --no-clone-bundle -u https://github.com/rockchip-linux/manifests -b master -m rk3288_linux.xml

$ repo sync --no-clone-bundle

(2) Sync to the lastest release code:

$ repo init --repo-url=https://github.com/rockchip-linux/repo --no-clone-bundle -u https://github.com/rockchip-linux/manifests -b master -m rk3288_linux_release.xml

$ repo sync --no-clone-bundle


### SDK/RK Linux build 
refer to build/mk-kernel.sh  (https://github.com/rockchip-linux/build)


http://opensource.rock-chips.com/wiki_Linux_user_guide
Linux user guide
 

Contents
1    Overall
2    Environment
3    Getting the Sources
4    Build Image
5    Pack Image
6    Flash image
7    Download Image
Overall
This guide provides information which will help you geting start with Rockchip Linux SDK. Please contact service@rock-chips.com if you need business support.

We are providing 2 kind of rootfs. Buildroot and prebuilt Debian. You can choose the way you prefer. 

Buildroot: An easy and small embedded Linux system. Recommend for your product development. 
Prebuilt Debian: A generic desktop Distro. Only for your evaluation. 
You will need below firmware/image for a full Linux OS and flash them to different locations:

Rockchip miniloader: This is the first level boot loader
U-Boot: This is the second level boot loader
Trusted: ARM Trusted Firmware
Boot: It is Android boot image format. Pack kernel dtb and image to one partition. Use it for production. 
Rootfs: Buildroot or Debian system image
Recovery: It is Android boot image format. Pack kernel dtb, image and ramdisk to one partition. Use it for OTA update. 
Misc: used for transfer command between rootfs and recovery
 


Environment
Please use Ubuntu 16.04 or later version. The early version can't work.

Here are some necessary packages for building the project.

$ sudo apt-get install repo git u-boot-tools device-tree-compiler mtools parted libudev-dev libusb-1.0-0-dev lib32gcc-7-dev python-linaro-image-tools linaro-image-tools gcc-arm-linux-gnueabihf gcc-aarch64-linux-gnu libstdc++-7-dev autoconf autotools-dev libsigsegv2 m4 intltool libdrm-dev curl sed make binutils build-essential gcc g++ bash patch gzip bzip2 perl tar cpio python unzip rsync file bc wget libncurses5 libqt4-dev libglib2.0-dev libgtk2.0-dev libglade2-dev cvs mercurial rsync openssh-client subversion asciidoc w3m dblatex graphviz python-matplotlib libssl-dev pv e2fsprogs fakeroot devscripts libi2c-dev libncurses5-dev texinfo liblz4-tool genext2fs
 

Getting the Sources
Rockchip provide open source software on Github . Please check here to get the source code of Rockchip Linux SDK. 

Build Image
Build all image
enter the root directory of Rockchip Linux SDK. use below command to build all image. 
./build.sh all
Build U-Boot
Please refer to U-Boot for how to build U-Boot
Building kernel
Please refer to kernel for how to build Kernel
Building rootfs
Buildroot: Please refer to Buildroot for how to build Buildroot,  We recommand customers use Buildroot for product development. 
Debian: Please refer to Debian user guide for how to build Debian. Please note that Debian is a desktop OS, We recommand customers only use Debian for evaluation. Please use Buildroot for product development. 
Building recovery
please refer to recovery page for how to build recovery image
Pack Image
Go back to root directory of Linux

Please use below command to pack image for Debian

./mkfirmware.sh debian
Please use below command to pack image for Buildroot

./mkfirmware.sh buildroot
It will generate all the image you need in the rockimg directory.

rockdev/
├── boot.img
├── MiniLoaderAll.bin
├── misc.img
├── oem.img
├── parameter.txt
├── recovery.img
├── rootfs.img
├── trust.img
├── uboot.img
└── userdata.img 
Flash image
Windows: Please refer to AndroidTool for how to flash image to device

Linux: Please refer to upgrade tool for how to flash image to device


Download Image
We provide prebuilt for all the board we support. Please go to download page to download image you need

 


http://opensource.rock-chips.com/wiki_Upgradetool

Upgradetool
upgrade_tool is a firmware upgrade tool for Linux. You can find it in [Linux SDK root]/ tools/linux/Linux_Upgrade_Tool.  Or you can donwload it from here. 

To use upgrade_tool, make sure you can execute it first.  

chmod 777 ./tools/linux/Linux_Upgrade_Tool/upgrade_tool
To use upgradetool  flash image. Please make sure your device is in maskrom rockusb mode.  Go to the rockimg directory

cd rockimg
Use below command to flash image. Let's use RK3399 as an example. You only need change rk3399_loader_v1.09.112.bin to the one you are using. 

sudo ../tools/linux/Linux_Upgrade_Tool/upgrade_tool ul rk3399_loader_v1.09.112.bin
sudo ../tools/linux/Linux_Upgrade_Tool/upgrade_tool di -p parameter.txt
sudo ../tools/linux/Linux_Upgrade_Tool/upgrade_tool di -u uboot.img
sudo ../tools/linux/Linux_Upgrade_Tool/upgrade_tool di -t trust.img
sudo ../tools/linux/Linux_Upgrade_Tool/upgrade_tool di -re resource.img
sudo ../tools/linux/Linux_Upgrade_Tool/upgrade_tool di -k kernel.img
sudo ../tools/linux/Linux_Upgrade_Tool/upgrade_tool di -rootfs rootfs.img
sudo ../tools/linux/Linux_Upgrade_Tool/upgrade_tool rd
 

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值