Does someone experiments this board on M5 with the last ARMBIAN binary. It seems that the dts for wifi port description is not present. The wlan does’nt appear in ifconfig.
You talking about the add-on M5 specific wifi/bluetooth adapter? I got it working and posted about how to do it a few minutes ago.
here’s the summary of the other post:
modify /boot/boot.ini by modifying the following line (typically line 96) and add the wifi_bt_rtl8822cs driver overlay:
setenv overlays "i2c0 spi0 uart1 wifi_bt_rtl8822cs"
update /etc/modules to load driver at boot:
sudo echo “88x2cs” >> /etc/modules-load.d/modules.conf
load driver immediately without need for reboot:
modprobe 88x2cs
Mark,
thanks for your post, I did’nt got issue to start WIFI on M5 with the BANANA PI distro available on there site, I did like you describe. The problem I experiments is the stability of wifi driver which disconnects randomly all station. So I try with the last build on the ARMBIAN site. the last version 6.1.x boot fine but unfortunatly on these builds the DTB does not describe the wifi RTL8822 board and the overlay is not there. On top the structure of the DTB change on ARMBIAN version so the overlay for the board available on old banana distro is incompatible. The M2 PRO with the wifi on board works perfectly with the last ARMBIAN distro. Gerard
Igor
I download the last build :
Armbian_23.02.2_Bananapim5_bullseye_current_6.1.11_minimal.img
Has you can see in the README.meson-overlays file there is no trace of the rtl8822 board overlay :
This document describes overlays provided in the kernel packages For generic Armbian overlays documentation please see https://docs.armbian.com/User-Guide_Allwinner_overlays/
Platform:
meson (Amlogic)
Provided overlays:
- i2c8
Overlay details:
i2c8
Activates TWI/I2C bus 8
I2C8 pins (SCL, SDA): GPIO1-C4, GPIO1-C5
and there are no file about this board in the directory :
gerard@pc-gerard:/media/gerard/armbi_root/boot/dtb-6.1.11-meson64/amlogic/overlay$ ls -l total 36 -rwxr-xr-x 1 root root 232 févr. 18 01:07 meson-fixup.scr
-rwxr-xr-x 1 root root 377 févr. 18 01:07 meson-g12-gxl-cma-pool-896MB.dtbo
-rwxr-xr-x 1 root root 343 févr. 18 01:07 meson-i2cA.dtbo
-rwxr-xr-x 1 root root 343 févr. 18 01:07 meson-i2cB.dtbo
-rwxr-xr-x 1 root root 238 févr. 18 01:07 meson-uartA.dtbo
-rwxr-xr-x 1 root root 238 févr. 18 01:07 meson-uartC.dtbo
-rwxr-xr-x 1 root root 759 févr. 18 01:07 meson-w1AB-gpio.dtbo
-rwxr-xr-x 1 root root 490 févr. 18 01:07 meson-w1-gpio.dtbo
-rwxr-xr-x 1 root root 339 févr. 18 01:07 README.meson-overlays
gerard@pc-gerard:/media/gerard/armbi_root/boot/dtb-6.1.11-meson64/amlogic/overlay$
so except if the device description is in the board dtb (difficult to see) or if I did’nt understand something , I don’t see how the boot could load the device description.
Did you boot this version on an M5 with tis board ?
regards
Gerard
Mark
I know quite well the procedure (you give) to declare the board and use it for the old version of armbian (the one available on the BANANA-PI site and it works , but the driver or the OS are buggy and the driver drops all the station randomly and is not reliable. It’s why I try the last release on the ARMBIAN 23.02.2. On this distrib the boot sequence change and there are no more overlay for the wifi board.
regards Gerard
Its not overlay, but different DT file
add this to /boot/armbianEnv.txt
fdtfile=amlogic/meson-sm1-bananapi-m2-pro.dtb
thanks
I will test that next week. does that means that “fdtfile=amlogic/meson-sm1-bananapi-m2-pro.dtb” is missing in /boot/armbianEnv.txt ? and why to boot M5 with M2-pro dtb file ?
Gérard
It seems like anything past the ancient 4.9 kernel goes bonkers and it’s one of the reasons I replaced the m5 with a genuine rpi. the initial cost savings has not and is not worth the headache of this little board that “could have…”. My wifi dongle drops in and out on 5.x kernels on this thing too. Frustrating…
Sidenote: How did you even get that image to boot though? I’ve been unsuccessful 10 times trying to get any of those to even boot.
You can get the file on https://www.armbian.com/bananapi-m5/ and linux boots fine on M5 but does’nt recognize the 8822cs board. I will test next week the propose setup of Igor.
Gerard
I might overlook this. You have M5 with wifi on board? That is something different and might not work OOB if wired in some different way that M2 Pro … anyway, worth trying.
https://wiki.banana-pi.org/Banana_Pi_BPI-M5#Armbian try this 2023-01-31 relase images, the driver seems not stable, but works.
you shoud add rtl8822cs to overlay in /boot/armbianEnv.txt, default is not enable.
@igor the rtl8822cs board is connected on the gpio connector and works with the sdio protocol. Gerard
I confirm that 8822cs wifi external board on gpio connector is not recognized by
Armbian_23.02.2_Bananapim5_bullseye_current_6.1.11_minimal.img with
explicit
fdtfile=amlogic/meson-sm1-bananapi-m2-pro.dtb or
fdtfile=amlogic/meson-sm1-bananapi-m5.dtb
in armbianEnv.txt.
Both boots fine.
Gerard
official armbian only support the bananapi m2pro onboard 8821cu or 8821cu usb dongle, not support 40pin 8822cs external board.
The upstream Linux 6.2.y kernel supports RTL8822CS in the rtw88 driver and the mezzanine has been tested (working fine) with M5 and M2S boards. Older Linux kernels require the vendor driver or a pile of rtw88 patches need backporting. The following patch prepares support for the mezzanine board. You only need to enable the sd_emmc_a
and uart_a
nodes through an overlay or fdtput.
From a custom Linux image (not Armbian) - dmesg: http://ix.io/4qpF
I download “Welcome to Armbian 23.02.2 Bullseye with Linux 6.1.11-meson64” on M5 with optional RTL8822CS WiFi/BT mezzanine board.
I add “overlays=uartA” in /boot/armbianEnv.txt there is no dtb file for sd_mmc_a in overlay directory (see list in my previous post) I add the module 88x2cs in /etc/modules. I reboot and the wifi interface is not there in ifconfig.
Does some one sees this config working with this software and if yes how to configure it ? thanks for your help. Gerard
I can attest I got my wifi working by using Armbian on the latest kernel, finally, instead of getting stuck with Sinovoip’s 4.9. I use the patch by @chewitt. To avoid any confusion, this is the wifi module.
You need to compile it yourself. Clone the build repo.
git clone --depth=1 --branch=main https://github.com/armbian/build
cd build
The step is as below. Mine is using the current minimal Bookworm. You can change it accordingly.
./compile.sh CREATE_PATCHES=yes KERNEL_GIT=full BOARD=bananapim5 BRANCH=current RELEASE=bookworm BUILD_MINIMAL=yes BUILD_DESKTOP=no KERNEL_CONFIGURE=yes COMPRESS_OUTPUTIMAGE=sha,img
Or you can use use the UI:
./compile.sh CREATE_PATCHES=yes
At some point, you’ll be prompted to make changes to your code in a directory for patching. Find meson-sm1-bananapi-m5.dts
and replace (all) the code with the one provided by @chewitt.
vi cache/sources/linux-kernel-worktree/6.1__meson64__arm64/arch/arm64/boot/dts/amlogic/meson-sm1-bananapi-m5.dts
Armbian will create a copy of the patch in output/patch
directory.
Once compiled boot into it. Then use fdtput
to make change to kernel tree. I got this from libreElec.wiki.
fdtput -t s /boot/dtb-6.x.x.xx-meson24/amlogic/meson-sm1-bananapi-m5.dtb /soc/sd@ffe03000 status okay
fdtput -t s /boot/dtb-6.x.x.xx-meson24/amlogic/meson-sm1-bananapi-m5.dtb /soc/bus@ffd00000/serial@24000 status okay
Then modify your modules.conf
:
vi /etc/modules-load.d/modules.conf
# append the following line to the end of modules.conf:
88x2cs
Reboot. If everything goes accordingly, your wifi should be up and running. @igorpec Is there’s any possibility to get the patch into the release distribution?
Regards.
EDIT: Apparently if you do system upgrade, your patched kernel can be overwritten. Thus, you need to freeze the kernel.
Thanks a lot for your answer. After some investigations I found the file of CHEWIT and I try to compile and put the patch at the right time during the build of the minimal build with your command. Unfortunatly, after two hours of build the process failed with this message :
[] Kernel image filetype after pre_package_kernel_image [ vmlinuz-6.1.25-meson64: Linux kernel ARM64 boot executable Image, little-endian, 4K pages ]
[] removed ‘/home/gerard/build/.tmp/work-5cca76d8-90d8-4071-aeae-44a2473d4702/tmp.2ItP6wUFC2/lib/modules/6.1.25-meson64/build’
[] removed ‘/home/gerard/build/.tmp/work-5cca76d8-90d8-4071-aeae-44a2473d4702/tmp.2ItP6wUFC2/lib/modules/6.1.25-meson64/source’
[] [6.6K] /home/gerard/build/.tmp/work-5cca76d8-90d8-4071-aeae-44a2473d4702/tmp.2ItP6wUFC2/lib/modules/6.1.25-meson64/kernel
[] ├── [ 60] arch
[] ├── [1.2K] crypto
[] ├── [1.7K] drivers
[] ├── [1.1K] fs
[] ├── [ 200] kernel
[] ├── [ 920] lib
[] ├── [1.0K] net
[] └── [ 280] sound
[]
[] 6.6K used in 8 directories
/home/gerard/build/lib/functions/compilation/kernel-debs.sh: command substitution: line 265: syntax error near unexpected token `then’
[] Exiting with error 2 [ at /home/gerard/build/lib/functions/compilation/kernel-debs.sh:1
kernel_package_callback_linux_image() --> lib/functions/compilation/kernel-debs.sh:1
create_kernel_deb() --> lib/functions/compilation/kernel-debs.sh:123
prepare_kernel_packaging_debs() --> lib/functions/compilation/kernel-debs.sh:72
kernel_package() --> lib/functions/compilation/kernel.sh:164
do_with_hooks() --> lib/functions/general/extensions.sh:548
do_with_logging() --> lib/functions/logging/section-logging.sh:81
kernel_prepare_build_and_package() --> lib/functions/compilation/kernel.sh:138
compile_kernel() --> lib/functions/compilation/kernel.sh:73
artifact_kernel_build_from_sources() --> lib/functions/artifacts/artifact-kernel.sh:203
artifact_build_from_sources() --> lib/functions/artifacts/artifacts-obtain.sh:34
obtain_complete_artifact() --> lib/functions/artifacts/artifacts-obtain.sh:227
build_artifact_for_image() --> lib/functions/artifacts/artifacts-obtain.sh:276
main_default_build_packages() --> lib/functions/main/build-packages.sh:97
full_build_packages_rootfs_and_image() --> lib/functions/main/default-build.sh:19
do_with_default_build() --> lib/functions/main/default-build.sh:30
cli_standard_build_run() --> lib/functions/cli/cli-build.sh:29
armbian_cli_run_command() --> lib/functions/cli/utils-cli.sh:136
cli_entrypoint() --> lib/functions/cli/entrypoint.sh:176
main() --> compile.sh:50
]
[] Cleaning up [ please wait for cleanups to finish ]
[] ANSI log file built; inspect it by running: [ less -RS output/logs/log-build-5cca76d8-90d8-4071-aeae-44a2473d4702.log.ans ]
I did’nt change any parameter in the build configuration and a copy of your command.
Any idea of this issue ?
Gerard