BPI-R2 Pro Compiling debian image

i tried to build debian image from github repo,but get no sdcard image,did i something wrong?

Started build.sh,used option to build debian (afair 4)

ls rockdev/
boot.img           misc.img       recovery.img  rootfs.img  update.img
MiniLoaderAll.bin  parameter.txt  rootfs.ext4   uboot.img

seems i miss something:

./build.sh sdpackage
processing option: sdpackage
Skipping build_sdcard_package for missing configs:  RK_UPDATE_SDCARD_ENABLE_FOR_AB.

Update-EMMC-Tools.zip.001 (300 KB) Update-EMMC-Tools.zip.002 (300 KB) Update-EMMC-Tools.zip.003 (300 KB) Update-EMMC-Tools.zip.004 (300 KB) Update-EMMC-Tools.zip.005 (300 KB) Update-EMMC-Tools.zip.006 (300 KB) Update-EMMC-Tools.zip.007 (300 KB) Update-EMMC-Tools.zip.008 (300 KB) Update-EMMC-Tools.zip.009 (23.9 KB) Update-SD-Tools.zip.001 (300 KB) Update-SD-Tools.zip.002 (173.9 KB) hi frank-w,

you compile the BSP successfully, the path include all images.

  1. “MiniLoaderAll.bin uboot.img boot.img misc.img recovery.img rootfs.img parameter.txt”, these images file is for EMMC boot, please use the attachment emmc update tools, flash them into EMMC.
  2. “update.img”, it is for SD boot, please use the attachment SD update tools, flash them into SD CardEMMC-Update SD-Update .

Firstly you need instal the attachment USB driver for EMMC update Update the R2PRO’s EMMC , you must onnect miniUSB convert USB calble between PC omputer and R2PRO, push down SW1 key of R2PRO board, then power up, then R2PRO will enter MASKROM mode, on EMMC Update tools’s UI, you can see one device, then you will execute the run button to update.DriverAssitant_v5.1.1.zip.001 (300 KB) DriverAssitant_v5.1.1.zip.002 (300 KB) 上传中:DriverAssitant_v5.1.1.zip.003… DriverAssitant_v5.1.1.zip.004 (300 KB) DriverAssitant_v5.1.1.zip.005 (300 KB) DriverAssitant_v5.1.1.zip.006 (300 KB) DriverAssitant_v5.1.1.zip.007 (300 KB) DriverAssitant_v5.1.1.zip.008 (300 KB) DriverAssitant_v5.1.1.zip.009 (300 KB) DriverAssitant_v5.1.1.zip.010 (300 KB) DriverAssitant_v5.1.1.zip.011 (300 KB) DriverAssitant_v5.1.1.zip.012 (300 KB) DriverAssitant_v5.1.1.zip.013 (300 KB) DriverAssitant_v5.1.1.zip.014 (300 KB) 上传中:DriverAssitant_v5.1.1.zip.015… DriverAssitant_v5.1.1.zip.016 (300 KB) 上传中:DriverAssitant_v5.1.1.zip.017… DriverAssitant_v5.1.1.zip.018 (300 KB) DriverAssitant_v5.1.1.zip.019 (300 KB) DriverAssitant_v5.1.1.zip.020 (300 KB) DriverAssitant_v5.1.1.zip.021 (300 KB) DriverAssitant_v5.1.1.zip.022 (300 KB) DriverAssitant_v5.1.1.zip.024 (300 KB) DriverAssitant_v5.1.1.zip.025 (300 KB) DriverAssitant_v5.1.1.zip.026 (300 KB) 上传中:DriverAssitant_v5.1.1.zip.027… DriverAssitant_v5.1.1.zip.028 (300 KB) DriverAssitant_v5.1.1.zip.029 (300 KB) DriverAssitant_v5.1.1.zip.030 (300 KB) DriverAssitant_v5.1.1.zip.031 (300 KB) DriverAssitant_v5.1.1.zip.032 (283.2 KB)

can the sd-card/emmc only created by this (windows-) application? no dd in linux?

which part is update.img for sdcard of the blocks (i guess replace boot.img, if i unserstand you correctly)?

basicly i see in first screenshot adresses, can you show how sdcard looks like? i guess miniloaderall.img, (boot.img,) uboot.img and rootfs.img are same.

Because Silicon Vendor Rockchip implement the built package process, the package tools and some loader sourcecode don’t supply. So we never know that the final image’s format. Update.img is for SD boot, it’s one vendor special package format. So you only use the vendor tools to flash SD card.

Manjaro builds image for quartzt64 rk3566 without vendor tools


But have not found yet where bootheaders (idblock.bin,uboot/fip) are written.

On first try i setup windows vm and create sdimage with the tools and then maybe look for the binary-signatures.but newer kernel is priority

We got rockchip target in OpenWrt and do build ARM Trusted Firmware and U-Boot from source for that target. No proprietary tools involved what-so-ever. See images for NanoPi R2S (RK3328) and NanoPi R4S (RK3399).

do you have rk356x target too (e.g. quartz64)?

can you point me to script where image is created with which files (uboot.bin/fip,…idblock.bin), partition create,…?

have got sdcard in windows-VM working, but sdcard-tool does not find it because it is mapped by virtualbox as harddrive (non-removable), so I’m currently not able to create sdcard as my host system is linux

No, only up to Rk3399 in OpenWrt for now, but I suppose it’s similar? Rk3568 is also present in vanilla U-Boot by now, but Rk356x is still missing in TF-A sources:

right, TF-A source is missing, but there are binaries which can be used for building fip

i’m not sure i’m doing right, but i added process to my build.sh (special tree), needs patch to rockchip-atf-python-script too

i have a createimg-target too (which i had copied from manjaro):

both untested as i have no board yet, but i get one soon :wink: - image works and mainline uboot gets loaded,but cannot load linux kernel yet

  • debug-uart-settings: 1500000 8N1 (ch340g,ft323,cp2104 needed)
  • did not see a boot-switch (to choice between emmc/sdcard)

edit: i managed to get usb-cardreader working in windows-vm and selectable in sdcard-tool, but it stops at “clear MBR failed”, it looks like device is blocked in linux when using in virtualbox…i cannot access it from linux and write failes in windows, found my internal reader too, but sometimes it is hidden…strange, but got same error with internal reader

Edit2: got bpi kernel booted to compare settings with my kernel

Edit3: mainline uboot working now :slight_smile: