SPI Communication and Wi-Fi Module Issues on Axon with ESP32-S3 (Master-Slave Setup)

Hello Vicharak Team,

I’ve been trying to establish an SPI-based master-slave communication between the Axon board (Master) and an ESP32-S3 (Slave). While doing so, I’ve faced the following issues that I’d appreciate some help with.


1. SPI Interface Setup (spidev issues)

I was following the standard procedure to enable spidev on Axon (running the custom Linux image). I made the necessary changes including:

  • Overlays for SPI (spidev2.dtbo)

  • Updating U-Boot using:

    sudo u-boot-update -k Image-6.1.75-axon -r initrd.img-6.1.75-axon -d rk3588-axon-linux-6.1.75-axon.dtb -o spidev2.dtbo
    

Despite that, the SPI device /dev/spidev* was not appearing. I attempted to manually load the device:

echo spidev | sudo tee /sys/class/spi_master/spi2/device/modalias

But received:

tee: /sys/class/spi_master/spi2/device/modalias: Permission denied

Also, modprobe spidev didn’t help even though the spidev.ko module was available. This suggests a permission or overlay-related issue. I also confirmed configfs is already mounted:

sudo mount -t configfs none /sys/kernel/config
mount: /sys/kernel/config: none already mounted or mount point busy.

2. Post-reboot Wi-Fi Module Disappearance

After making the SPI-related changes and executing:

sudo reboot

The Wi-Fi module stopped working. On reboot, the system could no longer detect any wireless interfaces. lshw was not available initially, and installing it failed due to permission errors:

E: Could not open lock file /var/lib/dpkg/lock-frontend - open (13: Permission denied)

Attempting to reinstall or check firmware also didn’t help:

sudo apt download firmware-misc-nonfree

But it resulted in:

E: Unable to locate package firmware-misc-nonfree

No wireless interfaces listed

Running:

iwconfig

gave:

lo        no wireless extensions.
eth0      no wireless extensions.

Log Snippets for Reference

SPI Overlay Attempt:

P: Checking for EXTLINUX directory... found.
P: Writing config for Image-6.1.75-axon...
P: Updating /boot

After sudo reboot — Wi-Fi Gone:

No Wi-Fi module/interface visible via `iwconfig` or `ip a`

Failed lshw install:

bash: lshw: command not found
sudo apt install lshw
E: Could not open lock file /var/lib/dpkg/lock-frontend - open (13: Permission denied)

My Environment:

  • Axon board with Linux kernel 6.1.75-axon
  • ESP32-S3 connected via SPI (slave)
  • Working on SPI Master-Slave protocol for stepper motor control
  • SSH and serial access available
  • Wi-Fi previously functional before SPI config and reboot

What I Need Help With:

  1. Why isn’t spidev getting properly registered even after overlay updates?
  2. What could cause the Wi-Fi module to disappear after SPI overlay changes and reboot?
  3. How can I safely restore wireless connectivity without reflashing the whole image?
  4. Any suggestion for debugging or resetting the network interface?

Let me know if you need any more logs or output. I really appreciate your time and help.

Thanks,
Himani Netha.

Here, below Answer will solve your issues.

  1. Overlay is not enabled properly, as it was not the correct way to enable and disable for vicharak-board.

  2. We also need to look into it, what does it affect to disappearance of the Wi-Fi firmware. Could you send spio.dtbo overlays with source as well.

  3. By installing kernel and firmware, all is set to be done again.

     sudo apt update
     sudo apt install linux-image-6.1.75-axon
     sudo apt install vicharak-firmware
    
  4. For Debugging WiFi,

  • You can see Kernel Log

    dmesg | grep -i wlan
    
  • Check existence of Firmware

    ls -l /lib/firmware/rtlbt/rtl8852*
    

    Solution :

    sudo apt install vicharak-firmware