文档库 最新最全的文档下载
当前位置:文档库 › RK3128_ANDROID4.4.4-RBOX_SDK_V1.0_20141010发布说明

RK3128_ANDROID4.4.4-RBOX_SDK_V1.0_20141010发布说明

RK3128_ANDROID4.4.4-RBOX_SDK_V1.0_20141010发布说明
RK3128_ANDROID4.4.4-RBOX_SDK_V1.0_20141010发布说明

密级状态:绝密( ) 秘密( ) 内部( ) 公开(√)

RK3128_R-BOX_ANDROID4.4.4-SDK

发布说明

(技术部,BOX组)

文件状态:[ ] 正在修改[√] 正式发布

当前版本:V1.0

作者:黄景华

完成日期:2014-10-10

审核:黄激流

完成日期:

福州瑞芯微电子有限公司 Fuzhou Rockchip Electronics Co., Ltd (版本所有,翻版必究) 

版本历史

版本号作者修改日期修改说明备注V1.0 黄景华2014.10.10 初始发布

目录

1 概述 (2)

2 主要支持功能 (3)

2.1功能项说明与配置 (4)

2.1.1 工具说明 (4)

2.1.2 内核板极配置 (4)

2.1.3 Camera (4)

2.1.4 PMIC (4)

3 SSH公钥操作说明 (5)

3.1SSH公钥生成 (5)

3.2使用KEY-CHAIN管理密钥 (6)

3.3多台机器使用相同SSH公钥 (6)

3.4一台机器切换不同SSH公钥 (7)

3.5密钥权限管理 (8)

4 REPO 同步说明 (9)

4.1G IT权限申请说明 (9)

4.2源码获取说明 (9)

5 编译说明 (10)

5.1编译环境搭建 (10)

5.2编译步骤 (13)

5.2.1 Kernel 编译步骤 (13)

5.2.2 U boot 编译步骤 (13)

5.2.3 Android 编译步骤 (14)

5.3烧写说明 (14)

1 概述

本版本是配合RK3128 R-BOX平台发布的Android4.4.4的SDK代码。适用于RK3128 R-BOX 开发板以及基于其上所有开发产品。

环境编译事宜请参见第5章节编译说明。

下载代码请参考第4章节repo同步操作。

本文档提及的文档和工具,工具位于工程根目录/RKTools文件夹下,文档位于工程根目录/RKDocs文件夹下。工具的使用说明都在工具相应目录里。

2 主要支持功能

此版本主要软硬件功能如下:

硬件

1)Memory size: up to 2GMb DDR3

2)WIFI (802.11 a/b/g/n/ac)

3)Ethernet (RJ45 10/100/1000Mb)

4)USB host (HDD external / HID / udisk / USB audio / USB camera)

5)USB device (MTP / adb)

6)SD card / TF card

7)HDMI:1080P@60Hz/1080P@50Hz/720P@60Hz/720P@50Hz/576P@50Hz/480P@60

Hz

8)CVBS: PAL/NTSC

9)YPbPr: 720P@60Hz/720P@50Hz/576P@50Hz/480P@60Hz

10)SPDIF

11)IR remote

软件( 主要应用程序):

VideoPlayer / MusicPlayer / Gallery / Browser / ApkInstall / Explorer / Maps / Email / Market (Google Play) / Gmail / Books / eHomeCenter_box

优化及特色功能:

1)音频多采样率支持

2)媒体库扫描加速

3)Pppoe (over Ethernet or WiFi)

4)Upnp/DLNA (HomeMediaCenter)

5)Samba (基于Explorer)

2.1 功能项说明与配置

2.1.1 工具说明

与SDK同步发布的产测工具包括:烧写工具、量产工具、固件工厂工具、PCBA测试工具,整机测试APK等。详情请阅读文档,其中工具位于工程根目录/RKTools文件夹下,文档位于工程根目录/RKDocs。下文为简单说明部分注意事项。

●工厂量产工具

请参考工具FactoryTool_v1.33的《工厂工具用户手册.pdf》

●开发烧写工具

请参考AndroidTool_Release_v2.3 里的《Android开发工具手册.pdf》

●驱动安装工具

直接运行Release_DriverAssitant里的DriverInstall.exe,先卸载后安装即可。

2.1.2 内核板极配置

本SDK采用Linux-3.10内核版本,内核移植可参考文档《RK平台linux-3.10相关介绍》。SDK 默认3.10内核使用统一的配置,即rockchip_defconfig。外设驱动配置可以通过dts来配置,详细可参考《RK312X_DTS使用说明文档》中相关介绍。

2.1.3 Camera配置说明

RK3128 Camera代码结构、配置、调试及目前已调试的Sensor支持列表等,可参考文档《RK312X_Camera_User_Manual》说明。

2.1.4 PMIC使用说明

RK3128平台PMIC使用请参考文档《rk312x平台LINUX3.10上pmu使用说明》。

3 SSH公钥操作说明

3.1 SSH公钥生成

使用如下命令生成:

ssh-keygen -t rsa -C "user@host"

请将user@host替换成您的邮箱地址。

命令运行完成会在你的目录下生成key文件。

请妥善保存生成的私钥文件id_rsa和密码,并将id_rsa.pub发邮件给SDK发布服务器的管理员。

3.2 使用key-chain管理密钥

推荐您使用比较简易的工具keychain管理密钥,使用此方法即可不用下面3.3/3.4的方法。

具体使用方法如下:

1. 安装keychain软件包:

$sudo aptitude install keychain

2. 配置使用密钥:

$vim ~/.bashrc

增加下面这行:

eval `keychain --eval ~/.ssh/id_rsa`

其中,id_rsa是私钥文件名称。

以上配置以后,重新登录控制台,会提示输入密码,只需输入生成密钥时使用的密码即可,若无密码可不输入。

另外,请尽量不要使用sudo或root用户,除非您知道如何处理,否则将导致权限以及密钥管理混乱。

3.3 多台机器使用相同SSH公钥

在不同机器使用,可以将你的ssh私钥文件id_rsa拷贝到要使用的机器的“~/.ssh/id_rsa”即可。

在使用错误的私钥会出现如下提示,请注意替换成正确的私钥。

添加正确的私钥后,就可以使用git 克隆代码,如下图。

添加ssh私钥可能出现如下提示错误。

Agent admitted failture to sign using the key

在console输入如下命令即可解决。

ssh-add ~/.ssh/id_rsa

3.4 一台机器切换不同SSH公钥

可以参考ssh_config文档配置ssh。

~$ man ssh_config

通过如下命令,配置当前用户的ssh配置。

~$ cp /etc/ssh/ssh_config ~/.ssh/config

~$ vi .ssh/config

如图,将ssh使用另一个目录的文件“~/.ssh1/id_rsa”作为认证私钥。通过这种方法,可以切换不同的的密钥。

3.5 密钥权限管理

服务器可以实时监控某个key的下载次数、IP等信息,如果发现异常将禁用相应的key的下载权限。

请妥善保管私钥文件。并不要二次授权与第三方使用。

4 Repo 同步说明

4.1 Git权限申请说明

Generate public key as mentioned in above section 3, then mail to fae@https://www.wendangku.net/doc/9418248968.html,

4.2 源码获取说明

run the command below:

$ git clone ssh://git@https://www.wendangku.net/doc/9418248968.html,:10000/repo/tools/repo

$ mkdir 3128_box_sdk

$ cd 3128_box_sdk

$ ../repo/repo init --repo-url ssh://git@https://www.wendangku.net/doc/9418248968.html,:10000/repo/rk/tools/repo -u

ssh://git@https://www.wendangku.net/doc/9418248968.html,:10000/repo/rk/platform/manifest -b android-4.4 -m rk312x-4.4-box.xml In order to save time in downloading codes, we pack cloned git repository when first version released.

Packed Git repository

rk3128_box_kitkat_rel_v1.00_141010.tar

Download compressed package, you can check out the latest codes as follows:

mkdir rk3128

tar xvf rk3128_box_kitkat_rel_v1.00_141010.tar –C rk3128

cd rk3128

.repo/repo/repo sync –l

.repo/repo/repo/ sync

5 编译说明

5.1 编译环境搭建

1.Initializing a Build Environment

This section describes how to set up your local work environment to build the Android source files. You will need to use Linux or Mac OS. Building under Windows is not currently supported.

Note: The source download is approximately 35GB in size. You will need over 45GB free to complete a single build, and up to 100GB (or more) for a full set of builds.

For an overview of the entire code-review and code-update process, see Life of a Patch.

2.Choosing a Branch

Some of the requirements for your build environment are determined by which version of the source code you plan to compile. See Build Numbers for a full listing of branches you may choose from. You may also choose to download and build the latest source code (called "master"), in which case you will simply omit the branch specification when you initialize the repository.

Once you have selected a branch, follow the appropriate instructions below to set up your build environment.

3.Setting up a Linux build environment

These instructions apply to all branches, including master.

The Android build is routinely tested in house on recent versions of Ubuntu LTS (10.04), but most distributions should have the required build tools available. Reports of successes or failures on other distributions are welcome.

For Gingerbread (2.3.x) and newer versions, including the master branch, a 64-bit environment is required. Older versions can be compiled on 32-bit systems.

Note: It is also possible to build Android in a virtual machine. If you are running Linux in a virtual machine, you will need at least 16GB of RAM/swap and 30GB or more of disk space in order to build the Android tree.

Detailed instructions for Ubuntu and MacOS follow. In general you will need:

?Python 2.6 -- 2.7, which you can download from https://www.wendangku.net/doc/9418248968.html,.

?GNU Make 3.81 -- 3.82, which you can download from https://www.wendangku.net/doc/9418248968.html,,

?JDK 6 if you wish to build Gingerbread or newer; JDK 5 for Froyo or older. You can download both from https://www.wendangku.net/doc/9418248968.html,.

?Git 1.7 or newer. You can find it at https://www.wendangku.net/doc/9418248968.html,.

4.Installing the JDK

(It is recommended for you to follow this instructions, otherwise it will cause some compile problems)

a. download the latest JDK 6 from https://www.wendangku.net/doc/9418248968.html,/technetwork/java/javase/downloads/jd k6downloads-1902814.html

b. decompress downloaded bin file

$./jdk-6u -linux-x64.bin

c. move it to a proper directory,for example :/usr/lib/jvm/

d. install alternative options:(update-alternative --install ) sudo update-alternatives --install /usr/bin/jar jar /usr/lib/jvm/jdk1.6.0_/bin/jar 60 sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.6.0_/bin/java 60 sudo update-alternatives --install /usr/bin/javac javac /usr/lib/jvm/jdk1.6.0_/bin/javac

60

sudo update-alternatives --install /usr/bin/javap javap /usr/lib/jvm/jdk1.6.0_/bin/javap

60

sudo update-alternatives --install /usr/bin/javadoc javadoc /usr/lib/jvm/jdk1.6.0_/bin/j avadoc 60

e. select jdk by hand

sudo update-alternatives --config jar

sudo update-alternatives --config java

sudo update-alternatives --config javac

sudo update-alternatives --config javap

sudo update-alternatives --config javadoc

Note: The lunch command in the build step will ensure that the Sun JDK is used instead of any previously installed JDK.

5.Installing required packages (Ubuntu 12.04)

You will need a 64-bit version of Ubuntu. Ubuntu 12.04 is recommended. Building using an older version of Ubuntu is not supported on master or recent releases.

$ sudo apt-get install git gnupg flex bison gperf build-essential \

zip curl libc6-dev libncurses5-dev:i386 x11proto-core-dev \

libx11-dev:i386 libreadline6-dev:i386 libgl1-mesa-glx:i386 \

libgl1-mesa-dev g++-multilib mingw32 tofrodos \

python-markdown libxml2-utils xsltproc zlib1g-dev:i386

$ sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so

6.Installing required packages (Ubuntu 10.04 -- 11.10)

Building on Ubuntu 10.04-11.10 is no longer supported, but may be useful for building older releases of AOSP.

$ sudo apt-get install git-core gnupg flex bison gperf build-essential \

zip curl zlib1g-dev libc6-dev lib32ncurses5-dev ia32-libs \

x11proto-core-dev libx11-dev lib32readline5-dev lib32z-dev \

libgl1-mesa-dev g++-multilib mingw32 tofrodos python-markdown \

libxml2-utils xsltproc

On Ubuntu 10.10:

$ sudo ln -s /usr/lib32/mesa/libGL.so.1 /usr/lib32/mesa/libGL.so

On Ubuntu 11.10:

$ sudo apt-get install libx11-dev:i386

7.Configuring USB Access

Under GNU/linux systems (and specifically under Ubuntu systems), regular users can't directly access USB devices by default. The system needs to be configured to allow such access.

The recommended approach is to create a file /etc/udev/rules.d/51-android.rules (as the root user) and to copy the following lines in it. must be replaced by the actual username of the user who is authorized to access the phones over USB.

# adb protocol on passion (Rockchip products)

SUBSYSTEM=="usb", ATTR{idVendor}=="2207", ATTR{idProduct}=="0010", MODE="0600", OWNER=""

Those new rules take effect the next time a device is plugged in. It might therefore be necessary to unplug the device and plug it back into the computer.

This is known to work on both Ubuntu Hardy Heron (8.04.x LTS) and Lucid Lynx (10.04.x LTS). Other versions of Ubuntu or other variants of GNU/linux might require different configurations.

References : https://www.wendangku.net/doc/9418248968.html,/source/initializing.html

5.2 编译步骤

5.2.1 kernel 编译步骤

A. SDK默认支持两种版型,即,SDK板和RK88样机,内核使用统一的配置rockchip_defconfig

$ make rockchip_defconfig

$ make rk3128-box.img (SDK板)

$ make rk3128-box-rk88.img(RK88样机)

B. 编译完将在kernel目录生成resource.img和kernel.img

5.2.2 Uboot 编译步骤

Uboot详细内容可参考《RockChip_Uboot开发文档V2.0》。编译命令如下,

$ make rk32xx_config

$ make

注意,编译之前需确认CONFIG_RKCHIPTYPE 是否为CONFIG_RK3128,代码位置如下:include/configs/rk32xx.h第40行附近:

#define CONFIG_RKCHIPTYPE CONFIG_RK3128

5.2.3 Android 编译步骤

注意:此SDK默认是512M内存版本,对低内存做了优化,但此优化会对性能产生一些影响,并且对系统做了些裁剪,如果是1G的内存,请把\device\rockchip\rk312x\ BoardConfig.mk BOARD_USE_LOW_MEM := true设置为false

Android编译命令如下:

$ source build/envsetup.sh

$ make

默认SDK以eng模式编译。如要使用user模式编译固件,可屏蔽buildspec.mk中的注释,如下:TARGET_BUILD_V ARIANT:=user

5.3 烧写说明

请参考“RK312X开发板使用手册V1.0.pdf”。

相关文档