Trying to get WG1602 LTE modem Fibocom NL668 working in Openwrt

I'm not able to get the assigned IP address from my WG1602 Fibocom NL668 4G modem to the Openwrt interface.

It seems to connect to the 4G network ok, and I can verify the modem has been given its IP address etc. The interface never sets it. Here is my current config.

EDIT: Resolved in reply, may also be helptul for the WG1608 also with this modem.

config interface 'LTE'
        option device '/dev/ttyUSB1'
        option proto 'ncm'
        option apn '3internet'
        option mode 'lte'
        option pdptype 'IP'
        option metric '40'
        option delegate '0'
        option debug '1'
        option ipv6 'auto'

/etc/gcom/ncm.json

{
  "fibocom": {
    "initialize": [
      "AT",
      "ATZ",
      "ATQ0",
      "ATV1",
      "ATE1",
      "ATS0=0",
      // Define PDP context #${profile}, e.g. 1
      //   ${pdptype} is typically "IP" or "IPV4V6"
      //   ${apn} would be your APN string, e.g. "internet"
    ],

    "modes": {
      // For Huawei we had e.g. AT^SYSCFGEX=...
      // On Fibocom, you can set RAT with AT+GTRAT:
      //   0 = GSM only
      //   2 = UMTS only
      //   3 = LTE only
      //   6 = LTE/UMTS/GSM  (triple-mode)
      //   10 = Automatic
      "preferlte":  "AT+GTRAT=3",   // LTE-only
      "preferumts": "AT+GTRAT=2",   // UMTS-only
      "lte":        "AT+GTRAT=3",   // Force LTE
      "umts":       "AT+GTRAT=2",   // Force 3G
      "gsm":        "AT+GTRAT=0",   // 2G only
      "auto":       "AT+GTRAT=6"    // All RATs (LTE/UMTS/GSM)
    },
    "configure": [
       "AT+GTRAT=3",
       "AT+CGDCONT=${profile},\\\"${pdptype}\\\"${apn:+,\\\"$apn\\\"}",
       "AT+CGATT=1",
    ],
    "connect": "AT+CGACT=${profile}",
    "disconnect": "AT+CGACT=0,${profile}"
    }
}

If I do, I will get example below, so I can see the IP has been assigned to the modem.

picocom -b 115200 /dev/ttyUSB1

AT+CGCONTRDP=1
+CGCONTRDP: 1,5,"3internet","138.23.212.18",,"138.21.212.128","138.23.212.129"

And here is my interface log

Thu Jan 23 22:00:52 2025 daemon.notice netifd: LTE (15131): sending -> AT
Thu Jan 23 22:00:52 2025 daemon.notice netifd: LTE (15131): sending -> ATZ
Thu Jan 23 22:00:53 2025 daemon.notice netifd: LTE (15131): sending -> ATQ0
Thu Jan 23 22:00:53 2025 daemon.notice netifd: LTE (15131): sending -> ATV1
Thu Jan 23 22:00:54 2025 daemon.notice netifd: LTE (15131): sending -> ATE1
Thu Jan 23 22:00:55 2025 daemon.notice netifd: LTE (15131): sending -> ATS0=0
Thu Jan 23 22:00:55 2025 daemon.notice netifd: LTE (15131): Configuring modem
Thu Jan 23 22:00:55 2025 daemon.notice netifd: LTE (15131): sending -> AT+GTRAT=3
Thu Jan 23 22:00:56 2025 daemon.notice netifd: LTE (15131): sending -> AT+CGDCONT=1,"IP","3internet"
Thu Jan 23 22:00:57 2025 daemon.notice netifd: LTE (15131): sending -> AT+CGATT=1
Thu Jan 23 22:00:57 2025 daemon.notice netifd: LTE (15131): Setting mode
Thu Jan 23 22:00:58 2025 daemon.notice netifd: LTE (15131): sending -> AT+GTRAT=3
Thu Jan 23 22:00:58 2025 daemon.notice netifd: LTE (15131): Starting network LTE
Thu Jan 23 22:00:58 2025 daemon.notice netifd: LTE (15131): Connecting modem
Thu Jan 23 22:00:59 2025 daemon.notice netifd: LTE (15131): sending -> AT+CGACT=1
Thu Jan 23 22:00:59 2025 daemon.notice netifd: LTE (15131): Setting up wwan0
Thu Jan 23 22:00:59 2025 daemon.notice netifd: Interface 'LTE' is now up
Thu Jan 23 22:00:59 2025 daemon.notice netifd: Network device 'wwan0' link is up
Thu Jan 23 22:00:59 2025 daemon.notice netifd: Network alias 'wwan0' link is up
Thu Jan 23 22:00:59 2025 daemon.notice netifd: Interface 'LTE_4' is enabled
Thu Jan 23 22:00:59 2025 daemon.notice netifd: Interface 'LTE_4' has link connectivity
Thu Jan 23 22:00:59 2025 daemon.notice netifd: Interface 'LTE_4' is setting up now
Thu Jan 23 22:00:59 2025 daemon.notice netifd: LTE_4 (15396): udhcpc: started, v1.36.1
Thu Jan 23 22:00:59 2025 user.notice firewall: Reloading firewall due to ifup of LTE (wwan0)
Thu Jan 23 22:00:59 2025 daemon.notice netifd: LTE_4 (15396): udhcpc: broadcasting discover
Thu Jan 23 22:01:00 2025 daemon.warn odhcpd[2258]: No default route present, overriding ra_lifetime!
Thu Jan 23 22:01:03 2025 daemon.notice netifd: LTE_4 (15396): udhcpc: broadcasting discover
Thu Jan 23 22:01:06 2025 daemon.notice netifd: LTE_4 (15396): udhcpc: broadcasting discover

OK that was easier than I thought.
I instead used QMI which resolved it all !

opkg install kmod-usb-net-qmi-wwan kmod-usb-wdm uqmi nano

/etc/config/network

config interface 'LTE'
    option proto 'qmi'
    option device '/dev/cdc-wdm0'
    option apn '3internet'
    option pdptype 'IP'
    option auth 'none'
    option ipv6 'auto'
    option delegate '0'
    option metric '40'

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.