RK3576 Developer Guide Android14 SDK en
RK3576 Developer Guide Android14 SDK en
[ √ ] Released
Finish Date: 2024-04-20
[ ] Modifying
Auditor: Jin Huajun
DISCLAIMER
THIS DOCUMENT IS PROVIDED “AS IS”. ROCKCHIP ELECTRONICS CO., LTD.(“ROCKCHIP”)DOES NOT
PROVIDE ANY WARRANTY OF ANY KIND, EXPRESSED, IMPLIED OR OTHERWISE, WITH RESPECT TO
THE ACCURACY, RELIABILITY, COMPLETENESS,MERCHANTABILITY, FITNESS FOR ANY PARTICULAR
PURPOSE OR NON-INFRINGEMENT OF ANY REPRESENTATION, INFORMATION AND CONTENT IN
THIS DOCUMENT. THIS DOCUMENT IS FOR REFERENCE ONLY. THIS DOCUMENT MAY BE UPDATED
OR CHANGED WITHOUT ANY NOTICE AT ANY TIME DUE TO THE UPGRADES OF THE PRODUCT OR
ANY OTHER REASONS.
Trademark Statement
"Rockchip", "瑞芯微", "瑞芯" shall be Rockchip’s registered trademarks and owned by Rockchip. All
the other trademarks or registered trademarks mentioned in this document shall be owned by
their respective owners.
Revision History
Version Revision
Author Revision Description Remark
no. Date
If there is any question about the document, please email to: [email protected]
Note: repo is a script invoking git developed by Google using Python script, and mainly used to
download, manage Android project software lib. The download address is as follows:
Generally, Rockchip FAE contact will provide the initial compressed package of the corresponding
version SDK in order to help customers acquire SDK source code quickly. Take
Rockchip_Android14.0_SDK_RELEASE.tar.gz.* as an example, you can sync the source code
through the following command after getting the initial package:
mkdir RK3576_Android14.0_SDK_RELEASE
cat RK3576_Android14.0_SDK_RELEASE.tar.gz* | tar -zx -C
RK3576_Android14.0_SDK_RELEASE
cd RK3576_Android14.0_SDK_RELEASE
.repo/repo/repo sync -l
.repo/repo/repo sync -c
Environment
You can install openssh-server for remote login, git for project management, and keychain for
public key and private key management tools.
mkdir -p ~/bin
7. Please execute following commands to install gitolite, and the installation method is
different for different versions. Please refer to the documentation in source code:
Client-side operation
cp username.pub keydir/username.pub
vi conf/gitolite.conf
@admin = admin1 admin2 admin3
repo gitolite-admin
RW+ = @admin
mkdir RK_Android14_mirror
cd RK_Android14_mirror
Client-side operation
vi conf/android_u.conf
@usergroup = user1 user2 user3
repo @android_u
R = @usergroup
RW+ = @admin
vi conf/gitolite.conf
include "android_u.conf"
vi conf/android_u.conf
@android_u = Android_T/manifests_xxx
Client-side operation
1. Download manifests_xxx warehouse on the client-side;
Download manifests_xxx.git warehouse on other client-side
cd manifests_xxx
cp -rf manifests/*.xml manifests_xxx/
git status
Android14.xml
Android14_Express.xml
default.xml
include/rk3576_repository.xml
include/rk_checkout_from_aosp.xml
include/rk_modules_repository.xml
remote.xml
remove_u.xml
remove_unused.xml
Local commits
git add -A
git commit -m "init xxx"
After following the above steps, your own code download link is as follows
mkdir Android14
cd Android14
~/repo/repo init -u ssh://[email protected]/Android_U/manifests_xxx.git -m
Android14.xml
Thereinto:
//10.10.10.206 which is your server address
You can complete your own repo server set-up with above steps, and you can share your code
server links with colleagues to work together.
Code management
After setting up the code server with above steps, most of the code warehouses use the default
branches of RK. If some warehouses need to modify their own codes, you can refer to the
following steps for operation.
cd kernel-6.1
Thereinto, rk29 is remote, which can be completed automatically by tab key directly
4. Enter .repo/manifests directory and modify the branch which is appointed by manifest;
Enter .repo/manifests directory, and you can find the manifest location corresponding to the
kernel warehouse by grep kernel
cd .repo/manifests
--- a/include/rk_modules_repository.xml
+++ b/include/rk_modules_repository.xml
@@ -10,7 +10,7 @@
<project path="hardware/rockchip/libgraphicpolicy"
name="rk/hardware/rk29/libgraphicpolicy" remote="rk"
revision="refs/tags/android-1s.0-mid-rkr1" />
<project path="hardware/rockchip/libhwjpeg" name="rk/hardware/rk29/libhwjpeg"
remote="rk" revision="refs/tags/android-14.0-mid-rkr1"/>
<project path="u-boot" name="rk/u-boot" remote="rk"
revision="refs/tags/android-14.0-mid-rkr1"/>
- <project path="kernel" name="rk/kernel" remote="rk29"
revision="refs/tags/android-14.0-mid-rkr1"/>
+ <project path="kernel" name="rk/kernel" remote="rk29" revision="xxx_branch"/>
<project path="bootable/recovery/rkupdate"
name="platform/bootable/recovery/rk_update" remote="rk"
revision="refs/tags/android-14.0-mid-rkr1"/>
<project path="bootable/recovery/rkutility"
name="platform/bootable/recovery/rk_utility" remote="rk"
revision="refs/tags/android-14.0-mid-rkr1"/>
Synchronize RK codes
1. It's required to synchronize RK codes on the server-side;
cd RK_Android14_mirror
.repo/repo/repo sync -c
The manifests (RK original) and the manifests_xxx (yourselves) are compared with the contrast
tools to combine the different parts that RK modifies to your own warehouses (mainly modify the
tag, adding and removing the warehouse, etc)
After comparing and confirming, the modification will be pushed to the manifests_xxx.
You can also confirm which warehouses are modified in this step, and in the next step you will
combine the modified warehouses.
3. The directories switched branches by yourselves need to push the merge that RK modifies
to your own branches manually.
Take kernel as an example:
You can find that the branch pointed at present is: remotes/m/master ->
rk29/xxx_branch
Check if there is a conflict. If there is a conflict, resolve the conflict firstly. You can execute the
next step when there is no conflict.
push the codes which have been combined to the remote branch
The other directories swiched can be combined and submitted in this way
Code compiling
Lunch item Description
lunch chipest
other description
item adapted
./build.sh -UKAup
( WHERE: -U = build uboot
-C = build kernel with Clang
-K = build kernel
-A = build android
-p = will build packaging in IMAGE
-o = build OTA package
-u = build update.img
-v = build android with 'user' or 'userdebug'
-d = huild kernel dts name
-V = build version
-J = build jobs
------------you can use according to the requirement, no need to record
uboot/kernel compiling commands------------------
)
============================================================
Please remember to set the environment variable before using the one key
compiling command, and select the platform to be compiled, for example:
source build/envsetup.sh
lunch rk3588_t-userdebug
============================================================
The
one key kernel uboot
Soc type reference Android
compiling compiling compiling
model
GKI
To enable GKI (Generic Kernel Image) functionality on the RK3576 platform, follow these steps:
BOARD_GRAVITY_SENSOR_SUPPORT := true
The following compilation is only applicable for non-GKI. For GKI, please refer to the document
RKDocs/android/《Rockchip_Developer_Guide_Android14_GKI_CN》.
The kernel.img and resource.img of Android 14.0 are included in the boot.img. To compile the
kernel, use the build.sh -AK command. After compilation, burn the boot.img under rockdev. This
process involves recompiling Android, so compilation time will be relatively long. It is
recommended to use the following method to compile the kernel separately.
Compile Kernel Separately to Generate boot.img
Principle of compilation: Replace the compiled kernel.img and resource.img in the kernel
directory with the old boot.img.
Taking the RK3576 prototype as an example, replace the corresponding boot.img and DTS during
compilation. Here, BOOT_IMG=../rockdev/Image-rk3576_u/boot.img specifies the path of the old
boot.img. The command is as follows:
cd kernel-6.1
export PATH=../prebuilts/clang/host/linux-x86/clang-r487747c/bin:$PATH
alias msk='make CROSS_COMPILE=aarch64-linux-gnu- LLVM=1 LLVM_IAS=1'
rk3576:
msk ARCH=arm64 rockchip_defconfig android-14.config rk3576.config && msk
ARCH=arm64 BOOT_IMG=../rockdev/Image-rk3576_u/boot.img rk3576-evb1-v10.img -j32
You can flash boot.img under the catalogue of kernel-6.1 directly to boot position of machine
after compiling, and please load the partition table(parameter.txt) when flashing, for fear of
flashing to the wrong place.
Image flashing
Image flashing tool
Android14 requires to update the USB driver DriverAssitant to V5.1.1 version. You can refer to the
tool instruction chapter to do the upgrade.
Windows flashing tool:
The firmware burning tool for the RK3576 platform on Windows requires the use of version
3.28 or above.
RKTools/windows/AndroidTool/AndroidTool_Release_v3.28
Linux烧写工具:
<span style="color:red;">**The firmware flashing tool for the RK3576 platform on
Linux requires the use of version 2.30 or above.**</span>
RKTools/linux/Linux_Upgrade_Tool/Linux_Upgrade_Tool_v2.30
Image instruction
rockdev/Image-rk3576_u/
├── boot-debug.img
├── boot.img
├── config.cfg
├── dtbo.img
├── MiniLoaderAll.bin
├── misc.img
├── parameter.txt
├── pcba_small_misc.img
├── pcba_whole_misc.img
├── recovery.img
├── resource.img
├── super.img
├── uboot.img
├── update.img
└── vbmeta.img
Image instruction
Image Instruction
the configuration file of the flash tool, you can directly load the
config.cfg
options required to be flashed for the flash tool
including the above img files to be flashed, can be used for the
update.img
tool to directly flash the whole image package
RKDocs/android/Rockchip_Developer_Guide_Android14_GKI_CN.pdf
Note: After entering fastbootd mode, relative information of the device will be displayed on the
screen, as shown below:
Note: please enter bootloader when using fastboot in the non-dynamic partition:
Use DSU(Dynamic System Updates) to flash GSI, and current Rockchip platform already
supports DSU by default. As this function requires large memory, it is not recommended to
use on the device with 1G DDR or less. For the instruction and usage of DSU, please refer to
Android official website:
https://source.android.com/devices/tech/ota/dynamic-system-updates
Note 1: when testing VTS, need to flash the compiled boot-debug.img to boot partition.
Note 2: when testing CTS-ON-GSI, no need to flash boot-debug.img.
Note 3: please use GSI image ended with -signed released by Google for testing.
DTBO function
Android 10.0 and above versions support Device Tree Overlays function, which requires to flash
dtbo.img during development, and is compatible with multiple products.
The modification method:
get_build_var PRODUCT_DTBO_TEMPLATE
For example:
PRODUCT_DTBO_TEMPLATE := $(LOCAL_PATH)/dt-
overlay.in(device/rockchip/rk576/rk3576_u/dt-overlay.in)
/dts-v1/;
/plugin/;
&chosen {
bootargs_ext = "androidboot.boot_devices=${_boot_device}";
};
&firmware_android {
vbmeta {
status = "disabled";
};
fstab {
status = "disabled";
};
};
&reboot_mode {
mode-bootloader = <0x5242C309>;
mode-charge = <0x5242C30B>;
mode-fastboot = <0x5242C303>;
mode-loader = <0x5242C301>;
mode-normal = <0x5242C300>;
mode-recovery = <0x5242C303>;
};
Note: There must be alias in the dts when using dtbo, otherwise it cannot overlay
successfully
get_build_var PRODUCT_FSTAB_TEMPLATE
For example:
PRODUCT_FSTAB_TEMPLATE := device/rockchip/common/scripts/fstab_tools/fstab.in
2. Modify: add partition mounting, modify swap_zram parameter, modify data partition format
and so on
Modify parameter.txt
Android 14 adds the tool that can generate parameter.txt, and support to compile parameter.txt
according to the configuration parameters. If there is no configuration template file, it will find
and add the modified parameter.txt file.
get_build_var PRODUCT_PARAMETER_TEMPLATE
For example:
PRODUCT_PARAMETER_TEMPLATE :=
device/rockchip/common/scripts/parameter_tools/parameter.in
2. Partition size configuration(example as below):
BOARD_SUPER_PARTITION_SIZE := 2688548864
BOARD_DTBOIMG_PARTITION_SIZE := xxxx
BOARD_BOOTIMAGE_PARTITION_SIZE := xxxxx
BOARD_CACHEIMAGE_PARTITION_SIZE := xxxx
device/rockchip/rk3576/rk3576_u/parameter.txt
parameter_tools --input
device/rockchip/common/scripts/parameter_tools/parameter.in --firmware-version
14.0 --machine-model rk3576 --manufacturer rockchip --machine rk3576_u --
partition-list
uboot_a:4096K,trust_a:4M,misc:4M,dtbo_a:4M,vbmeta_a:4M,boot_a:33554432,backup:30
0M,security:4M,cache:300M,metadata:4096,frp:512K,super:2G --output
parameter_new.txt
Note: If need to do the big version upgrade through OTA, please directly use the previous
version's parameter.txt
device/rockchip/rk3576/rk3576_u/BoardConfig.mk
+++ b/BoardConfig.mk
@@ -494,4 +494,11 @@ ifeq ($(strip $(BOARD_TWRP_ENABLE)), true)
+BOARD_WITH_SPECIAL_PARTITIONS := baseparameter:1M
device/rockchip/common/build/rockchip/RebuildParameter.mk
+ifneq ($(strip $(BOARD_WITH_SPECIAL_PARTITIONS)), )
+partition_list := $(partition_list),$(BOARD_WITH_SPECIAL_PARTITIONS)
+endif
cp -r rk3576_u rk3576_new_u
4. Once you have copied the directory, navigate into the rk3576_new_u directory.
5. Replace all occurrences of the string rk3576_u with rk3576_new_u in the files inside the
rk3576_new_u directory. You can use tools like sed or manually edit the files to make the
changes.
For example, you can use sed command like this:
sed -i 's/rk3576_u/rk3576_new_u/g' *
This command will replace all occurrences of rk3576_u with rk3576_new_u in all files inside the
rk3576_new_u directory.
6. Once you have made the changes, your new product directory rk3576_new_u is ready for
further customization and development.
Patch release
Redmine system will release some important patches from time to time, the link is as follows:
https://redmine.rock-chips.com/projects/rockchip_patch/issues
You can subscribe to receive real-time email notification of patch release in the following ways:
Step 1: Log in to redmine system
Log in to redmine system with redmine account registered with Rockchip.
Step 2: access my account
Done:
After a successful subscription, Rockchip can receive email notifications when patches are
released through the email address registered on redmine.
Document instruction
https://redmine.rockchip.com.cn/projects/fae/documents
external/camera_engine_rkaiq/rkisp2x_tuner/doc/
├── Rockchip_Color_Optimization_Guide_ISP2x_CN_v2.0.0.pdf
├── Rockchip_IQ_Tools_Guide_ISP2x_CN_v2.0.0.pdf
└── Rockchip_Tuning_Guide_ISP21_CN_v2.0.0.pdf
hardware/rockchip/rknn-toolkit2/doc/
RKDocs Instruction
RKDocs/
├── android
│ ├── Android11 异显开发说明.zip
│ ├── audio
│ │ └── Rockchip_Developer_Guide_Android_Multi_Audio_CN.pdf
│ ├── bt
│ │ └── Rockchip_Introduction_Android9.0_BT_Configuration_CN.pdf
│ ├── patches
│ │ └── root
│ │ ├── android11_root.pdf
│ │ └── RootChecker.apk
│ ├── Rockchip_Android14_GKI_Developer_Guide_CN.pdf
│ ├── Rockchip_Android14_SDK_Developer_Guide_CN.pdf
│ ├── Rockchip_Android14_SDK_Developer_Guide_EN.pdf
│ ├── Rockchip_Android_Remote_key_Provisioning_Guide.pdf
│ ├── Rockchip_Developer_Guide_Android11_Optimization_CN.pdf
│ ├── Rockchip_Developer_Guide_Android_AB_System_Upgrading_CN.pdf
│ ├── Rockchip_Developer_Guide_Android_Recovery_CN.pdf
│ ├── Rockchip_Developer_Guide_Android_SELinux(Sepolicy)CN.pdf
│ ├── Rockchip_Developer_Guide_PCBA_Test_Tool_V1.3_CN&EN.pdf
│ ├── Rockchip_Firmware_Upgrade_Failed_Analyze_Method_CN.pdf
│ ├── Rockchip_Introduction_Android_Application_Preinstallation_CN&EN.pdf
│ ├── Rockchip_Introduction_Android_Boot_Video_CN.pdf
│ ├── Rockchip_Introduction_Android_BOX_Display_Framework_Configuration_CN.pdf
│ ├── Rockchip_Introduction_Android_Factory_Reset_Protection_CN&EN.pdf
│ ├── Rockchip_Introduction_Android_Log_System.pdf
│ ├── Rockchip_Introduction_Android_Performance_Mode_CN&EN.pdf
│ ├──
Rockchip_Introduction_Android_Power_On_Off_Animation_and_Tone_Customization_CN&EN.pdf
│ ├── Rockchip_Introduction_Android_Samba_CN.pdf
│ ├── Rockchip_Introduction_Android_Widevine_Project_Start_Preparation_CN.pdf
│ ├── Rockchip_Introduction_Box_Media_Application_CN&EN.pdf
│ ├── Rockchip-Parameter-File-Format-Version1.4-CN.pdf
│ ├── Rockchip_User_Guide_Android_GMS_Configuration_CN.pdf
│ ├── Rockchip_User_Guide_Android_GMS_Configuration_EN.pdf
│ ├── Rockchip_User_Guide_Box_FactoryTestTool_V3.0_CN.pdf
│ ├── Rockchip_User_Guide_Dr.G_CN&EN.pdf
│ ├── Rockchip_User_Guide_Magisk_Installation_EN.pdf
│ ├── video
│ │ └── Rockchip_Android_Multimedia_FAQ_CN.pdf
│ └── wifi
│ ├── Rockchip_Introduction_REALTEK_WIFI_Driver_Porting_CN&EN.pdf
│ └── Rockchip_Introduction_WIFI_Configuration_CN&EN.pdf
└── common
├── Audio
│ ├── Rockchip_Developer_Guide_Android_EQ_DRC_CN.pdf
│ ├── Rockchip_Developer_Guide_Android_Multi_Audio_CN.pdf
│ ├──
Rockchip_Developer_Guide_Audio_Call_3A_Algorithm_Integration_and_Parameter_Debugging_CN.pdf
│ ├── Rockchip_Developer_Guide_Audio_CN.pdf
│ └── Rockchip_Developer_Guide_RK817_RK809_Codec_CN.pdf
├── camera
│ ├── common
│ │ └── Camera_External_FAQ_v1.0 .pdf
│ ├── HAL1
│ │ ├── README_CN.txt
│ │ ├── README_EN.txt
│ │ ├── RK312x_Camera_User_Manual_v1.4(3288&3368).pdf
│ │ ├── RK_ISP10_Camera_User_Manual_v2.3.pdf
│ │ ├── RKISPV1_Camera_Module_AVL_v1.7.pdf
│ │ ├── Rockchip_Camera_AVL_v2.0_Package_20180515.7z
│ │ ├── Rockchip_Introduction_RKISPV1_Camera_Driver_Debugging_Method_CN.pdf
│ │ ├── Rockchip_Introduction_RKISPV1_Camera_FAQ_CN.pdf
│ │ ├── Rockchip SOFIA 3G-R_PMB8018(x3_C3230RK)Camera_Module_AVL_v1.6_20160226.pdf
│ │ └── Rockchip_Trouble_Shooting_Android_CameraHAL1_CN_EN.pdf
│ ├── HAL3
│ │ ├── camera_engine_rkisp_user_manual_v2.2.pdf
│ │ ├── camera_hal3_user_manual_v2.3.pdf
│ │ ├── README_CN.txt
│ │ ├── RKCIF_Driver_User_Manual_v1.0.pdf
│ │ ├── RKISP1_IQ_Parameters_User_Guide_v1.2.pdf
│ │ ├── RKISP_Driver_User_Manual_v1.3.pdf
│ │ ├── Rockchip_Color_Optimization_Guide_ISP
│ │ │ ├── ISP21
│ │ │ │ └── CN
│ │ │ │ └── Rockchip_Color_Optimization_Guide_ISP21_CN_v2.0.1.pdf
│ │ │ ├── ISP30
│ │ │ │ └── CN
│ │ │ │ └── Rockchip_Color_Optimization_Guide_ISP30_CN_v3.0.0.pdf
│ │ │ └── ISP32-lite
│ │ │ └── CN
│ │ │ └── Rockchip_Color_Optimization_Guide_ISP32_Lite_CN_v3.1.0.pdf
│ │ ├── Rockchip_Development_Guide_3A_ISP
│ │ │ └── ISP30
│ │ │ └── CN
│ │ │ └── Rockchip_Development_Guide_3A_ISP30_v1.1.0.pdf
│ │ ├── Rockchip_Development_Guide_ISP
│ │ │ ├── ISP21
│ │ │ │ └── CN
│ │ │ │ └── Rockchip_Development_Guide_ISP21_CN_v2.1.0.pdf
│ │ │ ├── ISP30
│ │ │ │ └── CN
│ │ │ │ └── Rockchip_Development_Guide_ISP30_CN_v1.2.3.pdf
│ │ │ └── ISP32-lite
│ │ │ └── CN
│ │ │ └── Rockchip_Development_Guide_ISP32_Lite_CN_v1.0.0.pdf
│ │ ├── Rockchip_Driver_Guide_VI
│ │ │ ├── CN
│ │ │ │ └── Rockchip_Driver_Guide_VI_CN_v1.1.4.pdf
│ │ │ └── EN
│ │ │ └── Rockchip_Driver_Guide_VI_EN_v1.0.7.pdf
│ │ ├── Rockchip_IQ_Tools_Guide_ISP
│ │ │ ├── ISP21
│ │ │ │ └── Rockchip_IQ_Tools_Guide_ISP2x_CN_v2.0.3.pdf
│ │ │ ├── ISP30
│ │ │ │ └── Rockchip_IQ_Tools_Guide_ISP21_ISP30_CN_v2.0.4.pdf
│ │ │ └── ISP32-lite
│ │ │ └── CN
│ │ │ └── Rockchip_IQ_Tools_Guide_v2.0.7_CN.pdf
│ │ ├── Rockchip_Trouble_Shooting_CameraHAL3_CN_EN.pdf
│ │ ├── Rockchip_Tuning_Guide_ISP
│ │ │ ├── ISP21
│ │ │ │ └── CN
│ │ │ │ └── Rockchip_Tuning_Guide_ISP21_CN_v2.1.0.pdf
│ │ │ ├── ISP30
│ │ │ │ └── CN
│ │ │ │ └── Rockchip_Tuning_Guide_ISP30_CN_v1.1.0.pdf
│ │ │ └── ISP32-lite
│ │ │ └── CN
│ │ │ └── Rockchip_Tuning_Guide_ISP32-lite_CN_v1.0.0.pdf
│ │ └── USB_UVC_Integrated_Cameras.pdf
│ ├── README.txt
│ └── vehicle
│ └── Rockchip_Android_Fast_Reverse_Image_System_Developer_Guide_CN_V1.0.3.pdf
├── Can
│ ├── Rockchip_Developer_Guide_Can_CN.pdf
│ └── Rockchip_Developer_Guide_CAN_FD_CN.pdf
├── CLK
│ ├── Rockchip_Developer_Guide_Clock_CN.pdf
│ ├── Rockchip_Developer_Guide_Gpio_Output_Clocks_CN.pdf
│ ├── Rockchip_Develop_Guide_Pll_Ssmod_Clock_CN.pdf
│ └── Rockchip_RK3399_Developer_Guide_Clock_CN.pdf
├── CRU
│ ├── Rockchip_Developer_Guide_Linux3.10_Clock_CN.pdf
│ ├── Rockchip_Developer_Guide_Linux4.4_4.19_Clock_CN.pdf
│ ├── Rockchip_Develop_Guide_Pll_Ssmod_Clock_CN.pdf
│ ├── Rockchip_RK3399_Developer_Guide_Clock_CN.pdf
│ └── Rockchip_RK3399_Developer_Guide_Linux4.4_Clock_CN.pdf
├── CRYPTO
│ ├── Rockchip_Developer_Guide_Crypto_HWRNG_CN.pdf
│ └── Rockchip_Developer_Guide_Crypto_HWRNG_EN.pdf
├── DDR
│ ├── DDR_bandwidth_statistics_tool
│ │ ├── rk-msch-probe-for-user-32bit
│ │ ├── rk-msch-probe-for-user-64bit
│ │ └── Rockchip_Introduction_DDR_Bandwidth_Tool_CN.pdf
│ ├── Rockchip-Developer-Guide-DDR-CN.pdf
│ ├── Rockchip-Developer-Guide-DDR-EN.pdf
│ ├── Rockchip-Developer-Guide-DDR-Problem-Solution-CN.pdf
│ ├── Rockchip-Developer-Guide-DDR-Problem-Solution-EN.pdf
│ ├── Rockchip-Developer-Guide-DDR-Verification-Process-CN.pdf
│ ├── Rockchip_Developer_Guide_DDR_Verification_Process_EN.pdf
│ ├── Rockchip_Developer_Guide_HAL_DDR_ECC_CN.pdf
│ └── Rockchip-User-Guide-DDR-DQ-Eye-Tool-CN.pdf
├── debug
│ ├── RK3399-LOG-EXPLANATION.pdf
│ ├── Rockchip_Developer_Guide_DS5_CN.pdf
│ ├── Rockchip_Quick_Start_Linux_Perf.pdf
│ ├── Rockchip_Quick_Start_Linux_Streamline.pdf
│ ├── Rockchip_Quick_Start_Linux_Systrace.pdf
│ ├── Rockchip_RK3399_JTAG_Configuration_CN.pdf
│ └── Rockchip_User_Guide_J-Link_CN.pdf
├── display
│ ├── Rockchip_BT656_TX_AND_BT1120_TX_Developer_Guide_CN.pdf
│ ├── Rockchip_Developer_Guide_Baseparameter_Format_Define_And_Use_CN.pdf
│ ├── Rockchip_Developer_Guide_DRM_Display_Driver_CN.pdf
│ ├── Rockchip_Developer_Guide_DRM_Panel_Porting_CN&EN.pdf
│ ├── Rockchip_Developer_Guide_DRM_Panel_Porting_CN.pdf
│ ├── Rockchip_Developer_Guide_Dual_Display_Rotation_Direction_Debugging_CN.pdf
│ ├── Rockchip_Developer_Guide_HDMI_Based_on_DRM_Framework_CN&EN.pdf
│ ├── Rockchip_Developer_Guide_HDMI-CEC_CN.pdf
│ ├── Rockchip_Developer_Guide_HDMI_CN.pdf
│ ├── Rockchip_Develop_Guide_DRM_Direct_Show_CN.pdf
│ ├── Rockchip_Display_Issues_FAQ_V1.1.pdf
│ ├── Rockchip_DRM_RK628_Porting_Guide_CN.pdf
│ ├── Rockchip FAQ DRM Hardware Composer V1.00-20181213.pdf
│ ├── Rockchip_Introduction_DisplayAdjust_APK_CN.pdf
│ ├── Rockchip_Introduction_DRM_Integration_Helper_CN.pdf
│ ├── Rockchip_RK3588_Developer_Guide_DisplayPort_CN.pdf
│ ├── Rockchip_RK3588_Developer_Guide_MIPI_DSI2_CN.pdf
│ ├── Rockchip_RK3588_Developer_Guide_Vsync_Adjust_CN.pdf
│ ├── Rockchip_RK3588_User_Guide_DP_CN.pdf
│ ├── Rockchip_RK3588_User_Guide_eDP_CN.pdf
│ └── Rockchip_Trouble_Shooting_Graphics
├── DVFS
│ ├── Rockchip_Developer_Guide_CPUFreq_CN.pdf
│ ├── Rockchip_Developer_Guide_CPUFreq_EN.pdf
│ ├── Rockchip_Developer_Guide_Devfreq_CN.pdf
│ ├── Rockchip_Developer_Guide_Devfreq_EN.pdf
│ ├── Rockchip_Developer_Guide_Linux4.4_CPUFreq_CN.pdf
│ └── Rockchip_Developer_Guide_Linux4.4_Devfreq_CN.pdf
├── Ebook
│ ├── Rockchip_RK3566_Introduction_EBOOK_Display_Mode_CN.pdf
│ └── Rockchip_RK3566_Introduction_EBOOK_Sleep_Mode_CN.pdf
├── GMAC
│ ├── Rockchip_Developer_Guide_Ethernet_CN.pdf
│ ├── Rockchip_Developer_Guide_Linux_GMAC_CN.pdf
│ ├── Rockchip_Developer_Guide_Linux_GMAC_Mode_Configuration_CN.pdf
│ ├── Rockchip_Developer_Guide_Linux_GMAC_RGMII_Delayline_CN.pdf
│ └── Rockchip_Developer_Guide_Linux_GMAC_RGMII_Delayline_EN.pdf
├── hdmi-in
│ ├── apk
│ │ ├── HdmiInDemo_based_on_CameraHal1_2020.06.11_v1.2.tar.gz
│ │ └── rkCamera2_based_on_CameraHal3_V1.3.tar.gz
│ ├── Rockchip_Developer_Guide_HDMI_IN_Based_On_CameraHal1_CN.pdf
│ ├── Rockchip_Developer_Guide_HDMI_IN_Based_On_CameraHal3_CN.pdf
│ └── Rockchip_Developer_Guide_HDMI_RX_CN.pdf
├── I2C
│ ├── Rockchip_Developer_Guide_I2C_CN.pdf
│ └── Rockchip_Developer_Guide_I2C_EN.pdf
├── IO-Domain
│ ├── Rockchip_Developer_Guide_Linux_IO_DOMAIN_CN.pdf
│ ├── Rockchip_PX30_Introduction_IO_Power_Domains_Configuration.pdf
│ ├── Rockchip_RK3288_Introduction_IO_Power_Domains_Configuration.pdf
│ ├── Rockchip_RK3326_Introduction_IO_Power_Domains_Configuration.pdf
│ ├── Rockchip_RK3399_Introduction_IO_Power_Domains_Configuration.pdf
│ ├── Rockchip_RK3399Pro_Introduction_IO_Power_Domains_Configuration.pdf
│ └── Rockchip_RK356X_Introduction_IO_Power_Domains_Configuration.pdf
├── IOMMU
│ ├── Rockchip_Developer_Guide_Linux_IOMMU_CN.pdf
│ └── Rockchip_Developer_Guide_Linux_IOMMU_EN.pdf
├── Leds
│ └── Rockchip_Introduction_Leds_GPIO_Configuration_for_Linux4.4_CN.pdf
├── MCU
│ ├── Rockchip_RK3399_Developer_Guide_MCU_CN.pdf
│ └── Rockchip_RK3399_Developer_Guide_MCU_EN.pdf
├── Memory
│ └── Rockchip_Developer_Guide_Linux_CMA_CN.pdf
├── MMC
│ ├── Rockchip_Developer_Guide_SD_Boot_CN.pdf
│ └── Rockchip_Developer_Guide_SDMMC_SDIO_eMMC_CN.pdf
├── mobile-net
│ ├── Rockchip_Introduction_3G_Data_Card_USB_File_Conversion_CN.pdf
│ ├── Rockchip_Introduction_3G_Dongle_Configuration_CN&EN.pdf
│ └── Rockchip_Introduction_4G_Module_Configuration_CN&EN.pdf
├── MPP
│ ├── Rockchip_Developer_Guide_MPP_CN.pdf
│ └── Rockchip_Developer_Guide_MPP_EN.pdf
├── NVM
│ ├── Rockchip_Application_Notes_Storage_CN.pdf
│ ├── Rockchip_Developer_FAQ_Storage_CN.pdf
│ ├── Rockchip_Developer_Guide_OTP_CN.pdf
│ ├── Rockchip_Developer_Guide_OTP_EN.pdf
│ ├── Rockchip_Developer_Guide_SATA_CN.pdf
│ ├── Rockchip_Introduction_Partition_CN.pdf
│ ├── Rockchip_Introduction_Partition_EN.pdf
│ └── Rockchip_RK356X_Developer_Guide_SATA_CN.pdf
├── PCie
│ ├── Rockchip-Developer-Guide-linux4.4-PCIe.pdf
│ ├── Rockchip_Developer_Guide_PCIe_CN.pdf
│ ├── Rockchip_PCIe_Virtualization_Developer_Guide_CN.pdf
│ └── Rockchip_RK3399_Developer_Guide_PCIe_CN.pdf
├── perf
│ ├── perf使用说明.pdf
│ ├── Rockchip_Developer_FAQ_FileSystem_CN.pdf
│ ├── Rockchip_Optimize_Tutorial_Linux_IO_CN.pdf
│ ├── Rockchip_Quick_Start_Linux_Performance_Analyse_CN.pdf
│ └── systrace使用说明.pdf
├── PIN-Ctrl
│ ├── Rockchip_Developer_Guide_Linux_Pinctrl_CN.pdf
│ └── Rockchip_Developer_Guide_Linux_Pinctrl_EN.pdf
├── PMIC
│ ├── Rockchip_Developer_Guide_FreeRTOS_PMIC_CHARGER_POWERKEY_CN.pdf
│ ├── Rockchip_Developer_Guide_Power_Discrete_DCDC_EN.pdf
│ ├── Rockchip_Developer_Guide_RK817_RK809_Fuel_Gauge_CN&EN.pdf
│ ├── Rockchip_RK805_Developer_Guide_CN.pdf
│ ├── Rockchip_RK806_Developer_Guide_CN.pdf
│ ├── Rockchip_RK808_Developer_Guide_CN.pdf
│ ├── Rockchip_RK809_Developer_Guide_CN.pdf
│ ├── Rockchip_RK816_Developer_Guide_CN.pdf
│ ├── Rockchip_RK817_Developer_Guide_CN.pdf
│ ├── Rockchip_RK818_Developer_Guide_CN.pdf
│ ├── Rockchip_RK818_RK816_Developer_Guide_Fuel_Gauge_CN.pdf
│ └── Rockchip_RK818_RK816_Introduction_Fuel_Gauge_Log_CN.pdf
├── power
│ ├── Rockchip_Developer_Guide_Power_Analysis_EN.pdf
│ └── Rockchip_Developer_Guide_Sleep_and_Resume_CN.pdf
├── PWM
│ ├── Rockchip_Developer_Guide_Linux_PWM_CN.pdf
│ ├── Rockchip_Developer_Guide_Linux_PWM_EN.pdf
│ └── Rockchip_Developer_Guide_PWM_IR_CN.pdf
├── RGA
│ ├── Rockchip_Developer_Guide_RGA_CN.pdf
│ ├── Rockchip_Developer_Guide_RGA_EN.pdf
│ ├── Rockchip_FAQ_RGA_CN.pdf
│ └── Rockchip_FAQ_RGA_EN.pdf
├── RK628
│ ├── Rockchip_RK628D_Application_Notes_CN.pdf
│ └── Rockchip_RK628D_For_All_Porting_Guide_CN.pdf
├── RKTools manuals
│ ├── RKIQTool_User_Manual_v1.5-CH.pdf
│ ├── RKIQTool_User_Manual_v1.5-EN.pdf
│ ├── RK_Platform_apache_tomcat_ota_Server_Setup_Introduction.rar
│ ├── Rockchip_Box_Factory_Test_Tool_V2.0.rar
│ ├── Rockchip_Developer_Guide_Linux_Nand_Flash_Open_Source_Solution_CN.pdf
│ ├── Rockchip_Introduction_Image_Upgrading_Failure_Analysis_CN.pdf
│ ├── Rockchip_Introduction_MP_Tool_Upgrading_and_Related_Issues_Debugging_CN.pdf
│ ├── Rockchip_Introduction_REPO_Mirror_Server_Build_and_Management_CN.pdf
│ ├── Rockchip_Introduction_Stresstest_for_VR_CN.pdf
│ ├── Rockchip_Introduction_WNpctool_Write_Tool_CN.pdf
│ ├── Rockchip_User_Guide_Box_Factory_Test_Tool_CN.pdf
│ ├── Rockchip_User_Guide_Keybox_Burning_EN.pdf
│ ├── Rockchip_User_Guide_KeyWrite_CN.pdf
│ ├── Rockchip_User_Guide_MP_Flashing_v1.2_CN.pdf
│ ├── Rockchip_User_Guide_Production_For_Firmware_Download_CN.pdf
│ ├── Rockchip_User_Guide_RKDevInfoWriteTool_CN.pdf
│ ├── Rockchip_User_Guide_RKDevInfoWriteTool_EN.pdf
│ ├── Rockchip_User_Guide_RK_Platform_MP_Upgrading_CN.pdf
│ ├── Rockchip_User_Manual_Android_Development_Tool_CN.pdf
│ ├── Rockchip_User_Manual_RKIQTool_CN.pdf
│ ├── Rockchip_User_Manual_RKIQTool_EN.pdf
│ ├── Rockchip_User_Manual_RKUpgrade_Dll_CN.pdf
│ └── SecureBootTool_UserManual.pdf
├── SARADC
│ ├── Rockchip_Developer_Guide_Linux_SARADC_CN.pdf
│ └── Rockchip_Developer_Guide_Linux_SARADC_EN.pdf
├── security
│ ├── patch
│ │ └── u-boot
│ │ └── 0001-avb-add-embedded-key.patch
│ ├── RK3399_Efuse_Operation_Instructions_V1.00_EN.pdf
│ ├── RK356X_SecurityBoot_And_AVB_instructions_CN.pdf
│ ├── RK356X_SecurityBoot_And_AVB_instructions_EN.pdf
│ ├── RK3588_SecurityBoot_And_AVB_instructions_CN.pdf
│ ├── RK3588_SecurityBoot_And_AVB_instructions_EN.pdf
│ ├── Rockchip_Developer_Guide_Crypto_HWRNG_CN.pdf
│ ├── Rockchip_Developer_Guide_Secure_Boot_Application_Note_EN.pdf
│ ├── Rockchip_Developer_Guide_Secure_Boot_for_UBoot_Next_Dev_CN.pdf
│ ├── Rockchip_Developer_Guide_Secure_Boot_for_UBoot_Next_Dev_EN.pdf
│ ├── Rockchip_Developer_Guide_TEE_SDK_CN.pdf
│ ├── Rockchip_RK3399_User_Guide_SecurityBoot_And_AVB_CN.pdf
│ └── Rockchip Vendor Storage Application Note.pdf
├── Sensors
│ └── Rockchip_Developer_Guide_Sensors_CN.pdf
├── SPI
│ ├── Rockchip_Developer_Guide_Linux_SPI_CN.pdf
│ └── Rockchip_Developer_Guide_Linux_SPI_EN.pdf
├── Thermal
│ ├── Rockchip_Developer_Guide_Thermal_CN.pdf
│ └── Rockchip_Developer_Guide_Thermal_EN.pdf
├── TRUST
│ ├── Rockchip_Developer_Guide_Trust_CN.pdf
│ ├── Rockchip_Developer_Guide_Trust_EN.pdf
│ └── Rockchip_RK3588_Developer_Guide_System_Suspend_CN.pdf
├── Tutorial
│ ├── RK3399-CPUINFO.pdf
│ ├── RK3399-LOG-EXPLANATION.pdf
│ ├── Rockchip_Developer_FAQ_FileSystem_CN.pdf
│ ├── Rockchip_Introduction_Browser_FAQ_CN.pdf
│ └── Rockchip_Trouble_Shooting_Firmware_Upgrade_Issue_CN.pdf
├── UART
│ ├── Rockchip-Developer-Guide-RT-Thread-UART.pdf
│ ├── Rockchip_Developer_Guide_UART_CN.pdf
│ ├── Rockchip_Developer_Guide_UART_EN.pdf
│ └── Rockchip_Developer_Guide_UART_FAQ_CN.pdf
├── u-boot
│ ├── Rockchip-Developer-Guide-Linux-AB-System.pdf
│ ├── Rockchip-Developer-Guide-Uboot-mmc-device-driver-analysis.pdf
│ └── Rockchip_Developer_Guide_UBoot_Nextdev_CN.pdf
├── usb
│ ├── Rockchip_Developer_Guide_Linux_USB_Initialization_Log_Analysis_CN_V1.1.1.pdf
│ ├── Rockchip_Developer_Guide_Linux_USB_Performance_Analysis_CN_V1.1.1.pdf
│ ├── Rockchip_Developer_Guide_Linux_USB_PHY_CN.pdf
│ ├── Rockchip_Developer_Guide_USB_CN.pdf
│ ├── Rockchip_Developer_Guide_USB_EN.pdf
│ ├── Rockchip_Developer_Guide_USB_FFS_Test_Demo_CN.pdf
│ ├── Rockchip_Developer_Guide_USB_FFS_Test_Demo_CN_V1.2.1.pdf
│ ├── Rockchip_Developer_Guide_USB_Gadget_UAC_CN.pdf
│ ├── Rockchip_Developer_Guide_USB_Gadget_UAC_CN_V1.1.1.pdf
│ ├── Rockchip_Developer_Guide_USB_SQ_Test_CN.pdf
│ ├── Rockchip_Introduction_USB_SQ_Tool_CN.pdf
│ ├── Rockchip_RK3399_Developer_Guide_USB_CN.pdf
│ ├── Rockchip_RK356x_Developer_Guide_USB_CN.pdf
│ ├── Rockchip_RK356X_User_Guide_USB_CN.pdf
│ ├── Rockchip_RK3588_Developer_Guide_USB_CN.pdf
│ └── Rockchip_User_Guide_USB_PHY_Tuning_CN.pdf
└── watchdog
├── Rockchip_Developer_Guide_Linux_WDT_CN.pdf
└── Rockchip_Developer_Guide_Linux_WDT_EN.pdf
Tool usage
StressTest
Use the Stresstest tool to do the stress test for the various functions on the target devices to
make sure the whole system running stably. SDK can start StressTest application and perform
stress test of various functions by entering “83991906=” code in the calculator.
The test items of Stresstest tool mainly include:
Module related
Camera stress test: including Camera on/off, Camera taking photo and Camera switch.
Bluetooth stress test: including Bluetooth on/off.
Wi-Fi stress test: including Wi-Fi on/off, (plan to add ping test and iperf test).
RKDocs\android\Rockchip_Developer_Guide_PCBA_Test_Tool_CN&EN.pdf_V1.1_20171222.p
df。
DeviceTest
DeviceTest is used for the whole device test in factory, which mainly test whether the peripheral
components work normally after assembling. SDK will enter DeviceTest by entering “000.=” code
in the calculator, as shown below:
In factory, you can test the corresponding peripheral according to this interface. Click “TEST
CHECKED” to test the items one by one. If succeed, click pass, if fail, click failed, the final result will
display on the screen, as shown below. Red means failed item, others are pass, and the factory
can repair accordingly based on the test result. Besides, if customers need to customize the tool,
please contact FAE to apply for the corresponding source code.
USB driver
Rockchip USB driver install package includes ADB and image flashing driver
RKTools\windows\DriverAssitant_v5.1.1.zip
RKTools/windows/AndroidTool/AndroidTool_Release_v3.28.zip
The tool version will update time by time, please synchronize and update in time.
Linux version
RKTools/linux/Linux_Upgrade_Tool/Linux_Upgrade_Tool_v2.30.zip
RKTools\windows\SDDiskTool_v1.74.zip
Write SN tool
RKTools\windows\RKDevInfoWriteTool-1.3.0.7z
Install after unzip RKDevInfoWriteTool-1.3.0.7z
Use admin ID to open the software
RKDocs\common\RKTools manuals\Rockchip_User_Guide_RKDevInfoWriteTool_CN.pdf
RKTools\windows\Rockchip_Platform_DDR_Test_Tool_V1.38_Release_Annoucement_CN.7z
RKTools\windows\Rockchip_Platform_DDR_Test_Tool_V1.38_Release_Annoucement_EN.7z
RKTools\windows\efuse_v1.37.rar
RKTools\windows\SecureBootTool_v1.94.zip
RKTools\windows\FactoryTool-1.72.9.7z
RKTools\windows\OemTool_v1.3.rar
Camera IQ Tool
It is used for debugging ISP image effects.
external/camera_engine_rkaiq/rkisp2x_tuner
System debugging
ADB tool
Overview
ADB (Android Debug Bridge) is a tool in Android SDK which can be used to operate and manage
Android simulator or the real Android device. The functions mainly include:
adb shell
3、Execute the command ”adb devices” to see if the connection is successful or not. If the device
serial number shows up, the connection is successful.
ADB commonly used command elaboration
(1)Check the device situation
Check the Android device or simulator connected to computer:
adb devices
The return result is the serial number or IP and port number, status of the Android device
connected to PC.
(2)Install APK
Install the specific apk file to the device:
For example:
Re-install application:
(3)Uninstall APK
Complete uninstall:
For example:
For example:
adb shell
Note: upload local “WishTV.apk” file to the “system/app” directory of the Android system.
(7)Download the file from the device to PC
Use pull command can download the file or folder from the device to local computer.
For example:
Note: download the file or folder from the “system/app” directory of Android system to local “F:\”
directory.
(8)Check bug report
Run adb bugreport command can check all the error message report generated by system. The
command will show all dumpsys, dumpstate and logcat information of the Android system.
(9)Check the device system information
The specific commands in adb shell to check the device system information.
Logcat tool
Android logcat system provides the function to record and check the system debugging
information. The logcats are all recorded from various softwares and some system buffer. The
buffer can be checked and used through Logcat. Logcat is the function most commonly used by
debugging program. The function shows the program running status mainly by printing logcat.
Because the amount of logcat is very large, need to do filtering and other operations.
Use logcat command to check the contents of the system logcat buffer:
The basic format:
For example:
adb shell
logcat
adb shell
logcat *:W
Note: show the logcat information with priority of warning or higher.
adb shell
logcat ActivityManager:I MyApp:D *:S
Note: support all the logcat information except those with label of “ActivityManager” and priority
of “Info” above, label of “MyApp” and priority of “Debug” above.
adb shell
logcat WishTV:* *:S
or
adb shell
logcat –s WishTV
Only output the logcat with the specific priority and label
For example:
adb shell
logcat WishTV:I *:S
Note: only output the logcat with priority of I and label of WishTV.
Procrank tool
Procrank is a debugging tool with Android, running in the shell environment of the device, used
to output the memory snapshot of the process in order to effectively observe the memory usage
status of the process.
Include the following memory information:
VSS:Virtual Set Size The memory size used by virtual (including the memory used by the
shared lib)
RSS:Resident Set Size The actually used physical memory size (including the memory used
by the shared lib)
PSS:Proportional Set Size The actually used physical memory size (allocate the memory
used by the shared lib in proportion)
USS:Unique Set Size The physical memory used exclusively by the process (not including
the memory used by the shared lib)
Note:
USS size represents the memory size only used by the process, and it will be completely
recovered after the process is killed.
VSS/RSS includes the memory used by the shared lib, so it is not helpful to check the
memory status of the single process.
PSS is the shared memory status used by the specific single process after the shared
memory is allocated in proportion.
Use procrank
Make sure the terminal has the root authority before executing procrank
su
The command format:
procrank [ -W ] [ -v | -r | -p | -u | -h ]
procrank
procrank –v
Use below command format to view the memory status of the specific process:
cmdline means the target application name, PID means the target application process.
Output the memory status used by systemUI process:
or:
Analyze if there is memory leakage in the process by tracing the memory usage status. Use the
script to continuously output the process memory snapshot, and compare with USS segment to
see if there is memory leakage in this process.
For example: output the application memory usage of the process named com.android.systemui
to see if there is leakage:
1、Write the script test.sh
#!/bin/bash
while true;do
adb shell procrank | grep “com.android.systemui”
sleep 1
done
2、After connect to the device by adb tool, run the script: ./test.sh
Dumpsys tool
Dumpsys tool is a debugging tool in Android system, running in the shell environment of the
device, and provides the service status information running in the system. The running service
means the service process in the Android binder mechanism.
The conditions for dumpsys to output the print:
1、Only print the services already loaded to ServiceManager.
2、If the dump function in the service code is not implemented, there will be no information
output.
Use Dumpsys
dumpsys -help
dumpsys -l
dumpsys SurfaceFlinger
Note: the service name is case sensitive and must input the full service name.
ramoops {
compatible = "ramoops";
record-size = <0x0 0x20000>;
console-size = <0x0 0x80000>;
ftrace-size = <0x0 0x00000>;
pmsg-size = <0x0 0x50000>;
memory-region = <&ramoops_mem>;
};
Usage:
cat dmesg-ramoops-0
cat console-ramoops-0
logcat -L (pmsg-ramoops-0) pull out by logcat and parse
cat ftrace-ramoops-0
FIQ mode
You can input fiq command through the serial port to check the system status when the device
crashes or gets stuck. The specific command is as below:
127|console:/ $ fiq
debug> help
FIQ Debugger commands:
pc PC status
regs Register dump
allregs Extended Register dump
bt Stack trace
reboot [<c>] Reboot with command <c>
reset [<c>] Hard reset with command <c>
irqs Interupt status
kmsg Kernel log
version Kernel version
sleep Allow sleep while in FIQ
nosleep Disable sleep while in FIQ
console Switch terminal to console
cpu Current CPU
cpu <number> Switch to CPU<number>
ps Process list
sysrq sysrq options
sysrq <param> Execute sysrq with <param>
Common issues
What is current kernel version and u-boot version?
The corresponding kernel version of Android14.0 is: 6.1, u-boot branch is next-
dev branch
RK modification part
vim .repo/manifests/include/rk_checkout_from_aosp.xml
<project groups="pdk" name="platform/build" path="build/make" remote="rk"
revision="refs/tags/android-14.0-mid-rkr1">
AOSP part
vim .repo/manifests/default.xml
<default revision="refs/tags/android-14.0.0_r11"...>
First confirm RK version of SDK according to the instruction of "How to acquire the
corresponding RK release version for current SDK". Below take RKR6 version as example to
introduce.
Use the following command to save local commit information
.repo/repo/repo manifest -r -o release_manifest_rkr1_local.xml
Note:
rockchip,uboot-charge-on: uboot power off charging is mutually exclusive with android power off
charging
rockchip,android-charge-on: android power off charging is mutually exclusive with uboot power
off charging
rockchip,uboot-low-power-voltage: configure the voltage for low battery precharging to boot, it
can be configured according to the actual requirement
rockchip,screen-on-voltage: configure the voltage for low battery precharging to light the panel, it
can be configured according to the actual requirement
u-boot/tools/images/
├── battery_0.bmp
├── battery_1.bmp
├── battery_2.bmp
├── battery_3.bmp
├── battery_4.bmp
├── battery_5.bmp
└── battery_fail.bmp
If uboot charging is enabled, but there is no charging logo displaed, maybe it is because the
picture is not packaged into resource.img. You can package per the following command:
cd u-boot
./scripts/pack_resource.sh ../kernel-6.1/resource.img
cp resource.img ../kernel/resource.img
After executing the above command, uboot charging logo will be packaged into resource.img in
kernel directory. Now need to re-package resource.img into boot.img. You can execute
./mkiamge.sh in android root directory, and then flash boot.img under rockdev/.
HDMI IN configuration
hdmi in function is disabled in SDK by default. If need to enable, operate as below:
vim device/rockchip/rk3588/BoardConfig.mk
+BOARD_HDMI_IN_SUPPORT := true
RM310 4G configuration
4G function is disabled in SDK by default. If need to enable, operate as below:
vim device/rockchip/common/BoardConfig.mk
#for rk 4g modem
-BOARD_HAS_RK_4G_MODEM ?= false
+BOARD_HAS_RK_4G_MODEM ?= true
---
a/rk3566_rgo/overlay/frameworks/base/packages/SettingsProvider/res/values/defaul
ts.xml
+++
b/rk3566_rgo/overlay/frameworks/base/packages/SettingsProvider/res/values/defaul
ts.xml
@@ -24,5 +24,5 @@
You can configure persist.wifi.sleep.delay.ms to delay closing wifi.
The default is 15 minutes, 0 means that the wifi is turned off
immediately after the screen is off. -->
- <integer name="def_wifi_sleep_policy">2</integer>
+ <integer name="def_wifi_sleep_policy">0</integer>
</resources>
vim device/rockchip/common/BoardConfig.mk
#0: ROTATION_NONE rotate 0 degree
#90: ROTATION_RIGHT rotate 90 degrees
#180: ROTATION_DOWN rotate 180 degrees
#270: ROTATION_LEFT rotate 270 degrees
# For Recovery Rotation
TARGET_RECOVERY_DEFAULT_ROTATION ?= ROTATION_NONE
to
for domestic customers: (here we take Tsinghua university mirror source as example. You can
change to other domestic mirror source)
cd device/rockchip/common
RKDocs\android\Rockchip_Introduction_Android_Power_On_Off_Animation_and_Tone_Cus
tomization_CN&EN.pdf
RKDocs\android\Rockchip_User_Guide_Dr.G_CN&EN.pdf
RK3326
PX30
RK3566
RK3568
RK3588
RK3568S
EFUSE support chipset
RK3288
RK3368
RK3399
Refer to the document for image signing and otp/efuse flashing:
RKDocs\common\security\Rockchip-Secure-Boot-Application-Note-V1.9.pdf
Enable/disable selinux
Refer to the following modification, false to disable, true to enable
device/rockchip/common$
--- a/BoardConfig.mk
+++ b/BoardConfig.mk
@@ -67,7 +67,7 @@ endif
diff --git
a/services/core/java/com/android/server/wm/ActivityTaskManagerService.java
b/services/core/java/com/android/server/wm/ActivityTaskManagerService.java
index 595c340..d4e495a 100644
---
a/services/core/java/com/android/server/wm/ActivityTaskManagerService.java
+++
b/services/core/java/com/android/server/wm/ActivityTaskManagerService.java
@@ -6555,7 +6555,7 @@ public class ActivityTaskManagerService extends
IActivityTaskManager.Stub {
} catch (RemoteException e) {
}
- if (!Build.isBuildConsistent()) {
+ if (0 && !Build.isBuildConsistent()) {
Slog.e(TAG, "Build fingerprint is not consistent, warning
user");
mUiHandler.post(() -> {
if (mShowDialogs) {
--- a/BoardConfig.mk
+++ b/BoardConfig.mk
@@ -146,3 +146,6 @@ endif
ifeq ($(strip $(BOARD_USES_AB_IMAGE)), true)
DEVICE_MANIFEST_FILE :=
device/rockchip/$(TARGET_BOARD_PLATFORM)/manifest_ab.xml
endif
+# for ethernet
+BOARD_HS_ETHERNET := true
If you want to compile Android, you also need to modify the following code
cd rk3562_Android14.0/kernel/configs
problem:
The LZ4 version of the system is too low, and the version 1.8.3 or above is required
wlq@ubuntu:~$ lz4 -v
*** LZ4 command line interface 64-bits v1.8.3, by Yann Collet ***
refusing to read from a console
solution:
copy the LZ4 compiled by Android to override the LZ4 of the system
RKDocs/android/Rockchip_Introduction_Android_Samba_CN.pdf
NFS boot
Refer to the documents and patches:
RKDocs/android/patches/customized_functions/nfs_boot_patch_v1.1.0.zip
RKDocs\android\patches\customized_functions/Android11异显开发说明.zip
RKDocs/android/patches/customized_functions/Dual_Audio_v1.0.zip
Choosing a Branch
Some requirements for the build environment are determined by the version of the source code
you plan to compile. For a full list of available branches, see Build Numbers. You can 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.
After you have selected a branch, follow the appropriate instructions below to set up your build
environment.
2. Optionally, confirm the checksums of the downloaded files against the SHA256 string listed
with each package above. For example, with the sha256sum tool:
Run dpkg for each of the .deb files you downloaded. It may produce errors due to missing
dependencies:
To fix missing dependencies:
Note: If, during a build, you encounter version errors for Java, see Wrong Java version for likely
causes and solutions.
Installing required packages (Ubuntu 14.04)
You will need a 64-bit version of Ubuntu. Ubuntu 14.04 is recommended.
sudo apt-get install git-core gnupg flex bison gperf build-essential zip curl
zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 lib32ncurses5-dev x11proto-
core-dev libx11-dev lib32z-dev ccache libgl1-mesa-dev libxml2-utils xsltproc
unzip python-pyelftools python3-pyelftools device-tree-compiler libfdt-dev
libfdt1
Note: To use SELinux tools for policy analysis, also install the python-networkx package. Note: If
you are using LDAP and want to run ART host tests, also install the libnss-sss:i386 package.
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 : http://source.android.com/source/initializing.html
It will generate the key file in your directory after the command is executed successfully.
Please keep carefully the generated private key file id_rsa and password, and send id_rsa.pub to
SDK release server admin through email.
$vim ~/.bashrc
After adding the correct private key, you can use git to clone code, shown as below picture:
ssh-add ~/.ssh/id_rsa
~$ man ssh_config
Use the following commands to configure ssh for current user.
~$ cp /etc/ssh/ssh_config ~/.ssh/config
~$ vi .ssh/config
As below picture, identify another directory ssh file ”~/.ssh1/id_rsa” as certificate private key. In
this way, you can switch different keys.
APPENDIX B-5 Key authority management
The server can real-time monitor for the specific key the download times, IP and other
information. If any abnormal case is found, it will prohibit the download authority of the
corresponding key.
Please keep carefully the private key file. DO NOT re-authorize it to the third party.
To create a new product directory for Rockchip development, you need to copy the existing directory, for example using the command 'cp -r rk3576_u rk3576_new_u'. After copying, navigate into the new directory and replace all occurrences of the old directory name with the new one using a tool like 'sed', for example: 'sed -i 's/rk3576_u/rk3576_new_u/g' *'. After these changes, the new product directory 'rk3576_new_u' is set up for further customization and development .
Dumpsys and logcat are essential tools for debugging and analyzing system performance on Rockchip platforms. Dumpsys provides comprehensive system information, allowing developers to examine service outputs and system states, which is critical for identifying performance bottlenecks and system issues. Logcat, on the other hand, captures and filters log messages, aiding in real-time analysis of system activity and application behavior, which helps quickly diagnose problems and verify system and application interactions under various conditions .
The MiniLoaderAll.bin file in the RK3576 image structure serves as the first-level loader that initializes the boot process by setting up necessary hardware and preparing the system to load subsequent boot stages. It is an integral part of the flashing image files that enables the device to begin booting .
Enabling the Generic Kernel Image (GKI) in Android 14 for Rockchip devices streamlines kernel management by using a standard, device-agnostic kernel. It affects the way kernels are compiled and bundled, as GKI requires kernel.img and resource.img to be included in boot.img rather than being separately flashed. This change supports greater modularity and consistency across devices that are GMS or EDLA certified, but necessitates careful updating and adherence to GKI specifications .
To confirm if the local SDK is updated to the latest release by RK, one needs to acquire the corresponding RK release version information and compare it with the local setup. Ensuring the SDK is up-to-date is crucial for accessing the latest features, security updates, and compatibility improvements provided by Rockchip, thereby enhancing development efficiency and device performance .
The Rockchip platform meets GMS and EDLA certification requirements in Android 14 by implementing the Generic Kernel Image (GKI), aligned with Google's mandate for kernel standardization. GKI ensures that Rockchip devices use a standardized, modular kernel, which simplifies updates and compatibility across diverse hardware configurations, thus fulfilling certification requirements while maintaining performance and security .
For the RK3576 platform, flashing images requires several steps and specific tool versions. First, ensure the USB driver is updated to DriverAssistant V5.1.1. For Windows, the firmware burning tool must be version 3.28 or above. For Linux, use the Linux Upgrade Tool version 2.30 or above. The image flashing process involves compiling the boot.img separately, if necessary, and managing partition tables such as parameter.txt to avoid incorrect flashing .
Rockchip provides tools and methods including modifying filesystem type to EXT4 for better logging and journaling capabilities, and using partitioning strategies within their provided SDK and tools. These modifications aim to optimize the read and write performance by making more efficient use of available storage hardware and reducing system overheads in data operations .
The Rockchip platform supports Dynamic System Updates (DSU) by default, which allows for over-the-air updates through Google's official DSU mechanism. However, DSU requires a considerable amount of memory, and it is not recommended for devices with DDR of 1GB or less due to potential performance constraints .
Modifying the Android system to support 64-bit only on Rockchip devices involves changing the build configuration to exclude 32-bit binaries. This can be done by setting relevant compilation flags in the build environment and ensuring that all dependencies and libraries are available in 64-bit versions. Comprehensive testing is necessary to confirm that the applications and system services operate correctly with these modifications, as this affects overall system compatibility and performance .