<div dir="auto"><div>I've seen this firmware bug before. AT&T uses the default eps bearer for Internet connectivity and the default setting in quectel's firmware is incorrect for most subscriptions.</div><div dir="auto"><br></div><div dir="auto">Setting the default bearer apn to an empty string before enabling the modem fixed this for me.<br><br><div class="gmail_quote" dir="auto"><div dir="ltr" class="gmail_attr">On Tue, Apr 23, 2024, 09:17 Filip Kubicz <<a href="mailto:filip.kubicz@tier.app">filip.kubicz@tier.app</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Bruce,<div><br>You can use ModemManager's API to set APN. ModemManager will do it using QMI protocol and there should be no need to send additional AT command unless you're doing something more custom not handled by ModemManager.<br><br></div><div>I've been using Quectel (EG/EC) modems over USB with ModemManager and as Enrico said there is no need to use Quectel's patched driver qmi_wwan_q. With newer Linux versions can use mainline qmi_wwan, as explained here: <a href="https://www.mail-archive.com/modemmanager-devel@lists.freedesktop.org/msg06298.html" target="_blank" rel="noreferrer">https://www.mail-archive.com/modemmanager-devel@lists.freedesktop.org/msg06298.html</a><br>You can just confirm that your modem PID/VID is included in the version of kernel that you use and this is going to work.<br><br>I'm sharing sample kernel output for reference, hope it helps. I think you need cdc-wdm0 device.<br><br>Jan 1 00:00:33 kernel: [ 33.548300] usb 1-1: new high-speed USB device number 2 using ci_hdrc<br>Jan 1 00:00:33 kernel: [ 33.781440] usb 1-1: New USB device found, idVendor=2c7c, idProduct=0121, bcdDevice= 3.18<br>Jan 1 00:00:33 kernel: [ 33.790457] usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3<br>Jan 1 00:00:33 kernel: [ 33.797992] usb 1-1: Product: EC21-EUX<br>Jan 1 00:00:33 kernel: [ 33.801795] usb 1-1: Manufacturer: Quectel<br>Jan 1 00:00:33 kernel: [ 33.805937] usb 1-1: SerialNumber: 0123456789ABCDEF<br>Jan 1 00:00:33 kernel: [ 33.870897] option 1-1:1.0: GSM modem (1-port) converter detected<br>Jan 1 00:00:33 kernel: [ 33.903985] usb 1-1: GSM modem (1-port) converter now attached to ttyUSB0<br>Jan 1 00:00:33 kernel: [ 33.956276] option 1-1:1.1: GSM modem (1-port) converter detected<br>Jan 1 00:00:33 kernel: [ 33.980366] usb 1-1: GSM modem (1-port) converter now attached to ttyUSB1<br>Jan 1 00:00:33 kernel: [ 33.998549] option 1-1:1.2: GSM modem (1-port) converter detected<br>Jan 1 00:00:34 kernel: [ 34.021000] usb 1-1: GSM modem (1-port) converter now attached to ttyUSB2<br>Jan 1 00:00:34 kernel: [ 34.052445] option 1-1:1.3: GSM modem (1-port) converter detected<br>Jan 1 00:00:34 kernel: [ 34.076217] usb 1-1: GSM modem (1-port) converter now attached to ttyUSB3<br>Jan 1 00:00:34 kernel: [ 34.144283] qmi_wwan 1-1:1.4: cdc-wdm0: USB WDM device<br>Jan 1 00:00:34 kernel: [ 34.177899] qmi_wwan 1-1:1.4 wwan0: register 'qmi_wwan' at usb-ci_hdrc.1-1, WWAN/QMI device, xx:xx:e9:ae:aa:11<br></div><div><br>And part of the mmcli -m 0 output:<br> System | device: /sys/devices/platform/soc/2100000.bus/2184200.usb/ci_hdrc.1/usb1/1-1<br> | drivers: qmi_wwan, option<br> | plugin: quectel<br> | primary port: cdc-wdm0<br> | ports: cdc-wdm0 (qmi), ttyUSB0 (qcdm), ttyUSB1 (ignored), <br> | ttyUSB2 (at), ttyUSB3 (ignored), wwan0 (net)<br></div><div><br>And then you will be able to set APN using ModemManager API: <a href="https://www.freedesktop.org/software/ModemManager/doc/latest/ModemManager/gdbus-org.freedesktop.ModemManager1.Modem.Simple.html" target="_blank" rel="noreferrer">https://www.freedesktop.org/software/ModemManager/doc/latest/ModemManager/gdbus-org.freedesktop.ModemManager1.Modem.Simple.html</a><br>You can pass the APN to Connect() function.<br>Or for testing you can use<br><pre style="color:rgb(0,0,0)">mmcli -m 0 --simple-connect="apn=your_apn"</pre></div><div>mmcli - more info here <a href="https://www.freedesktop.org/software/ModemManager/man/1.0.0/mmcli.8.html" target="_blank" rel="noreferrer">https://www.freedesktop.org/software/ModemManager/man/1.0.0/mmcli.8.html</a><br><br clear="all"><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><span style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px">Kind regards,</span><br style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px"><span style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px">Filip</span></div></div></div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Apr 22, 2024 at 11:12 AM Enrico Mioso <<a href="mailto:mrkiko.rs@gmail.com" target="_blank" rel="noreferrer">mrkiko.rs@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Fri, Apr 19, 2024 at 04:39:46PM +0000, Bruce Johnson wrote:<br>
> I have a question about using both QMI and the serial interface with ModemManager.<br>
> <br>
> I had little difficulty getting ModemManager's SimpleModem to connect to T-Mobile (USA) using a Quectel EG25-G, but we found that modem wasn't compatible with AT&T and/or a private APN used by one of our customers. We were advised to use the Quectel EC25, and after engaging both Quectel and AT&T, we were told that we need to insert the APN into the modem using an AT command, AT+CGDCONT=1,"IPV4V6","mcm.com.attz". I had to tweak the kernel config and the ModemManager build.<br>
> <br>
> Mods:<br>
> <br>
> * I built ModemManager 1.18.4 with --with-at-command-via-dbus.<br>
> * In the kernel config, I added USB Serial Converter support -> USB driver for GSM and CDMA modems.<br>
> <br>
> After I did this, the /dev/ttyUSB[1-4] files showed up, and I was able to issue AT commands using ModemManager, but while the modem would sort-of connect with SimpleModem's connect method -- I am getting a Bearer, and mmcli shows "connected" -- I receive no IP address information from the carrier. Port wwan0 is showing up as "ignored". (mmcli output below)<br>
> <br>
> The Quectel docs also said to patch the kernel a certain way to allow use of serial and the QMI_WWAN driver, but wwan0 is still ignored.<br>
> <br>
> Does anyone have any suggestions?<br>
> <br>
> Thanks!<br>
> <br>
> --<br>
> Bruce Johnson<br>
> Chantilly, Virginia<br>
> USA<br>
<br>
I will stand corrected in case - but...<br>
I don't think you need AT commands via d-bus to do this, but giving the APN via QMI somehow, depending on the object or method you use to connect.<br>
That said, you probably won't need qmi_wwan_q or whatever - the stock qmi_wwan driver from kernel, and "option" for serial should suffice.<br>
<br>
For some reason you have wwan0 (gnored) in your output which doesn't sound right. I would try to look at it/fix it first.<br>
<br>
Enrico<br>
<br>
<br>
<br>
> <br>
> <br>
> --------------------------------<br>
> General | path: /org/freedesktop/ModemManager1/Modem/0<br>
> | device id: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX<br>
> --------------------------------<br>
> Hardware | manufacturer: Quectel<br>
> | model: EC25<br>
> | firmware revision: EC25AFFAR07A14M4G<br>
> | supported: gsm-umts, lte<br>
> | current: gsm-umts, lte<br>
> | equipment id: 359401089771197<br>
> --------------------------------<br>
> System | device: /sys/devices/pci0000:00/0000:00:15.0/usb1/1-4<br>
> | drivers: option, qmi_wwan<br>
> | plugin: quectel<br>
> | primary port: ttyUSB3<br>
> | ports: ttyUSB2 (gps), ttyUSB3 (at), ttyUSB4 (at), wwan0 (ignored)<br>
> --------------------------------<br>
> Status | unlock retries: sim-pin (3), sim-puk (10), sim-pin2 (3), sim-puk2 (10)<br>
> | state: connected<br>
> | power state: on<br>
> | access tech: lte<br>
> | signal quality: 60% (recent)<br>
> --------------------------------<br>
> Modes | supported: allowed: 2g, 3g, 4g; preferred: none<br>
> | current: allowed: 2g, 3g, 4g; preferred: none<br>
> --------------------------------<br>
> IP | supported: ipv4, ipv6, ipv4v6<br>
> --------------------------------<br>
> 3GPP | imei: 3594010XXXXXXXX<br>
> | operator id: 310410<br>
> | operator name: AT&T<br>
> | registration: home<br>
> --------------------------------<br>
> 3GPP EPS | ue mode of operation: csps-2<br>
> --------------------------------<br>
> SIM | primary sim path: /org/freedesktop/ModemManager1/SIM/0<br>
> --------------------------------<br>
> Bearer | paths: /org/freedesktop/ModemManager1/Bearer/0<br>
> <br>
> <br>
</blockquote></div>
</blockquote></div></div></div>