Modem Disappears a few seconds after boot

Environment:
Raspberry Pi 4b, Debian 12 lite, Sixfab LTE Hat, Quectel EG25G, Sixfab UPS v2, Sixfab 4g antennas, T-mobile data sim

This pi is going to be an off grid server for a cabin. Plex, multiple web apps running in docker, camera, weather station, soil monitoring.

Problem:
I had this up and running in any/all cellular modes ECM, PPP, QMI (i was testing) in the end i opted for using modem manager and network manager with qmi. Speeds and latency were excellent. Now, i have 2 Quectel Eg25G’s and a Telit910NF purchased through sixfab. All of a sudden on this pi and it is reproducable with my second hat and EG25G is that i can talk to the modem for a few seconds and get it’s bearer through modem manager and then…it’s just gone (mmcli --modem=0, no modem found), but it populates everything for the first few seconds. If i use minicom to talk to the serial port i can issue AT commands but the interface is EXTREMLY SLOW (both entering and exiting minicom). So basically my modem just up and disappears and I don’t know why.

This connection is with the qmi-wwan drivers that are preinstalled in debian 12 (no need to install anymore)

Just to reiterate I had this up and running beautifully.

The commands used to attach the gsm/lte connection in network manager are:

sudo nmcli connection add type gms ifname "cdc-wdm0’ con-name ‘ARBITRARY NAME’ apn ‘YOUR APN’ connection.autoconnect yes

Linux command line output:

 cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux 12 (bookworm)"
NAME="Debian GNU/Linux"
VERSION_ID="12"
VERSION="12 (bookworm)"
VERSION_CODENAME=bookworm
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
 uname -a
Linux wipi 6.1.0-rpi4-rpi-v8 #1 SMP PREEMPT Debian 1:6.1.54-1+rpt2 (2023-10-05) aarch64 GNU/Linux
 lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 2c7c:0125 Quectel Wireless Solutions Co., Ltd. EC25 LTE modem
Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
 lsusb -t
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/1p, 480M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/4p, 480M
        |__ Port 4: Dev 3, If 0, Class=Vendor Specific Class, Driver=option, 480M
        |__ Port 4: Dev 3, If 1, Class=Vendor Specific Class, Driver=option, 480M
        |__ Port 4: Dev 3, If 2, Class=Vendor Specific Class, Driver=option, 480M
        |__ Port 4: Dev 3, If 3, Class=Vendor Specific Class, Driver=option, 480M
        |__ Port 4: Dev 3, If 4, Class=Vendor Specific Class, Driver=qmi_wwan, 480M
usb-devices

T:  Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=480 MxCh= 1
D:  Ver= 2.00 Cls=09(hub  ) Sub=00 Prot=01 MxPS=64 #Cfgs=  1
P:  Vendor=1d6b ProdID=0002 Rev=06.01
S:  Manufacturer=Linux 6.1.0-rpi4-rpi-v8 xhci-hcd
S:  Product=xHCI Host Controller
S:  SerialNumber=0000:01:00.0
C:  #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=0mA
I:  If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub
E:  Ad=81(I) Atr=03(Int.) MxPS=   4 Ivl=256ms

T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  2 Spd=480 MxCh= 4
D:  Ver= 2.10 Cls=09(hub  ) Sub=00 Prot=01 MxPS=64 #Cfgs=  1
P:  Vendor=2109 ProdID=3431 Rev=04.21
S:  Product=USB2.0 Hub
C:  #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=100mA
I:  If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub
E:  Ad=81(I) Atr=03(Int.) MxPS=   1 Ivl=256ms

T:  Bus=01 Lev=02 Prnt=02 Port=03 Cnt=01 Dev#=  3 Spd=480 MxCh= 0
D:  Ver= 2.00 Cls=ef(misc ) Sub=02 Prot=01 MxPS=64 #Cfgs=  1
P:  Vendor=2c7c ProdID=0125 Rev=03.18
S:  Manufacturer=Quectel
S:  Product=EG25-G
C:  #Ifs= 5 Cfg#= 1 Atr=a0 MxPwr=500mA
I:  If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=option
E:  Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:  If#= 1 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=83(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
I:  If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
E:  Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=85(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
I:  If#= 3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
E:  Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=87(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
I:  If#= 4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=ff Driver=qmi_wwan
E:  Ad=05(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=88(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=89(I) Atr=03(Int.) MxPS=   8 Ivl=32ms

T:  Bus=02 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=5000 MxCh= 4
D:  Ver= 3.00 Cls=09(hub  ) Sub=00 Prot=03 MxPS= 9 #Cfgs=  1
P:  Vendor=1d6b ProdID=0003 Rev=06.01
S:  Manufacturer=Linux 6.1.0-rpi4-rpi-v8 xhci-hcd
S:  Product=xHCI Host Controller
S:  SerialNumber=0000:01:00.0
C:  #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=0mA
I:  If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub
E:  Ad=81(I) Atr=03(Int.) MxPS=   4 Ivl=256ms
dmesg | grep tty
[    0.000000] Kernel command line: coherent_pool=1M 8250.nr_uarts=1 snd_bcm2835.enable_headphones=0 snd_bcm2835.enable_headphones=1 snd_bcm2835.enable_hdmi=1 snd_bcm2835.enable_hdmi=0  smsc95xx.macaddr=DC:A6:32:EE:8C:47 vc_mem.mem_base=0x3ec00000 vc_mem.mem_size=0x40000000  console=ttyS0,115200 console=tty1 root=PARTUUID=dea94805-02 rootfstype=ext4 fsck.repair=yes rootwait cfg80211.ieee80211_regdom=US
[    0.000887] printk: console [tty1] enabled
[    1.661915] fe201000.serial: ttyAMA1 at MMIO 0xfe201000 (irq = 36, base_baud = 0) is a PL011 rev2
[    1.662212] serial serial0: tty port ttyAMA1 registered
[    1.671264] printk: console [ttyS0] disabled
[    1.671392] fe215040.serial: ttyS0 at MMIO 0xfe215040 (irq = 37, base_baud = 62500000) is a 16550
[    1.848147] printk: console [ttyS0] enabled
[    7.213415] systemd[1]: Created slice system-getty.slice - Slice /system/getty.
[    7.233433] systemd[1]: Created slice system-serial\x2dgetty.slice - Slice /system/serial-getty.
[   11.323173] usb 1-1.4: GSM modem (1-port) converter now attached to ttyUSB0
[   11.410588] usb 1-1.4: GSM modem (1-port) converter now attached to ttyUSB1
[   11.485619] usb 1-1.4: GSM modem (1-port) converter now attached to ttyUSB2
[   11.503643] usb 1-1.4: GSM modem (1-port) converter now attached to ttyUSB3
ls -l /sys/bus/usb-serial/devices
total 0
lrwxrwxrwx 1 root root 0 Oct 26 22:02 ttyUSB0 -> ../../../devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.4/1-1.4:1.0/ttyUSB0
lrwxrwxrwx 1 root root 0 Oct 26 22:02 ttyUSB1 -> ../../../devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.4/1-1.4:1.1/ttyUSB1
lrwxrwxrwx 1 root root 0 Oct 26 22:02 ttyUSB2 -> ../../../devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.4/1-1.4:1.2/ttyUSB2
lrwxrwxrwx 1 root root 0 Oct 26 22:02 ttyUSB3 -> ../../../devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.4/1-1.4:1.3/ttyUSB3
ls -l /dev/serial/by-id
total 0
lrwxrwxrwx 1 root root 13 Oct 26 20:52 usb-Quectel_EG25-G-if00-port0 -> ../../ttyUSB0
lrwxrwxrwx 1 root root 13 Oct 26 20:52 usb-Quectel_EG25-G-if01-port0 -> ../../ttyUSB1
lrwxrwxrwx 1 root root 13 Oct 26 20:52 usb-Quectel_EG25-G-if02-port0 -> ../../ttyUSB2
lrwxrwxrwx 1 root root 13 Oct 26 20:52 usb-Quectel_EG25-G-if03-port0 -> ../../ttyUSB3

AT commands:

AT

OK

ATI

Quectel
EG25
Revision: EG25GGBR07A08M2G

OK

AT+QGMR

EG25GGBR07A08M2G_30.200.30.200

OK

AT+CPIN?

+CPIN: READY

OK

AT+CPAS

+CPAS: 0

OK

AT+CFUN?

+CFUN: 1

OK

AT+COPS?

+COPS: 0

OK

AT+QCFG=“usbnet”

+QCFG: “usbnet”,0

OK

AT+QCFG=“band”

+QCFG: “band”,0xbff,0x1e00b0e18df,0x0

OK

AT+CREG?

+CREG: 0,3

OK
AT+CGDCONT?

+CGDCONT: 1,“IPV4V6”,“fast.t-mobile.com”,“0.0.0.0.0.0.0.0.0.0.0.0.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
+CGDCONT: 4,“IPV4V6”,“tmus”,“0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0”,0,0,0,0

OK

AT+CSQ

+CSQ: 15,99

OK

AT+CGATT?

+CGATT: 0

OK

AT+QCFG=“nwscanseq”

+QCFG: “nwscanseq”,0403010502

OK

AT+QCFG=“nwscanmode”

+QCFG: “nwscanmode”,0

OK

AT+QCFG=“iotopmode”

ERROR

AT+QCSQ

+QCSQ: “LTE”,83,-107,206,-7

OK

AT+QNWINFO

+QNWINFO: “FDD LTE”,“311480”,“LTE BAND 13”,5230

OK