I'm seeking help with a device tree issue I'm facing on the Raspberry Pi 5.

Goal: My objective is to connect an external 1.8V SDIO WiFi card to a Raspberry Pi using the built-in microSD card slot (the TF card slot). I'm using the card slot because the 40-pin GPIO header only supports 3.3V logic.

Successful working setup: Raspberry Pi 4

I have a setup that works perfectly on my Raspberry Pi 4.

Result: The SDIO WiFi card enumerates correctly

Device Tree Overlay: I'm using a custom overlay file named

emmc_wifi_rpi4.dts.

/dts-v1/;
/plugin/;
/ {
 compatible = "brcm,bcm2711";
 fragment@0 {
 target = <&emmc2>;
 __overlay__ {
 status = "disabled";
 };
 };
 fragment@1 {
 target = <&soc>;
 __overlay__ {
 mmc@7e340000 {
 compatible = "brcm,bcm2835-sdhci";
 reg = <0x7e340000 0x100>;
 interrupts = <0x00 0x7e 0x04>;
 clocks = <&clocks 0x33>;
 pinctrl-names = "default";
 pinctrl-0 = <&emmc_gpio48>;
 bus-width = <4>;
 status = "okay";
 #address-cells = <1>;
 #size-cells = <0>;
 dma-names = "rx-tx";
 dmas = <&dma 11>;
 brcm,overclock-50 = <0>;
 sd-uhs-sdr104;
 };
 };
 };
};

Failing setup: Raspberry Pi 5

When I try to replicate this on a Raspberry Pi 5, the setup fails.

Result: the SDIO WiFi card is not detected and fails to enumerate

Device Tree Overlay: I created a new overlay for this, named

emmc2-wifi_rpi5.dts.

/dts-v1/;
/plugin/;
/ {
 compatible = "brcm,bcm2712";
 fragment@0 {
 target = <&sdio1>;
 __overlay__ {
 status = "disabled";
 };
 };
 fragment@1 {
 target = <&soc>;
 __overlay__ {
 mmc@fff000 {
 compatible = "brcm,bcm2712-sdhci";
 reg-names = "host0円cfg";
 reg = <0xfff000 0x260 0xfff400 0x200>;
 interrupts = <0x00 0x111 0x04>;
 clocks = <0x08>;
 pinctrl-names = "default";
 pinctrl-0 = <0x09 0x0a>;
 vqmmc-supply = <0x0b>;
 bus-width = <0x04>;
 status = "okay";
 #address-cells = <1>;
 #size-cells = <0>;
 sd-uhs-sdr104;
 cd-gpios = <0x0d 0x05 0x01>;
 supports-cqe = <0x01>;
 };
 };
 };
};

Logic Analyzer Findings

I've also done some debugging with a logic analyzer, which revealed a key difference:

On the Raspberry Pi 4, I can see the host send CMD5 (IO_SEND_OP_COND), and the SDIO wifi provides a valid response.

On the Raspberry Pi 5, the host sends CMD5, but there is 1no response1 from the sdio wifi at all.

This lack of response to CMD5 on the Pi 5 seems to be the core of the enumeration failure and likely points to an issue with the electrical interface (e.g., power/voltage).

My Question

Could anyone help me understand what might be causing the enumeration to fail on the Raspberry Pi 5?

I suspect there are significant architectural differences between the Pi 4 (BCM2711) and Pi 5 (BCM2712/RP1), especially regarding how the device tree handles pinctrl, clocks, or power supplies (vqmmc-supply), but I'm not sure what specific changes are needed in my overlay.

I'm happy to provide the contents of all four DTS files if that would help with debugging.

Thank you in advance!

1 Reply 1

I carefully checked the logic analyzer again, and the LA of Raspberry Pi 4 is as follows:

Raspberry Pi 4

The logic analyzer of Raspberry Pi 5 is as follows:

Raspberry Pi 5

Waveform analysis
Raspberry Pi 4
CLK (pink) idle state: low level
Only generate pulses during transmission

Raspberry Pi 5
CLK (pink) idle state: high level
This is clock polarity reversal

May I ask why the above phenomenon occurs? After that, the Raspberry Pi 4 is normally enumerated, while the Raspberry Pi 5 is not。

Your Reply

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Reply", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.