9. Wireless support¶
JAGUAR SBC-RK3588-AMR features an M.2 Key-E socket (Fig. 2.1 Jaguar interfaces overview) which can be used for adding WiFi and Bluetooth support. This chapter shows how to connect to an existing WiFi network and how to scan Bluetooth devices.
9.1. Recommended adapter¶
CHERRY Embedded Solutions recommends using an Intel Wireless-AC 9260 WiFi 5/Bluetooth 5.1 module. If a different adapter is used, this section can be skipped.
This adapter requires non-free firmware though so the following needs to be done on Debian:
echo deb http://deb.debian.org/debian/ bookworm main non-free-firmware \
> /etc/apt/sources.list.d/non-free-firmware.list
apt-get update
apt-get install firmware-iwlwifi
reboot
Note
In Yocto, linux-firmware-ibt-18
and linux-firmware-iwlwifi-9260
packages
should be installed. They are installed by default in our cherry-es-extended-image
image.
Additionally, make sure the following Kconfig symbols are set in the kernel defconfig (they are already set this way in the default defconfig):
CONFIG_IWLWIFI=m
CONFIG_IWLDVM=m
CONFIG_IWLMVM=m
CONFIG_BT_HCIBTUSB=m
so that the drivers are built as modules. Finally, ensure that the following files exist in your root file system:
$ ls -1 /lib/modules/*/kernel/drivers/net/wireless/intel/iwlwifi/{dvm/,mvm/,}*.ko
/lib/modules/5.10.160-g13643c184ca4/kernel/drivers/net/wireless/intel/iwlwifi/dvm/iwldvm.ko
/lib/modules/5.10.160-g13643c184ca4/kernel/drivers/net/wireless/intel/iwlwifi/iwlwifi.ko
/lib/modules/5.10.160-g13643c184ca4/kernel/drivers/net/wireless/intel/iwlwifi/mvm/iwlmvm.ko
$ ls -1 /lib/modules/*/kernel/drivers/bluetooth/btusb.ko
/lib/modules/5.10.160-g13643c184ca4/kernel/drivers/bluetooth/btusb.ko
The name of the directory in /lib/modules
should match exactly the one
returned by:
$ uname --kernel-release
5.10.160-g13643c184ca4
Note
To install the kernel driver modules into the rootfs on Debian, compile the
kernel following the instructions from Section 5.4 Compile the Linux kernel
and either copy the files to the running system with the rsync
command
listed in that section and reboot or regenerate a debos image following
instructions from Section 5.5 Building the debos image.
If everything went well, a wlan0
device should appear when executing:
ip address show wlan0
9.2. Installing software dependencies¶
apt-get install network-manager wpasupplicant bluez
# Disable systemd-networkd and systemd-resolved to let NetworkManager handle everything
systemctl disable --now systemd-networkd
systemctl disable --now systemd-resolved
systemctl enable --now NetworkManager
9.3. Connecting to a Wifi network¶
You can show the available wifi networks using:
nmcli dev wifi
Connect to a network using the following command (replace the network name and password as appropriate):
nmcli dev wifi connect "CHERRY Example Wifi" password "hello-jaguar"
You should get a message like:
Device 'wlan0' successfully activated with '79ef39fc-8f49-4719-a8d9-4d6d789bb815'.
You should have connectivity over Wifi now. You can check the IP address you received using:
ip address show dev wlan0
Note
By default, nmcli
is not available in our Yocto core-image-minimal
image. However, it is
available in our Yocto cherry-es-extended-image
image.
9.4. Scanning Bluetooth devices¶
First set the HCI device up:
hciconfig hci0 up
Then scan devices:
hcitool scan