I'm stuck in MBIM mode trying to revert back to QMI

I’m having trouble connecting to the internet using my rm500-ae. I was trying to switch to Ethernet mode but i kept having a hard time, so I tried to switch back to QMI but instead it’s stuck on MBIM mode. I can get into at commands onto my router itself, but I don’t know how to fix to errors I caused. it keeps saying sim_illegal_state. So can I get help with this please?

Let’s start by showing the current state:
cat /sys/kernel/debug/usb/devices

root@OpenWrt:~# - cat /sys/kernel/debug/usb/devices
-ash: -: not found
root@OpenWrt:~#

"-" symbol is not a part of the command

T: Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=480 MxCh= 1
B: Alloc= 0/800 us ( 0%), #Int= 0, #Iso= 0
D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=1d6b ProdID=0002 Rev= 6.06
S: Manufacturer=Linux 6.6.32 ehci_hcd
S: Product=EHCI Host Controller
S: SerialNumber=f1058000.usb
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=02 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=480 MxCh= 1
B: Alloc= 0/800 us ( 0%), #Int= 0, #Iso= 0
D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=1d6b ProdID=0002 Rev= 6.06
S: Manufacturer=Linux 6.6.32 xhci-hcd
S: Product=xHCI Host Controller
S: SerialNumber=f10f8000.usb3
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=02 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 3 Spd=480 MxCh= 0
D: Ver= 2.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1
P: Vendor=2c7c ProdID=0800 Rev= 4.14
S: Manufacturer=Quectel
S: Product=RM500Q-AE
S: SerialNumber=52f531b0
C:* #Ifs= 5 Cfg#= 1 Atr=a0 MxPwr=500mA
I:* If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
E: Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E: Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:* If#= 1 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=40 Driver=option
E: Ad=83(I) Atr=03(Int.) MxPS= 10 Ivl=32ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:* If#= 2 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
E: Ad=85(I) Atr=03(Int.) MxPS= 10 Ivl=32ms
E: Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E: Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:* If#= 3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
E: Ad=87(I) Atr=03(Int.) MxPS= 10 Ivl=32ms
E: Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E: Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
I:* If#= 4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=ff Driver=qmi_wwan
E: Ad=88(I) Atr=03(Int.) MxPS= 8 Ivl=32ms
E: Ad=8e(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E: Ad=0f(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms

T: Bus=03 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=5000 MxCh= 1
B: Alloc= 0/800 us ( 0%), #Int= 0, #Iso= 0
D: Ver= 3.00 Cls=09(hub ) Sub=00 Prot=03 MxPS= 9 #Cfgs= 1
P: Vendor=1d6b ProdID=0003 Rev= 6.06
S: Manufacturer=Linux 6.6.32 xhci-hcd
S: Product=xHCI Host Controller
S: SerialNumber=f10f8000.usb3
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

Your modem is in QMI mode.
I suggest switching it to MBIM (AT+QCFG="usbnet",2) and make configuration as shown in OpenWrt wiki.

okay how can i switch to mbim?

… as shown in OpenWrt wiki

okay and another thing, its not giving me any internet connection at all during qmi mode

First check on the modem itself:

AT+CEREG?
AT+CGDCONT?
AT+CGPADDR
AT+QENG="servingcell"

Then make sure everything is configured per OpenWrt instructions then ask for help in their forum.

AT+CEREG?
+CEREG: 0,0
T+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,“”,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,“”,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,“”,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,“”,0
+CGDCONT: 5,“IPV4V6”,“h2g2”,“0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0”,0,0,0,0,“”,0
AT+QENG=“servingcell” +QENG: “servingcell”,“LIMSRV”,“LTE”,“FDD”,311,480,6FE6B0F,27,1025,2,2,2,9E03,-94,-15,-63,18,0,-,30

You’re not registered to the network, it’s too early to talk about connection.

Show the result of AT+QMBNCFG="List"

What is the correct APN name for your SIM/plan ?

its really
fast.t-mobile.com

but it doesn’t show up on the AT+QMBNCFG=“List”

You need to show the complete command output, formatted.

yeah heres what shows
AT+QMBNCFG=“List”
+QMBNCFG: “List”,0,1,1,“Commercial-TMO”,0x0A01050F,202303281
+QMBNCFG: “List”,1,0,0,“ROW_Commercial”,0x0A010809,202201191
+QMBNCFG: “List”,2,0,0,“FirstNet”,0x0A015300,202106041
+QMBNCFG: “List”,3,0,0,“5G-ATT”,0x0A015700,202101151
+QMBNCFG: “List”,4,0,0,“ROW_Generic_3GPP_PTCRB_GCF”,0x0A01FB09,202102071
+QMBNCFG: “List”,5,0,0,“Rogers_Canada”,0x0A014800,202101151
+QMBNCFG: “List”,6,0,0,“Bell_Canada”,0x0A014700,202101151
+QMBNCFG: “List”,7,0,0,“Telus_DataOnly”,0x0A014900,202101151
+QMBNCFG: “List”,8,0,0,“Commercial-Sprint”,0x0A010204,202101151
+QMBNCFG: “List”,9,0,0,“VoLTE-ATT”,0x0A010335,202102031
+QMBNCFG: “List”,10,0,0,“CDMAless-Verizon”,0x0A010126,202209271
+QMBNCFG: “List”,11,0,0,“Telia_Sweden”,0x0A012400,202101151
+QMBNCFG: “List”,12,0,0,“TIM_Italy_Commercial”,0x0A012B00,202101151
+QMBNCFG: “List”,13,0,0,“France-Commercial-Orange”,0x0A010B21,202101151
+QMBNCFG: “List”,14,0,0,“Commercial-DT-VOLTE”,0x0A011F1F,202101151
+QMBNCFG: “List”,15,0,0,“Germany-VoLTE-Vodafone”,0x0A010449,202101151
+QMBNCFG: “List”,16,0,0,“UK-VoLTE-Vodafone”,0x0A010426,202101151
+QMBNCFG: “List”,17,0,0,“Commercial-EE”,0x0A01220B,202101151
+QMBNCFG: “List”,18,0,0,“Optus_Australia_Commercial”,0x0A014400,202101151
+QMBNCFG: “List”,19,0,0,“Telstra_Australia_Commercial”,0x0A010F00,202201111
+QMBNCFG: “List”,20,0,0,“Commercial-LGU”,0x0A012608,202101151
+QMBNCFG: “List”,21,0,0,“Commercial-KT”,0x0A01280B,202101151
+QMBNCFG: “List”,22,0,0,“Commercial-SKT”,0x0A01270A,202101151
+QMBNCFG: “List”,23,0,0,“Commercial-Reliance”,0x0A011B0C,202210211
+QMBNCFG: “List”,24,0,0,“Commercial-SBM”,0x0A011C0B,202101151
+QMBNCFG: “List”,25,0,0,“Commercial-KDDI”,0x0A010709,202101151
+QMBNCFG: “List”,26,0,0,“Commercial-DCM”,0x0A010D0D,202101151
+QMBNCFG: “List”,27,0,0,“VoLTE-CU”,0x0A011561,202101151
+QMBNCFG: “List”,28,0,0,“VoLTE_OPNMKT_CT”,0x0A0113E0,202101151
+QMBNCFG: “List”,29,0,0,“Volte_OpenMkt-Commercial-CMCC”,0x0A012010,202101151

First check if SIM is accessible with AT+CPIN?

If you get +CPIN: READY in response, then proceed, otherwise focus on fixing SIM issue.

Let’s try to disable this:

AT+QMBNCFG="AutoSel",0
AT+QMBNCFG="Deactivate"
AT+CFUN=1,1

Modem will restart, give it a few moments and repeat AT commands from my earlier post.

okay i’ve did that, and its still not connecting to the internet.

You need to show the output, formatted.

Unknown error (SIM_ILLEGAL_STATE)