-
Establish Android build environment.
-
Make sure to run the below commands to install some dependencies
sudo apt-get install dosfstools e2fsprogs fdisk kpartx mtools rsync
sudo pip3 install meson mako jinja2 ply pyyaml dataclasses
- Initialize repo:
repo init -u https://android.googlesource.com/platform/manifest -b android-16.0.0_r3
curl -o .repo/local_manifests/manifest_rk_opi.xml -L https://raw.githubusercontent.com/dvab-sarma/android_local_manifest/android-16.0_r3/manifest_rk_opi.xml --create-dirs
Or optionally, you can reduce download size by creating a shallow clone and removing unneeded projects:
repo init -u https://android.googlesource.com/platform/manifest -b android-16.0.0_r3 --depth=1
curl -o .repo/local_manifests/manifest_rk_opi.xml -L https://raw.githubusercontent.com/dvab-sarma/android_local_manifest/android-16.0_r3/manifest_rk_opi.xml --create-dirs
curl -o .repo/local_manifests/remove_projects.xml -L https://raw.githubusercontent.com/dvab-sarma/android_local_manifest/android-16.0_r3/remove_projects.xml
- Sync source code:
repo sync -j$(nproc)
- Setup Android build environment:
. build/envsetup.sh
- Select the device (
opi5_pro) and build target (tablet UI,tvfor Android TV, orcarfor Android Automotive):
lunch aosp_opi5_pro-bp3a-userdebug
lunch aosp_opi5_pro_tv-bp3a-userdebug
lunch aosp_opi5_pro_car-bp3a-userdebug
- Compile:
make bootimage systemimage vendorimage -j$(nproc)
- Make flashable image for the device
(
opi5 series boards):
./opi5_pro-mkimg.sh
- Currently, this update (qpr1) support is only for Rockchip's rk3588 SoC, Would be releasing for rk3566 in near future. For AOSP 16 on rk3566, Please use the android-16.0 branch of this project.
Also look into Linux kernel build instructions.
The kernel version is 6.15, which is not the recommended kernel for android 15 or 16. It should work fine since most of the patches for rk3588 were upstreamed to kernel version 6.14 and the recommended kernel 6.12 for android 16 was missing the patches.
The rockchip drm was patched in this kernel attached in this github. So, it is recommended to use the kernel in this github.
- Camera doesn't work, since the mainline devicetree doesn't have the camera. Will be fixed in the future.
- 3.5 mm port doesn't work.
- Ethernet port isn't working.
- USB 3.0 doesn't work.
- Android
- Linux kernel
- You can download the android 15 / 16 prebuilt images for various boards from this google drive link. Here
- Camera drivers need to be developed for rockchip based devices.
- Audio needs to be configured properly.
Credits:
- The android userspace code is based on KonstaKang's raspberry-vanilla aosp project. A huge thanks to KonstaKang and raspberry-vanilla team.
- A huge thanks to Masayuki Araki (Misaka) for his contribution in developing and testing this build for Orange Pi 5.