Cannot Establish Data Connection with Quectel EC25-A

I am not able to establish a working LTE connection using the Cellular Modem Kit with Quectel EC25-A in Toronto, ON.

The module is attached to a Raspberry Pi 3B and connected using the right-angle USB cable that is included in the kit. The Base Hat powers on and the modem is detected in Raspberry Pi OS (seeing wwan0 interface and lsusb is listing “Quectel Wireless Solutions Co., Ltd. EC25 LTE modem”), but when I execute quectel-CM -s ltemobile.apn it fails and exits.

pi@ELANTRA:~ $ sudo ./files/quectel-CM/quectel-CM -s ltemobile.apn [06-13_20:35:36:701] Quectel_QConnectManager_Linux_V1.6.0.12 [06-13_20:35:36:705] Find /sys/bus/usb/devices/1-1.2 idVendor=0x2c7c idProduct=0x125, bus=0x001, dev=0x004
[06-13_20:35:36:706] Auto find qmichannel = /dev/cdc-wdm0 [06-13_20:35:36:706] Auto find usbnet_adapter = wwan0 [06-13_20:35:36:707] netcard driver = qmi_wwan, driver version = 5.10.17-v8+ [06-13_20:35:36:708] ioctl(0x89f3, qmap_settings) failed: Operation not supported, rc=-1 [06-13_20:35:36:710] Modem works in QMI mode [06-13_20:35:36:733] /proc/1169/fd/7 → /dev/cdc-wdm0 [06-13_20:35:36:734] /proc/1169/exe → /home/pi/files/quectel-CM/quectel-CM [06-13_20:35:38:740] cdc_wdm_fd = 7 [06-13_20:35:38:843] Get clientWDS = 4 [06-13_20:35:38:877] Get clientDMS = 1 [06-13_20:35:38:910] Get clientNAS = 4 [06-13_20:35:38:945] Get clientUIM = 1 [06-13_20:35:38:979] Get clientWDA = 1 [06-13_20:35:39:013] requestBaseBandVersion EC25EFAR06A11M4G [06-13_20:35:39:149] requestGetSIMStatus SIMStatus: SIM_READY [06-13_20:35:39:149] requestSetProfile[1] ltemobile.apn///0 [06-13_20:35:39:217] requestGetProfile[1] ltemobile.apn///0 [06-13_20:35:39:252] requestRegistrationState2 MCC: 0, MNC: 0, PS: Detached, DataCap: UNKNOW [06-13_20:35:39:285] requestQueryDataCall IPv4ConnectionStatus: DISCONNECTED [06-13_20:35:39:285] ifconfig wwan0 down [06-13_20:35:39:305] ifconfig wwan0 0.0.0.0 [06-13_20:35:48:159] QmiWwanThread exit [06-13_20:35:48:160] qmi_main exit

I am using a working SIM (tested in my phone). Querying the modem in minicom with the command AT+QCFG=“usbnet” returns 0. Also, executing sudo qmicli -d /dev/cdc-wdm0 --dms-get-operating-mode returns the error:

[/dev/cdc-wdm0] Operating mode retrieved: Mode: ‘offline’ Reason: ‘unknown’ HW restricted: ‘no’

Running sudo qmicli -d /dev/cdc-wdm0 --dms-set-operating-mode=‘online’ fails as:

error: couldn’t set operating mode: QMI protocol error (52): ‘DeviceNotReady’

Is my unit defective? Has anyone experienced similar issues?

1 Like

Hello,

Please share the output of the following AT commands.
AT+CPIN?
AT+QGMR
AT+CPAS
AT+CFUN?
AT+COPS?
AT+QCFG=“band”
AT+QCFG=“nwscanseq”
AT+QCFG=“nwscanmode”
AT+CGDCONT?
AT+CREG?
AT+CSQ
AT+QCSQ
AT+QNWINFO
AT+CGATT?
AT+QCFG=“usbnet”

Thank you for responding, @saeed.

AT+CPIN?
+CPIN: READY
OK

AT+QGMR
EC25EFAR06A11M4G_01.001.01.001
OK

AT+CPAS
+CPAS: 0
OK

AT+CFUN?
+CFUN: 7
OK

AT+COPS?
+COPS: 0
OK

AT+QCFG=“band”
+QCFG: “band”,0x260,0x80a,0x0
OK

AT+QCFG=“nwscanseq”
+QCFG: “nwscanseq”,0403010502
OK

AT+QCFG=“nwscanmode”
+QCFG: “nwscanmode”,0
OK

AT+CGDCONT?
+CGDCONT: 1,“IP”,“ltedata.apn”,“0.0.0.0”,0,0,0,0
+CGDCONT: 2,“IPV4V6”,“ims”,“0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0”,0,0,0,0
+CGDCONT: 3,“IPV4V6”,“SOS”,“0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0”,0,0,0,1
OK

AT+CREG?
+CREG: 0,0
OK

AT+CSQ
+CSQ: 99,99
OK

AT+QCSQ
+QCSQ: “NOSERVICE”

AT+QNWINFO
+QNWINFO: No Service
OK

AT+CGATT?
+CGATT: 0
OK

AT+QCFG=“usbnet”
+QCFG: “usbnet”,0
OK

Does the output of AT+CREG? indicate that the EC25 is not registering on the cellular network and that I need to associate my module’s IMEI to my SIM before I can connect? I had this SIM in a Huawei Cellular Modem previously and it works in my phone as well.

Thanks in advance for your help, @saeed!

Hello,

The issue is with the Firmware, EC25A variant with EC25E Firmware.
Please flash the right firmware.
Download Link including flashing tools and guide.

1 Like

Can I ask how you determined that this EC25-A had been flashed with the wrong firmware? Was it the line?

[06-15_23:18:48:409] requestBaseBandVersion EC25EFAR06A11M4G

Yes, the Firmware version of the EC25-A variant should look like EC25AFARXXXXXXXX.

I had noticed that, but for some reason, it didn’t click. I received it last week and found it unimaginable that Sixfab or Quectel would ship a device with the wrong firmware. I just thought I was doing something wrong. Thank you, @saeed. Before I flash the device I’ll contact Sixfab and advise their technical department so that if the unit is damaged while flashing it is covered by the warranty.

1 Like

I’m still having some trouble, @saeed. I’m following the instructions for QFlash, the module is plugged into my computer, I ran QFlash as administrator, but my PC is not recognizing the device and I cannot select the option for “USB DM” in COM Port field of QFlash. It is not even populating in the field.

I think it might be better if you RMA this unit and send me a new unit that is flashed with the correct firmware.

Seems you do not have the USB driver installed on your Windows Device.
Please install it from here.

Thank you, @saeed. I was finally able to get it working.

I appreciate all of your help and direction. By the way, the qmi_reconnect service does not attempt to establish or re-establish an IPv6 connection. I am able to establish an IPv6 connection manually by executing sudo ./files/quectel-CM/quectel-CM -4 -6 -s ltedata.apn only after disabling the qmi_reconnect service then rebooting the Pi. Perhaps, qmi_reconnect can be updated at some point to add IPv6 support?

Could you please share the log of the reconnect service and the reconnect scripts and service?

Sure, but I’ll need your help. I’m just learning Linux, Raspberry Pi OS, etc. Can you tell me the command to grab those logs?

HEllo, the details are available on the tutorial page.

check status of the service with
sudo systemctl status qmi_reconnect.service

the reconnect script is at /usr/src/qmi_reconnect.sh and service at /etc/systemd/system/qmi_reconnect.service

I hope this is what you’re looking for:

pi@ELANTRA:~ $ sudo systemctl status qmi_reconnect
● qmi_reconnect.service - QMI Auto Connection
Loaded: loaded (/etc/systemd/system/qmi_reconnect.service; enabled; vendor preset: enabled)
Active: active (running) since Sat 2021-06-26 01:05:12 EDT; 9min ago
Main PID: 547 (sh)
Tasks: 4 (limit: 780)
CGroup: /system.slice/qmi_reconnect.service
├─547 /bin/sh /usr/src/qmi_reconnect.sh
├─561 sudo ./quectel-CM -s ltemobile.apn
└─586 ./quectel-CM -s ltemobile.apn
Jun 26 01:05:24 ELANTRA sh[547]: udhcpc: sending discover
Jun 26 01:05:27 ELANTRA sh[547]: udhcpc: sending discover
Jun 26 01:05:30 ELANTRA sh[547]: udhcpc: no lease, failing
Jun 26 01:05:30 ELANTRA sh[547]: udhcpc: started, v1.30.1
Jun 26 01:05:30 ELANTRA sh[547]: No resolv.conf for interface wwan0.udhcpc
Jun 26 01:05:30 ELANTRA sh[547]: udhcpc: sending discover
Jun 26 01:05:30 ELANTRA sh[547]: udhcpc: sending select for 25.101.88.17
Jun 26 01:05:30 ELANTRA sh[547]: udhcpc: lease of 25.101.88.17 obtained, lease time 7200
Jun 26 01:05:30 ELANTRA sh[547]: Too few arguments
Jun 26 01:05:30 ELANTRA sh[547]: Too few arguments
pi@ELANTRA:~ $

pi@ELANTRA:~/files/quectel-CM $ sudo /bin/sh /usr/src/qmi_reconnect.sh
ping: Warning: source address might be selected on device other than wwan0.
PING 8.8.8.8 (8.8.8.8) from 192.168.0.178 wwan0: 56(84) bytes of data.
— 8.8.8.8 ping statistics —
1 packets transmitted, 0 received, 100% packet loss, time 0ms
Connection down, reconnecting…
[06-26_01:55:16:989] Quectel_QConnectManager_Linux_V1.6.0.12
[06-26_01:55:16:993] Find /sys/bus/usb/devices/1-1.2 idVendor=0x2c7c idProduct=0x125, bus=0x001,
dev=0x004
[06-26_01:55:16:993] Auto find qmichannel = /dev/cdc-wdm0
[06-26_01:55:16:994] Auto find usbnet_adapter = wwan0
[06-26_01:55:16:994] netcard driver = qmi_wwan, driver version = 5.10.17-v8+
[06-26_01:55:16:994] ioctl(0x89f3, qmap_settings) failed: Operation not supported, rc=-1
[06-26_01:55:16:995] Modem works in QMI mode
[06-26_01:55:17:041] cdc_wdm_fd = 7
[06-26_01:55:17:145] Get clientWDS = 20
[06-26_01:55:17:179] Get clientDMS = 1
[06-26_01:55:17:213] Get clientNAS = 4
[06-26_01:55:17:247] Get clientUIM = 1
[06-26_01:55:17:281] Get clientWDA = 1
[06-26_01:55:17:315] requestBaseBandVersion EC25AFAR05A07M4G
[06-26_01:55:17:451] requestGetSIMStatus SIMStatus: SIM_READY
[06-26_01:55:17:451] requestSetProfile[1] ltemobile.apn///0
[06-26_01:55:17:519] requestGetProfile[1] ltemobile.apn///0
[06-26_01:55:17:553] requestRegistrationState2 MCC: 302, MNC: 720, PS: Attached, DataCap: LTE
[06-26_01:55:17:587] requestQueryDataCall IPv4ConnectionStatus: DISCONNECTED
[06-26_01:55:17:587] ifconfig wwan0 down
[06-26_01:55:17:609] ifconfig wwan0 0.0.0.0
[06-26_01:55:17:653] requestSetupDataCall WdsConnectionIPv4Handle: 0x872db450
[06-26_01:55:17:757] ifconfig wwan0 up
[06-26_01:55:17:764] busybox udhcpc -f -n -q -t 5 -i wwan0
udhcpc: started, v1.30.1
Too few arguments.
Too few arguments.
udhcpc: sending discover
udhcpc: sending select for 25.101.88.17
udhcpc: lease of 25.101.88.17 obtained, lease time 7200
Too few arguments.
Too few arguments.

The reconnect service seems to work fine and the connection is established.

Yes, it is connecting. My complaint was that qmi_reconnect is not even attempting to establish an IPv6 connection.

Is it possible to update the script to add the flags / options -4 -6 to force qmi_reconnect to establish and maintain both an IPv4 and IPv6 connection?

I’ve edited / updated qmi_reconnect.sh to

#!/bin/sh
while true; do
ping -I wwan0 -c 1 8.8.8.8
if [ $? -eq 0 ]; then
echo “Connection up, reconnect not required…”
else
echo “Connection down, reconnecting…”
sudo ./quectel-CM -4 -6 -s ltemobile.apn
fi
sleep 1
done

… and now it is establishing and maintaining an IPv4 and IPv6 connection.

yes, you did it. The qmi_reconnect.sh needed to be changed.

It would be great if the GH repository could be updated so that IPv6 connectivity is enabled for anyone following the qmi_reconnect tutorial.

Since the use case of each user is not similar, the code is open source so that, users can change it according to their use case.