MC7700 no GPS with modem manager

I’m trying to make an IoT device using armbian that needs lte connectivity and GPS tracking, as I’m quite inexperienced in the subject I figured I would use modem manager. With modem manager I can use lte without problems but i can’t get gps data because it thinks that the module isn’t compatible.

root@orangepi:/# mmcli -m 0 --location-status

/org/freedesktop/ModemManager1/Modem/0
  ----------------------------
  Location |   capabilities: '3gpp-lac-ci'
           |        enabled: '3gpp-lac-ci'
           |        signals: 'no'

I have already used the gps in the module with at commands but modem manager blocks the tty so i need another way.

I’m not fixed in using modem manager, if you recommend another way that’s somewhat easy to implement I’m happy to try it.

Thank you for your help

Maybe you can try the linux QMI SDK to control the GPS functionality.

@edfarrera,

So this is a MC7700, I would probably keep it simple and stick with mm, using QMI would entail a load of work and the unit is soo old now there are no guarantees that it would work with the current SDK.

So what error is the mmcli throwing at you when you specify the modem? Does the modem have the right port assigned to it in the system for the NMEA?

Regards

Matt

1 Like

@mlw

I don’t see any errors when using the mmcli commands. Are you talking about a command in specific?

How do I check if the system has the right port for NMEA?

Thanks for your help

@mlw

Here is some info if that helps

root@orangepi:~# mmcli -L

Found 1 modems:
	/org/freedesktop/ModemManager1/Modem/0 [Sierra Wireless, Incorporated] MC7700

root@orangepi:~# mmcli -m 0

/org/freedesktop/ModemManager1/Modem/0 (device id '3ff5dfc2b5e2d3df28f56f4df05cd3cb0e7208b1')
  -------------------------
  Hardware |   manufacturer: 'Sierra Wireless, Incorporated'
           |          model: 'MC7700'
           |       revision: 'SWI9200X_03.05.10.02AP R4684 CARMD-EN-10527 2012/02/25 11:58:38'
           |      supported: 'gsm-umts, lte'
           |        current: 'gsm-umts, lte'
           |   equipment id: '012626001074846'
  -------------------------
  System   |         device: '/sys/devices/platform/fe380000.usb/usb5/5-1'
           |        drivers: 'sierra, sierra_net'
           |         plugin: 'Sierra (legacy)'
           |   primary port: 'ttyUSB3'
           |          ports: 'ttyUSB3 (at), wwan0 (net), ttyUSB4 (at)'
  -------------------------
  Numbers  |           own : 'unknown'
  -------------------------
  Status   |           lock: 'none'
           | unlock retries: 'sim-pin (3), sim-pin2 (0), sim-puk (10), sim-puk2 (10)'
           |          state: 'connected'
           |    power state: 'on'
           |    access tech: 'umts'
           | signal quality: '20' (recent)
  -------------------------
  Modes    |      supported: 'allowed: 2g; preferred: none
           |                  allowed: 3g; preferred: none
           |                  allowed: 2g, 3g; preferred: none
           |                  allowed: 4g; preferred: none
           |                  allowed: 2g, 3g, 4g; preferred: none'
           |        current: 'allowed: 2g, 3g, 4g; preferred: none'
  -------------------------
  Bands    |      supported: 'unknown'
           |        current: 'unknown'
  -------------------------
  IP       |      supported: 'ipv4, ipv6, ipv4v6'
  -------------------------
  3GPP     |           imei: '012626001074846'
           |  enabled locks: 'none'
           |    operator id: '33403'
           |  operator name: 'Movistar'
           |   subscription: 'unknown'
           |   registration: 'home'
  -------------------------
  SIM      |           path: '/org/freedesktop/ModemManager1/SIM/0'

  -------------------------
  Bearers  |          paths: '/org/freedesktop/ModemManager1/Bearer/0'

@jyijyi
I think it doesn’t support qmi

at!udusbcomp=?
0 - HIP  DM    NMEA  AT    MDM1  MDM2  MDM3  MS  SUPPORTED
1 - HIP  DM    NMEA  AT    MDM1  MS              NOT SUPPORTED
2 - HIP  DM    NMEA  AT    NIC1  MS              SUPPORTED
3 - HIP  DM    NMEA  AT    MDM1  NIC1  MS        SUPPORTED
4 - HIP  DM    NMEA  AT    NIC1  NIC2  NIC3  MS  SUPPORTED
5 - HIP  DM    NMEA  AT    ECM1  MS              SUPPORTED
6 - DM   NMEA  AT    QMI                         NOT SUPPORTED
7 - DM   NMEA  AT    RMNET1 RMNET2 RMNET3        NOT SUPPORTED
8 - Win8 Std Net                                 NOT SUPPORTED

at!udusbcomp?
!UDUSBCOMP: 3

Accord to sdk release note, you need to set
At!udpid=68A2
Ar!reset

The “sierra legacy” plugin in ModemManager (the one used when the module is in Direct IP mode) doesn’t support GPS location, it’s just not developed yet. If you switch the module to QMI, you’ll be able to use the built-in GPS management from the QMI PDS service, and that should work as expected.

If you still want to stick using DirectIP and ModemManager, you can always tell MM to ignore the specific TTY in charge of the GPS (with ID_MM_PORT_IGNORE udev rules) and then you would be able to manage the GPS yourself without MM interfering.

Also, please note that you cannot just “switch” the MC7700 modem running in DirectIP mode (like yours) into QMI mode by using AT commands. You need to fully upgrade to a QMI capable firmware instead. The Sierra website publishes both QMI and DIP (DirectIP) firmware versions:
https://source.sierrawireless.com/resources/airprime/software/mc7700-firmware-package-history/

If you have a recent enough libqmi, you could also use qmi-firmware-update to perform the upgrade; run “qmi-firmware-update --help-examples” and look for the MC7700 example.

Thank you for your help, I managed to ignore the port like you suggested by creating a file in /etc/udev/rules.d/ with the name 50-at.rules with the following content:

ATTRS{idVendor}=="1199", ATTRS{idProduct}=="68a3", SUBSYSTEM=="tty", KERNEL=="ttyUSB2", ENV{ID_MM_PORT_IGNORE}="1"

This makes MM ignore the NMEA port but for some reason I don’t get anything in that port with the default driver.

Sadly changing the firmware is not an option for me because I have to many units and I think that would be a lot of work (unless there is an automatic way of doing so).

One thing that kinda worked was using the command at!udpid=68A2 to switch the modem to QMI mode (but like you said this doesn’t make QMI work) with this the device was grabbed with the GobiSerial drivers instead of the sierra drivers and now I can get the GPS data through the NMEA port and use Modem Manager, but this option makes a ppp0 connection instead of a wwan0. If i understand correctly the wwan0 is faster so I would prefer that one.