Everything posted by maxsub
-
Orange Pi RV2
@sven-ola there are 3 ways to boot the R2S: 1. Press the boot button before applying power. White USB port connected to a PC. Apply power. It goes into fastboot mode like an android. Theoretically this should let you flash the on-board eMMC. I can successfully put it in fastboot mode but the flashing has not worked. 2. Boot from eMMC 3. Boot from USB. The eMMC has two boot partitions that are fixed size and one large main partition. My project uses the u-boot environment but also does a few minor things. It prioritizes USB if it finds a bootable medium there. It also safely flashes the boot blocks on the eMMC and then the main blocks. It adds some safety checks before flashing. Nothing else.
-
Orange Pi RV2
The R2S has an internal eMMC and a USB port. After debugging the default u-boot scripts I found that it does not boot from USB once you have Armbian installed on eMMC. To reinstall a fresh copy of Armbian or any other OS, you have to use the fastboot based KyTool which does not usually work on a modern Windows PC with USB 3.0 ports. So you could end up in a state where you have to manually interrupt U-boot, or worse if you corrupt the eMMC. I rewrote the u-boot flow on the R2S. I also cleaned up the nand-sata-install and added a lot of safety checks. It will look at USB and boot from there. After that you can safely install to eMMC. Below is the link. Please let me know if it is worth submitting a PR. The changes will not touch anything in the main system, it adds these scripts to /usr/local/lib and /usr/local/sbin. https://github.com/arvindmaxar/u-boot-tools
- Orange Pi RV2
- Orange Pi RV2
-
Orange Pi RV2
> apt search linux-headers linux-headers-6.19.6+deb14+1-common/testing 6.19.6-2 all Common header files for Linux 6.19.6+deb14+1 linux-headers-6.19.6+deb14+1-riscv64/testing 6.19.6-2 riscv64 Header files for Linux 6.19.6+deb14+1-riscv64 linux-headers-riscv64/testing 6.19.6-2 riscv64 Header files for Linux riscv64 configuration (meta-package) > uname -r 6.18.18-current-spacemit
- Orange Pi RV2
- Orange Pi RV2
- Orange Pi RV2
-
Orange Pi RV2
Thanks for the script @sven-ola. I got the R2S booted from USB. I had to tweak a few minor things. Where did you get the Ubuntu boot.cmd? usb start setenv devtype usb setenv devnum 0:1 setenv prefix boot/ setenv fdtfile dtb-6.6.99-legacy-spacemit/spacemit/x1_orangepi-r2s.dtb #setenv fdtfile spacemit/k1-orangepi-rv2.dtb setenv bootargs "console=ttyS0,115200 root=/dev/sda1" ls ${devtype} ${devnum} ${prefix} load ${devtype} ${devnum} ${ramdisk_addr_r} ${prefix}uInitrd load ${devtype} ${devnum} ${kernel_addr_r} ${prefix}Image load ${devtype} ${devnum} ${fdt_addr_r} ${prefix}/${fdtfile} booti ${kernel_addr_r} ${ramdisk_addr_r} ${fdt_addr_r}
- Orange Pi RV2
- Orange Pi RV2
- Orange Pi RV2
- Orange Pi RV2
-
Orange Pi RV2
I setup a fresh install on the RV2 using the pre-built Forky binary. Everything works stably but the idle load average is very high all the time: armbian@orangepirv2:~$ uptime 09:22:27 up 13:30, 1 user, load average: 2.00, 2.00, 2.00 Looks like the bug that cause the kernel to spin is still there.
- Orange Pi RV2
-
Orange Pi RV2
Thanks @sven-ola! You have been of amazing support here. My worry about using the closed source binary firmware is that it opens up a security hole (no patches for vulnerabilities, etc). Same for OpenWrt - the xunlong code is a fork from OpenWrt and not being updated as far as I can tell. That's why I went the Armbian route, with your code in mainstream, it will get continuously updated. The WiFi is definitely underpowered, and CPU overpowered. I am using an R2S with a USB Wireless adapter (realtek): Panda wireless PAU0B. However, the 6.6 kernel seems to not allow AP mode.
- Orange Pi RV2
- Orange Pi RV2
- Orange Pi RV2
- Orange Pi RV2
-
Orange Pi RV2
I started a build of mesa-spacemit-kt from source on the RV2 and ran into only a couple of issues: ../src/amd/llvm/ac_llvm_helper.cpp:102:10: error: no matching function for call to โunwrap(LLVMOpaqueModule*&)โ 102 | unwrap(module)->setTargetTriple(TM->getTargetTriple().getTriple()); | ~~~~~~^~~~~~~~ In file included from /usr/include/llvm-19/llvm/IR/Type.h:18, from /usr/include/llvm-19/llvm/IR/DerivedTypes.h:23, from /usr/include/llvm-19/llvm/IR/InstrTypes.h:26, from /usr/include/llvm-19/llvm/Analysis/TargetLibraryInfo.h:14, from ../src/amd/llvm/ac_llvm_helper.cpp:8:
- Orange Pi RV2
-
Orange Pi RV2
The bcmdhd dkms is getting built and the debs are being updated if I use SKIP_ARMBIAN_REPO=yes. [๐ณ|๐จ] Building for 6.18.9-edge-spacemit [๐ณ|๐จ] [๐ณ|๐จ] Building initial module bcmdhd-spacemit-sdio/101.10.591.84.37-4 for 6.18.9-edge-spacemit [๐ณ|๐จ] The kernel is built without module signing facility, modules won't be signed [๐ณ|๐จ] [๐ณ|๐จ] Building module(s)............................... done. [๐ณ|๐จ] Installing /lib/modules/6.18.9-edge-spacemit/updates/dkms/bcmdhd.ko.xz [๐ณ|๐จ] Installing /lib/modules/6.18.9-edge-spacemit/updates/dkms/dhd_static_buf.ko.xz [๐ณ|๐จ] Running depmod.... done. [๐ณ|๐จ] Processing triggers for man-db (2.13.1-1) ... When installing the image deb the previous dkms gets deleted. Preparing to unpack linux-image-edge-spacemit_26.02.0-trunk_riscv64__6.18.9-S3aec-D0000-P87b2-C50afHfe35-HK01ba-Vc222-B052a-R448a.deb ... Armbian 'linux-image-edge-spacemit' for '6.18.9-edge-spacemit': 'prerm' starting. dkms: removing module bcmdhd-spacemit-sdio/101.10.591.84.37-4 for kernel 6.18.9-edge-spacemit (riscv64) Module bcmdhd-spacemit-sdio/101.10.591.84.37-4 for kernel 6.18.9-edge-spacemit (riscv64): Before uninstall, this module version was ACTIVE on this kernel. Deleting /lib/modules/6.18.9-edge-spacemit/updates/dkms/bcmdhd.ko.xz Deleting /lib/modules/6.18.9-edge-spacemit/updates/dkms/dhd_static_buf.ko.xz ......... It gets built during install of the image deb: Autoinstall of module bcmdhd-spacemit-sdio/101.10.591.84.37-4 for kernel 6.18.9-edge-spacemit (riscv64) Building module(s).............................................. Installing /lib/modules/6.18.9-edge-spacemit/updates/dkms/bcmdhd.ko.xz Installing /lib/modules/6.18.9-edge-spacemit/updates/dkms/dhd_static_buf.ko.xz Running depmod.....
- Orange Pi RV2
-
Orange Pi RV2
Got it! But this DKMS should be loaded by the build: function post_family_tweaks_bsp__orangepirv2_wifi() { display_alert "$BOARD" "Force load bmcdhd wireless" "info" run_host_command_logged mkdir -pv "${destination}"/etc/modules-load.d run_host_command_logged echo "bcmdhd" > "${destination}"/etc/modules-load.d/${BOARD}.conf }