EM160R-GL on linux in ECM mode does not work

EM160R-GL on linux in ECM mode does not give an IP address when request an address via DHCP, this problem is not present in QMI and MBIM modes, but I want ECM mode.

I think I found the solution to the problem in ECM mode, but those AT settings do not work on the EM160R-GL modem.

Maybe these AT commands are the solution, but they give me ERROR:

AT+QCFG="ethernet"
ERROR

AT+QCFG="ethernet",0
ERROR

AT+QCFG="nat",0
ERROR

AT+QNETDEVCTL?
ERROR

AT+QNETDEVSTATUS
ERROR

AT+QNETDEVCTL=1,1,1
ERROR

AT+QNETDEVCTL=1,3,1
ERROR

AT+QNETDEVCTL=2,3,1
ERROR

AT+QNETDEVCTL=3,1,0
ERROR

AT+QNETDEVSTATUS
ERROR

AT+QMAP
ERROR

AT+QMAP?
ERROR

AT+QMAP=?
ERROR

AT+QMAP="LANIP"
ERROR

Troubleshooting

With an “x” I hide IMEI, IP and MAC addresses.

Linux Commands:

Modify TTL and Hop Limit for egress traffic in nftables:

root@OpenWrt:~# nft list ruleset
...
        chain mangle_postrouting {
                type filter hook postrouting priority mangle; policy accept;
                oifname { "usb0", "ppp0", "eth1", "wwan0" } ip ttl set 65
                oifname { "usb0", "ppp0", "eth1", "wwan0" } ip6 hoplimit set 65
        }
...


root@OpenWrt:~# udhcpc -n -q -f -i usb0
udhcpc: started, v1.36.1
udhcpc: broadcasting discover
udhcpc: broadcasting discover
udhcpc: broadcasting discover
udhcpc: no lease, failing


root@OpenWrt:~# ip a
8: usb0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN qlen 1000
    link/ether 1a:37:x:x:x:x brd ff:ff:ff:ff:ff:ff
    inet6 fe80::1837:x:x:x/64 scope link
       valid_lft forever preferred_lft forever


root@OpenWrt:~# ip route
192.168.1.0/24 dev br-lan scope link  src 192.168.1.1


root@OpenWrt:~# ifconfig usb0
usb0      Link encap:Ethernet  HWaddr 1A:37:x:x:x:x
          inet6 addr: fe80::1837:x:x:x/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:12 errors:0 dropped:0 overruns:0 frame:0
          TX packets:91 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:760 (760.0 B)  TX bytes:29474 (28.7 KiB)


root@OpenWrt:~# lsusb && lsusb -t
Bus 001 Device 001: ID 1d6b:0002 Linux 5.15.150 xhci-hcd xHCI Host Controller
Bus 002 Device 002: ID 2c7c:0620 Quectel EM160R-GL
Bus 002 Device 001: ID 1d6b:0003 Linux 5.15.150 xhci-hcd xHCI Host Controller
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci-mtk/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=, Driver=option, 5000M
    |__ Port 1: Dev 2, If 1, Class=, Driver=option, 5000M
    |__ Port 1: Dev 2, If 2, Class=, Driver=option, 5000M
    |__ Port 1: Dev 2, If 3, Class=, Driver=option, 5000M
    |__ Port 1: Dev 2, If 4, Class=, Driver=cdc_ether, 5000M
    |__ Port 1: Dev 2, If 5, Class=, Driver=cdc_ether, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci-mtk/2p, 480M


root@OpenWrt:~# cat /sys/kernel/debug/usb/devices
...
T:  Bus=02 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  2 Spd=5000 MxCh= 0
D:  Ver= 3.20 Cls=ef(misc ) Sub=02 Prot=01 MxPS= 9 #Cfgs=  1
P:  Vendor=2c7c ProdID=0620 Rev= 4.09
S:  Manufacturer=Quectel
S:  Product=EM160R-GL
S:  SerialNumber=xxxxxxxx
C:* #Ifs= 6 Cfg#= 1 Atr=a0 MxPwr=896mA
I:* If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=30 Driver=option
E:  Ad=81(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
E:  Ad=01(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
I:* If#= 1 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=option
E:  Ad=83(I) Atr=03(Int.) MxPS=  10 Ivl=32ms
E:  Ad=82(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
E:  Ad=02(O) Atr=02(Bulk) MxPS=1024 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=1024 Ivl=0ms
E:  Ad=03(O) Atr=02(Bulk) MxPS=1024 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=1024 Ivl=0ms
E:  Ad=04(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms
I:* If#= 4 Alt= 0 #EPs= 1 Cls=02(comm.) Sub=06 Prot=00 Driver=cdc_ether
E:  Ad=88(I) Atr=03(Int.) MxPS=  16 Ivl=32ms
I:  If#= 5 Alt= 0 #EPs= 0 Cls=0a(data ) Sub=00 Prot=00 Driver=cdc_ether
I:* If#= 5 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=cdc_ether
E:  Ad=8e(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
E:  Ad=0f(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms


root@OpenWrt:~# ls /dev/ttyUS*
/dev/ttyUSB0  /dev/ttyUSB1  /dev/ttyUSB2  /dev/ttyUSB3


root@OpenWrt:~# picocom /dev/ttyUSB2
picocom v3.1
...
Terminal ready

AT Commands:

AT+QGMR
EM160RGLAUR02A12M4GA
OK

AT+QCFG="usbnet"
+QCFG: "usbnet",1
OK

AT+QNWPREFCFG="mode_pref"
+QNWPREFCFG: "mode_pref",AUTO
OK

AT+QNWPREFCFG="lte_band"
+QNWPREFCFG: "lte_band",1:2:3:4:5:7:8:12:13:14:17:18:19:20:25:26:28:29:30:32:38:39:40:41:42:43:46:48:66
OK

AT+QMBNCFG=?
+QMBNCFG: "List"
+QMBNCFG: "Select"[,<MBN name>]
+QMBNCFG: "Deactivate"
+QMBNCFG: "AutoSel"[,(0,1)]
+QMBNCFG: "Delete","<MBN name>"
+QMBNCFG: "Add","<filename>"
OK

OK
AT+QMBNCFG="List"
+QMBNCFG: "List",0,1,1,"ROW_Commercial",0x08010809,202009241
+QMBNCFG: "List",1,0,0,"TIM_Italy_Commercial",0x08012B00,202004261
+QMBNCFG: "List",2,0,0,"Commercial-DT-VOLTE",0x08011F1F,202112061
+QMBNCFG: "List",3,0,0,"Commercial-TMO",0x0801050F,202205061
+QMBNCFG: "List",4,0,0,"Telstra_Australia_Commercial",0x08010F00,202206021
+QMBNCFG: "List",5,0,0,"ROW_Generic_3GPP_PTCRB_GCF",0x0801FE02,201910231
+QMBNCFG: "List",6,0,0,"Wind_Italy_Commercial",0x0801F300,202203031
+QMBNCFG: "List",7,0,0,"Germany-VoLTE-Vodafone",0x08010449,202004261
+QMBNCFG: "List",8,0,0,"Swiss-Comm",0x08010411,202004261
+QMBNCFG: "List",9,0,0,"Commercial-EE",0x0801220B,202004261
+QMBNCFG: "List",10,0,0,"CDMAless-Verizon",0x08010126,202007151
+QMBNCFG: "List",11,0,0,"hVoLTE-Verizon",0x0801010E,202006091
+QMBNCFG: "List",12,0,0,"Commercial-Sprint",0x08010204,202205061
+QMBNCFG: "List",13,0,0,"FirstNet",0x08015300,202009231
+QMBNCFG: "List",14,0,0,"VoLTE-ATT",0x08010335,202001101
+QMBNCFG: "List",15,0,0,"VoLTE-CU",0x08011561,202003131
+QMBNCFG: "List",16,0,0,"VoLTE_OPNMKT_CT",0x080113E0,202004261
+QMBNCFG: "List",17,0,0,"Volte_OpenMkt-Commercial-CMCC",0x08012010,201907031
+QMBNCFG: "List",18,0,0,"Rakuten_Japan_Commercial",0x08015500,202107021
+QMBNCFG: "List",19,0,0,"Commercial-KDDI",0x08010709,202006181
+QMBNCFG: "List",20,0,0,"Commercial-DCM",0x08010D0D,202004261
+QMBNCFG: "List",21,0,0,"Commercial-SBM",0x08011C0B,201907031
OK

AT+QMBNCFG="AutoSel"
+QMBNCFG: "AutoSel",1
OK

AT+CGDCONT=1,"IPV4V6","internet.ideasclaro"
OK

AT+CGDCONT=?
+CGDCONT: (1-42),"IP",,,(0-3),(0-4),(0-1),(0-1)
+CGDCONT: (1-42),"PPP",,,(0-3),(0-4),(0-1),(0-1)
+CGDCONT: (1-42),"IPV6",,,(0-3),(0-4),(0-1),(0-1)
+CGDCONT: (1-42),"IPV4V6",,,(0-3),(0-4),(0-1),(0-1)
OK

AT+CGDCONT?
+CGDCONT: 1,"IPV4V6","internet.ideasclaro","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
OK

AT+CGPADDR
+CGPADDR: 1,"10.68.x.x,40.3.70.0.16.25.218.81.0.0.0.26.73.95.164.1"
+CGPADDR: 2,""
+CGPADDR: 3,""
OK

AT+CGCONTRDP
+CGCONTRDP: 1,5,internet.ideasclaro,10.68.x.x,40.3.70.0.16.25.218.81.0.0.0.26.73.95.164.1, 254.128.0.0.0.0.0.0.0.0.0.26.73.95.164.64,216.230.147.90 40.0.0.152.0.0.0.4.0.0.0.0.0.0.0.4,216.230.139.8 40.3.243.64.19.0.0.0.0.0.0.0.0.0.0.12
OK

AT+CGCONTRDP=1
+CGCONTRDP: 1,5,internet.ideasclaro,10.68.x.x,40.3.70.0.16.25.218.81.0.0.0.26.73.95.164.1, 254.128.0.0.0.0.0.0.0.0.0.26.73.95.164.64,216.230.147.90 40.0.0.152.0.0.0.4.0.0.0.0.0.0.0.4,216.230.139.8 40.3.243.64.19.0.0.0.0.0.0.0.0.0.0.12
OK

AT+COPS?
+COPS: 0,0,"CLARO HND LTE Claro",7
OK

AT+QNWINFO
+QNWINFO: "FDD LTE","708001","LTE BAND 4",2250
OK

AT+QENG="serving cell"
OK

AT+QCAINFO
OK

AT+CREG?
+CREG: 0,1
OK

AT+CGACT?
+CGACT: 1,1
+CGACT: 2,0
+CGACT: 3,0
OK

AT+CGACT=?
+CGACT: (0,1)
OK

AT+QIACT=1
OK

AT+QIACT?
+QIACT: 1,1,1,"10.68.x.x"
OK

AT+CPIN?
+CPIN: READY

AT+QPING=1,"www.baidu.com"
OK

AT+QPING=1,"8.8.8.8"
OK

Temporary solution
Install ModemManager, but I don’t want to have this application when in ECM mode it is simple and more than enough.

The only problem I have found in ECM mode is that IPv6 addresses are not delegated, it only works in IPv4 protocol and this problem is not present in QMI and MBIM modes.

These are the settings that change when I use ModemManager in ECM mode:

root@OpenWrt:~# ip a
8: usb0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN qlen 1000
    link/ether ca:89:x:x:x:x brd ff:ff:ff:ff:ff:ff
...
10: ppp0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN qlen 3
    link/ppp
    inet 10.187.x.x peer 10.64.64.64/32 scope global ppp0
       valid_lft forever preferred_lft forever
    inet6 fe80::89d:x:x:x/128 scope link
       valid_lft forever preferred_lft forever


root@OpenWrt:~# ip route
default via 10.64.64.64 dev ppp0
10.64.64.64 dev ppp0 scope link  src 10.187.x.x
192.168.1.0/24 dev br-lan scope link  src 192.168.1.1


root@OpenWrt:~# ifconfig ppp0
ppp0      Link encap:Point-to-Point Protocol
          inet addr:10.187.x.x  P-t-P:10.64.64.64  Mask:255.255.255.255
          inet6 addr: fe80::89d:x:x:x/128 Scope:Link
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1
          RX packets:1364 errors:0 dropped:0 overruns:0 frame:0
          TX packets:2646 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:3
          RX bytes:65668 (64.1 KiB)  TX bytes:688363 (672.2 KiB)


root@OpenWrt:~# mmcli -L
    /org/freedesktop/ModemManager1/Modem/0 [Quectel] EM160R-GL


root@OpenWrt:~# mmcli -m 0
  --------------------------------
  General  |                 path: /org/freedesktop/ModemManager1/Modem/0
           |            device id: 372ac7fb1ce4dc1accb3798a55714e00f55e8d20
  --------------------------------
  Hardware |         manufacturer: Quectel
           |                model: EM160R-GL
           |    firmware revision: EM160RGLAUR02A12M4GA
           |            supported: gsm-umts, lte
           |              current: gsm-umts, lte
           |         equipment id: xxxxxxx
  --------------------------------
  System   |               device: /sys/devices/platform/1e1c0000.xhci/usb2/2-1
           |              physdev: /sys/devices/platform/1e1c0000.xhci/usb2/2-1
           |              drivers: option1, cdc_ether
           |               plugin: quectel
           |         primary port: ttyUSB2
           |                ports: ttyUSB2 (at), ttyUSB3 (at), usb0 (net)
  --------------------------------
  Status   |       unlock retries: sim-pin (3), sim-puk (10), sim-pin2 (3), sim-puk2 (10)
           |                state: connected
           |          power state: on
           |          access tech: lte
           |       signal quality: 100% (recent)
  --------------------------------
  Modes    |            supported: allowed: 2g, 3g, 4g; preferred: none
           |              current: allowed: 2g, 3g, 4g; preferred: none
  --------------------------------
  IP       |            supported: ipv4, ipv6, ipv4v6
  --------------------------------
  3GPP     |                 imei: xxxxxxx
           |          operator id: 708001
           |        operator name: CLARO HND LTE Claro
           |         registration: home
           | packet service state: attached
  --------------------------------
  3GPP EPS | ue mode of operation: csps-2
  --------------------------------
  SIM      |     primary sim path: /org/freedesktop/ModemManager1/SIM/0
  --------------------------------
  Bearer   |                paths: /org/freedesktop/ModemManager1/Bearer/1

Can you give me a firmware version that works with the above AT commands and does not give ERROR or some other way to make the EM160R-GL modem respond when requesting an address via DHCP in ECM mode so I don’t have to use ModemManager.

I hope you can help me, thank you.

@herbert.pan-Q @Bean.Wang-Q @Great.Zheng-Q @Kerr.Yang-Q @Puck-Q @vincent.ding-Q @Stephen.Li-Q @silvia @AnnaLiu @jfrog

hi,
1、Make sure your current version is the latest baseline version. Also, are the module drivers installed from Quectel?
2、This Qualcomm module does not support the QNETDEVCTL dialing command. I have sent 2 dialing documents for this module, which should be helpful to you.
3、It is recommended that in ECM mode, you can first adjust it under Windows, and then go to Linux system for debugging. Under normal circumstances, ECM dials automatically.

The ModemManager do not support the ECM mode.
If the modem is already in ECM mode, the should exist an interface which might be usb0.
Check whether there is an IP on the usb0.

I already have the modem in ECM mode and configured correctly, the problem is that it does not give an IP address when requesting an address via DHCP, please you can look Troubleshooting section that the modem is already working in ECM mode and exist the interface usb0.

This problem is not new and I think it is solved with the AT commands mentioned above, because with those AT commands other people solved the same problem that I have, but I can’t execute them because they give me ERROR:

AT+QMAP?
AT+QMAP=?
AT+QCFG="ethernet",0 
AT+QCFG="nat",0 
AT+QNETDEVCTL=1,3,1
AT+CFUN=1,1

The modem itself has internet, it just doesn’t give me an IP address when I request an address via DHCP in Linux:

AT+QIACT=1
OK

AT+QIACT?
+QIACT: 1,1,1,"10.68.x.x"
OK

AT+CPIN?
+CPIN: READY

AT+QPING=1,"www.baidu.com"
OK

AT+QPING=1,"8.8.8.8"
OK

The only solution that I have found are the commands mentioned above but they do not work on my EM160R-GL modem (because they give me ERROR), what should be done now is to ask the modem firmware section manager to look at the EM160R-GL source code and find the problem in ECM mode by comparing with the firmware of other modem models and release a new firmware version to correct this problem.

Can you give me some AT commands or Linux commands to try, maybe it will help.

They have the same problem:

They had the same problem but they solved it with the commands below:

Maybe these AT commands are the solution, but they give me ERROR:
AT+QCFG="ethernet"
ERROR

AT+QCFG="ethernet",0
ERROR

AT+QCFG="nat",0
ERROR

AT+QNETDEVCTL?
ERROR

AT+QNETDEVSTATUS
ERROR

AT+QNETDEVCTL=1,1,1
ERROR

AT+QNETDEVCTL=1,3,1
ERROR

AT+QNETDEVCTL=2,3,1
ERROR

AT+QNETDEVCTL=3,1,0
ERROR

AT+QNETDEVSTATUS
ERROR

AT+QMAP
ERROR

AT+QMAP?
ERROR

AT+QMAP=?
ERROR

AT+QMAP="LANIP"
ERROR

Please see all commands I have used in the Troubleshooting section.

root@OpenWrt:~# udhcpc -n -q -f -i usb0
udhcpc: started, v1.36.1
udhcpc: broadcasting discover
udhcpc: broadcasting discover
udhcpc: broadcasting discover
udhcpc: no lease, failing


root@OpenWrt:~# ip a
8: usb0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN qlen 1000
    link/ether 1a:37:x:x:x:x brd ff:ff:ff:ff:ff:ff
    inet6 fe80::1837:x:x:x/64 scope link
       valid_lft forever preferred_lft forever


root@OpenWrt:~# ip route
192.168.1.0/24 dev br-lan scope link  src 192.168.1.1


root@OpenWrt:~# ifconfig usb0
usb0      Link encap:Ethernet  HWaddr 1A:37:x:x:x:x
          inet6 addr: fe80::1837:x:x:x/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:12 errors:0 dropped:0 overruns:0 frame:0
          TX packets:91 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:760 (760.0 B)  TX bytes:29474 (28.7 KiB)

I don’t want to use ModemManager, I only installed ModemManager for testing purposes, the problem is that it is the only way to get the modem to work in ECM mode and I think it is a problem with the default firmware configuration and not a problem caused by me.

ModemManager has support with ECM mode, you can see at the end of the Temporary solution section:

root@OpenWrt:~# mmcli -L
    /org/freedesktop/ModemManager1/Modem/0 [Quectel] EM160R-GL


root@OpenWrt:~# mmcli -m 0
  --------------------------------
  General  |                 path: /org/freedesktop/ModemManager1/Modem/0
           |            device id: 372ac7fb1ce4dc1accb3798a55714e00f55e8d20
  --------------------------------
  Hardware |         manufacturer: Quectel
           |                model: EM160R-GL
           |    firmware revision: EM160RGLAUR02A12M4GA
           |            supported: gsm-umts, lte
           |              current: gsm-umts, lte
           |         equipment id: xxxxxxx
  --------------------------------
  System   |               device: /sys/devices/platform/1e1c0000.xhci/usb2/2-1
           |              physdev: /sys/devices/platform/1e1c0000.xhci/usb2/2-1
           |              drivers: option1, cdc_ether
           |               plugin: quectel
           |         primary port: ttyUSB2
           |                ports: ttyUSB2 (at), ttyUSB3 (at), usb0 (net)
  --------------------------------
  Status   |       unlock retries: sim-pin (3), sim-puk (10), sim-pin2 (3), sim-puk2 (10)
           |                state: connected
           |          power state: on
           |          access tech: lte
           |       signal quality: 100% (recent)
  --------------------------------
  Modes    |            supported: allowed: 2g, 3g, 4g; preferred: none
           |              current: allowed: 2g, 3g, 4g; preferred: none
  --------------------------------
  IP       |            supported: ipv4, ipv6, ipv4v6
  --------------------------------
  3GPP     |                 imei: xxxxxxx
           |          operator id: 708001
           |        operator name: CLARO HND LTE Claro
           |         registration: home
           | packet service state: attached
  --------------------------------
  3GPP EPS | ue mode of operation: csps-2
  --------------------------------
  SIM      |     primary sim path: /org/freedesktop/ModemManager1/SIM/0
  --------------------------------
  Bearer   |                paths: /org/freedesktop/ModemManager1/Bearer/1

I tried to flash/update the firmware from the oldest to the newest (the newest one is from 2022… OLD!) and all the firmware does not respond to DHCP requests when I am using ECM mode and the commands to solve this problem do not work because they give me ERROR.

I tried these firmware:

  1. EM160RGLAUR02A04M4G (Do not respond to DHCP requests and also try factory reset old and new method)
  2. EM160RGLAUR02A05M4G (Do not respond to DHCP requests and also try factory reset old and new method)
  3. EM160RGLAUR02A07M4G (Do not respond to DHCP requests and also try factory reset old and new method)
  4. EM160RGLAUR02A07M4G_BETA0923 (Do not respond to DHCP requests and also try factory reset old and new method)
  5. EM160RGLAUR02A08M4G (Do not respond to DHCP requests and also try factory reset old and new method)
  6. EM160RGLAUR02A09M4G (Do not respond to DHCP requests and also try factory reset old and new method)
  7. EM160RGLAUR02A10M4G (Do not respond to DHCP requests and also try factory reset old and new method)
  8. EM160RGLAUR02A12M4GA (Do not respond to DHCP requests, I updated this latest firmware about 7 times and tried factory reset about 20 times with new and old method)

NEW


AT&F0
AT+CFUN=1,1

<big>I'm going to break the modem and you don't give me a solution to this problem.</big>

The AT commands below are the possible solution, but I can't use these commands because they give me ERROR and these commands were added in the new firmware versions in 2023 and <big>the EM160R-GL support for fixing bugs and adding new features via firmware updates was abandoned/dropped in 2022</big>.

[quote="jfrog, post:58, topic:20296"]
Ok, now

AT+QCFG=“ethernet”,0
AT+QCFG=“usbnet”,1
AT+QCFG=“nat”,0
at+qnetdevctl=1,3,1
at+cfun=1,1

Then check with `AT+QNETDEVSTATUS` and try DHCP (with the proper interface name).
Please do not use pictures to display textual information.

When the modem is back just run your DHCP client and see whether it will work without additional commands.

I just realised that I suggested the wrong sequence of commands in my earlier [post](https://forums.quectel.com/t/anyone-who-has-worked-with-rm500u-cn/20296/22).
Reset command should be used before `at+qnetdevctl`, not after and `at+qnetdevctl` should be issued after the modem is back after reset.
[/quote]


[quote="iamromulan, post:6, topic:29560, full:true"]
I would recommend ECM mode if you are using the RJ45 board by Ethernet. Seems to be pretty stable. Any other usbnet mode you need to make sure AT+QMAPWAC=1 or it won’t auto connect the radio to the rest of the interfaces. In ECM this just happens automatically.

AT+QCFG=“usbnet”,1
then reboot

For IP passthrough there’s 3 levels of IPPT

1. DMZ method (not a true IP passthrough)
Set the modems DHCP to only hand out one IP address with AT+QMAP=“LAN”,192.168.225.2
If that errors on you then you don’t have that command on that firmware revision so use this to define the whole dhcp range and gateway AT+QMAP=“LANIP”,192.168.225.2,192.168.225.2,192.168.225.1,1
Then, set that IP as the DMZ with

AT+QMAP=“DMZ”,1,4,192.168.225.2

2. Actual IPPT
AT+QMAP=“MPDN_rule”,0,1,0,1,1,“FF:FF:FF:FF:FF:FF”
If you want the DNS from the provider to pass through as well: AT+QMAP=“DHCPV4DNS”,“disable”
You should still be able to access 192.168.225.1 if you have a web server running on the modem still.
3. I haven’t messed too much with this yet because it disables local access to the gateway address (192.168.225.1) but it’s the final step to a true IPPT mode.
AT+QMAP=“IPPT_NAT”,0

First time I ran that I went…oh crap I can’t access my admin page any more! :rofl:
(I have a webserver running on the modem serving a management page that accepts AT commands and shows signal stats)

P.S. If you run AT+QMAP=“WWAN” it’ll show you both the IPV4 and IPV6 address assigned from the carrier.
[/quote]

<big>I hope you can help me to solve this problem somehow, it is not possible that you have abandoned a modem that costs more than 160 dollars and can not give me an official solution to this problem.</big>

Could you check the AT

AT+QENG=“servingcell”

AT+CPIN?

AT+CGREG?

AT+CEREG?

AT+CFUN?

Others had the same problem I have, but they solved it with the above commands that I can’t use because they give me ERROR.

AT+QCFG="usbnet"
+QCFG: "usbnet",1
OK

AT+QENG="servingcell"
+QENG: "servingcell","NOCONN","LTE","FDD",708,001,60F53F,480,950,2,3,3,3FDF,-84,-8,-58,16,36
OK

AT+CPIN?
+CPIN: READY
OK

AT+CGREG?
+CGREG: 0,0
OK

AT+CEREG?
+CEREG: 0,1
OK

AT+CFUN?
+CFUN: 1
OK

If you could share the screen of your PC or give me the remote access please mail to me: bean.wang@quectel.com

It only support MBIM and it does not support ECM.

Not all the modem and all the cellular firmware support ECM.
For customer, Quectel would rather recommend the customer to try RMNET/MBIM.

Your situation is not the same with theirs.

Do you just need the DHCP?

ECM mode is broken on EM160R-GL modem and it does not respond to DHCP requests, without a firmware update that fixes this issue or adds the commands or functions mentioned above, then you cannot use this mode, only the QMI and MBIM modes work at the moment.

Please @AnnaLiu can you report this to the person responsible for the firmware or the CEO, maybe he will fix the problem and then you can send me the fixed firmware if it is not too much trouble.

Thank you @Bean.Wang-Q for trying to help me with this problem, but without a firmware update it is not possible.

@AnnaLiu
The EM160R-GL do not support ECM mode. So the host cannot get the IP via DHCP.
I have tested it also. Even with the lastest firmware it is not supported.

@Niki.Liu-Q
I have check the issue via Teamviewer.
It is because the firmware do not support ECM. If the customer really want to fix it we have to provide another firmware for it.
For the later discussion, please check it with Anna.

1 Like

Please fix this issue on the EM160R-GL that cannot get IP via DHCP in ECM mode or add the possibility of using ECM mode on the EM160R-GL, I bought this modem because it is the best LTE-A modem on the market, but I never thought I would have this big problem that can only be solved by you through a firmware update.

This is the reason why I want ECM mode:

ECM mode does not need connection monitoring, because the modem itself will handle connection monitoring and automatic reconnects internally. This mode is a lot more like how your phone runs – the phone doesn’t need a separate app for connection monitoring and reconnection, because those functions are built directly into the part of the modem firmware that runs the core functions of the modem inside the phone chipset.

Connection monitoring is essentially a hack on top of the modem operating software that we have to implement, because for modems in the most commonly run modes (QMI and MBIM), all of the modem’s internal management of this part of the connection is bypassed. Running connection monitoring in ECM mode can actually interfere with it.

ECM tends to be more reliable by far. Any disconnects are normally resolved before you even detect them.

Using ECM you turn over all control of the connection to the modem. It just acts like another device on the Ethernet to the router and the modem is doing all the talking to the tower and it instantly knows if the connection is down because it is in constant communication with that network so it has first hand knowledge of the connection breaking.

The other protocols have to ask the modem about the connection in one way or another and then tell it to reconnect.

When it works ECM is probably the best protocol for use with a modem It is as fast as the others and it will automatically reconnect if need be.

In ECM mode the modem is responsible for keeping the connection up. This means that connections are essentially permanent.

I’ve been running my VoIP system with the EM06-E for years without connection monitoring, and without a single apparent disconnect.

@AnnaLiu @Niki.Liu-Q @herbert.pan-Q @Bean.Wang-Q @Great.Zheng-Q @Kerr.Yang-Q @Puck-Q @vincent.ding-Q @Stephen.Li-Q @silvia @AnnaLiu

@EM160R-GL
Are you there, could you show me the page that why you must try the ECM mode?

I also tried my em160r-gl on ecm mode, router cannot find the usb device. I used ecm mode on my em12, ep06 and rm520 and they are fine except for em160r.

Im using openwrt and cdc-ncm drivers for all modems on dhcp.

Ecm is the most stable mode and rarely disconnects so this issue should be fixed

The EM160R will not support the ECM feature. If the customer need the ECM, It is better to try another module.

I have EM160RGLAUR02A10M4G_01.001.01.001 version i cannot run it in QMI. Even if i use AT+QCFG=“usbnet”,0. It cannot function under qmi protocol.

Module only function under mbim protocol

Should i switch to another firmware like EM160RGLAUR02A12M4GA?

Please try the quectel-CM.