Hi,
Thank you for the detailed report. We can help resolve both issues you encountered.
1. Recovering AT Command Access After Switching to ECM
AT command ports are still present after switching to ECM — the port numbers may have simply shifted after USB re-enumeration. To verify and recover:
# Check which ports are available after module boots
dmesg | grep -i "ttyUSB\|quectel"
# Try sending AT to each candidate port
echo -e "AT\r" > /dev/ttyUSB2
# Once AT responds, revert to RMNET and reboot the module
echo -e 'AT+QCFG="usbnet",0\r' > /dev/ttyUSB2
echo -e "AT+CFUN=1,1\r" > /dev/ttyUSB2
If the kernel lacks the cdc_ether driver, only the network interface disappears — the AT ports remain accessible.
2. Root Cause of Wake-Up Disconnections
Switching to ECM mode will not resolve the disconnection issue. The underlying cause is a USB suspend/resume timing problem between the PinePhone’s Allwinner A64 USB controller and the EC25-G module.
When the host wakes from sleep, the USB controller must send SOF packets to the bus within 3 seconds of the module’s remote wakeup signal. If it misses this window, the module re-enters suspend and drops the connection. This behaviour is independent of whether RMNET, ECM, MBIM, or RNDIS is configured.
Recommended fix — disable USB autosuspend for the EC25-G via udev:
# Create a udev rule to disable autosuspend (Quectel EC25-G VID:PID = 2c7c:0125)
echo 'ACTION=="add", SUBSYSTEM=="usb", ATTRS{idVendor}=="2c7c", ATTRS{idProduct}=="0125", TEST=="power/autosuspend", ATTR{power/autosuspend}="-1"' \
| sudo tee /etc/udev/rules.d/99-quectel-no-autosuspend.rules
sudo udevadm control --reload-rules
sudo udevadm trigger
# Verify it applied (should return -1)
cat /sys/bus/usb/devices/<bus>-<port>/power/autosuspend
Additionally, confirm that sleep mode is not enabled on the module side:
AT+QSCLK?
# Expected: +QSCLK: 0
# If it returns 1 or 2, disable it:
AT+QSCLK=0
This should fully resolve the disconnection on wake without any kernel recompilation or USB mode changes.