gpsd issues
#1
Hi everyone,

I am trying for a while now to get gps running. I went through the wiki page (https://wiki.mobian-project.org/doku.php?id=location), multiple times (also with at least one clean install of mobian) but run into some issues - I cannot find this mentioned anywhere.

What I did: I follow the steps and did manage to get some meaningful output from

Code:
mmcli -m 0 --location-enable-gps-nmea

(with the right modem number)

But the moment I move on to setup gpsd, I get no signal at all. I started gpsd, then run

Code:
gpspipe --nmea

The first time, the inital output looks normal, it recognizes ttyUSB1 and waits for a signal. A signal never comes, even leaving it for 8 hours at a window. No output at all. When I checked dmesg, I find this:


Code:
[17010.473495] usb 2-1: USB disconnect, device number 2
[17010.482390] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
[17010.491396] option 2-1:1.0: device disconnected
[17010.507679] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
[17010.516152] option 2-1:1.1: device disconnected
[17010.525462] option1 ttyUSB2: GSM modem (1-port) converter now disconnected from ttyUSB2
[17010.533818] option 2-1:1.2: device disconnected
[17010.547007] option1 ttyUSB3: GSM modem (1-port) converter now disconnected from ttyUSB3
[17010.555419] option 2-1:1.3: device disconnected
[17010.581592] qmi_wwan 2-1:1.4 wwan0: unregister 'qmi_wwan' usb-1c1b000.usb-1, WWAN/QMI devic
[17010.913371] usb 2-1: new high-speed USB device number 3 using ehci-platform
[17011.089623] usb 2-1: New USB device found, idVendor=2c7c, idProduct=0125, bcdDevice= 3.18
[17011.097896] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[17011.105096] usb 2-1: Product: EG25-G
[17011.108780] usb 2-1: Manufacturer: Quectel
[17011.121451] option 2-1:1.0: GSM modem (1-port) converter detected
[17011.132864] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB0
[17011.144117] option 2-1:1.1: GSM modem (1-port) converter detected
[17011.154905] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB2
[17011.170701] option 2-1:1.2: GSM modem (1-port) converter detected
[17011.182066] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB3
[17011.194272] option 2-1:1.3: GSM modem (1-port) converter detected
[17011.206092] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB4

So the modem disconnects and reconnects, but it loses ttyUSB1 and I assume moves it to ttyUSB2. /dev/ttyUSB1 does not exist anymore and gpsd is listening to nothing, as /etc/default/gpsd is sets devices to ttyUSB1. At least that's what I think the problem is.

I did not find anything on the forum or wiki about this so far, anyone has an idea?

Thanks!
  Reply
#2
The modem presents multiple USB ports with different uses. IIRC ttyUSB1 is NMEA output only, while ttyUSB2 is used for the AT commands that control it. Some modem failure modes cause one or more of the USB ports to disappear until the modem is restarted. You don't mention whether you're checking the NMEA output to see if it's getting a fix before you start gpsd. I don't know if the AGPS is now handled automatically or whether you'll need to do that manually, but without it you need a clear sky view, patience and luck to get a fix at all. Some people have trouble getting a fix even with the AGPS working. I don't remember what I did to get gpsd working while ModemManager was running - I'll see if I can find anything in my notes.
  Reply
#3
I'm having a similar problem. "sudo watch -n 5 mmcli -m any --location-get" produces a valid report with correct location data
but Foxtrotgps says "No GPS found" and cgps prints a screen full of "n/a".
  Reply
#4
How are you enabling the gps, and how are you configuring and starting gpsd?
  Reply
#5
>How are you enabling the gps,

How should I enable it?

>how are you configuring and starting gpsd?

ps and systemctl tell me it's running. I've made no configuration changes other than experimenting with replacing the line

DEVICES=""

in /etc/default/gpsd with

DEVICES="/dev/ttyUSB1"

and restarting gpsd via systemctl. Made no difference and I changed it back.
  Reply
#6
From memory you need to use mmcli's --location-enable-gps-unmanaged option when enabling the GPS, and make sure other gps access methods aren't enabled, otherwise ModemManager will connect to the USB port and prevent gpsd using it. Check the mmcli man page for details. It should be possible to automate this using the /etc/gpsd/device-hook scripting, so that unmanaged location is started when a gpsd client connects, and stopped when the last client disconnects, but I never got around to trying it. I think PmOS was using that hook to load AGPS data at start too. I can't test at the moment as I don't have a SIM in, and ModemManager still won't let you access the location without it even though the modem itself is capable of doing it.
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Modem Firmware Upgrade - Modem Busy - USB Issues biketool 10 6,291 09-23-2022, 05:15 AM
Last Post: biketool
  Lot of issues after flashing mobian to emmc with tow-boot benedikt55 5 3,554 08-30-2022, 01:14 PM
Last Post: benedikt55
  Issues with Mobian? Start here. tophneal 0 6,255 04-21-2022, 11:27 AM
Last Post: tophneal
  Anyone find a work around for the brightness issues from kernels 5.13/14? ragreenburg 2 2,787 09-01-2021, 08:49 AM
Last Post: ragreenburg
  Remote desktop, video playback issues Zebulon Walton 13 12,825 06-17-2021, 06:57 AM
Last Post: aus
  Always-On VPN issues at boot. Need to manually activate it.. What did i miss.. temp0rary 0 1,568 05-31-2021, 10:35 AM
Last Post: temp0rary
  Issues with Mobian 20210314 (data and updates) IMSAI8080 5 6,980 03-20-2021, 04:14 AM
Last Post: IMSAI8080
  Mobian Issues Csanderson0313 13 14,091 03-02-2021, 04:57 AM
Last Post: Gribouille

Forum Jump:


Users browsing this thread: 1 Guest(s)