BPI-R4 SIM1 not detected with modem Quectel in M.2 slot

I purchased 20 BPI-R4 units, all equipped with Quectel EM05-G modems. Our goal is to build a custom SDN using WireGuard tunnels and FRR routing to failover or load-balance between the WAN and the cellular network.

We are running OpenWrt version 24.5, with the modems installed in the M.2 slot linked to SIM 1. However, 6 out of 20 of the BPI-R4 units are failing to detect the SIM card. I have performed all standard troubleshooting steps but cannot identify why these specific units are failing.

Here is the output of mmcli -m 0 from one of the failing units:

On the BPI-R4 the SIM1 Led is ON.

Here is my modem initialisation.

Basic Config

AT+QSIMDET=0,0
AT+QCFG=“fcc_enable”,0
AT+QCFG=“usbnet”,0
AT+CFUN=1,1

Here all my modem test.

1- Verification of voltage (Must be above 3400 3.4 Volt)

AT+CBC  

+CBC: 0,15,3598 

2- SIM check

AT+QUIMSLOT? 

ERROR 

3- Check Phone Functionality

AT+CFUN? 

+CFUN: 1 

4- Check USB protocol

AT+QCFG="usbnet" 

+QCFG: "usbnet",0  

All modem have the same firmware version

Thank You for any help you can provide!

I’m no expert, but have you tried swapping sim cards with one that worked? Are all sim cards activated with your carrier?

Yes, I always test with both a ‘test’ SIM and a ‘production’ SIM, and neither are being detected. As I mentioned, I’m only seeing this issue on 6 out of the 20 BPI-R4 boards; the other 14 are working perfectly.

Thank You

Maybe detail check/compare the pin contacts of the SIM slot. This slot could be damaged by inserting an empty SIM tray and the (too) forcefully removing it. This may has happend to the boards with non working SIM slots.

I figured out the issue with the six BPI-R4 units that weren’t detecting the SIM card in the M.2 slot. It turns out the modem was the issue.

I will try to upgrade the modem firmware.

Thank you

1 Like

SIM detection polarity. The contact in SIM holder is opposite to what is given in schematic (open vs close when card inserted). Usually there is some command QCFG or similar by which either polarity can be switch or the detection by the contact switch can be fully disabled. We did a first try by isolating the detection pin in M.2 connectore but this has some risk as well. There are other threads in this forum dealing with SIM detection.

See your QSIMDET above. If still no improvement, stop ModemManager and try by terminalprogramm to have more control, maybe MM interacts as part of its initialization? ttyUSB0 may not be the AT port? if other info can come from USB enumeration?