MobileGPS support...

General support for the Pi-Star System
Post Reply
G8OGJ
Posts: 64
Joined: Mon May 06, 2019 8:13 pm
Location: Matlock
Contact:

MobileGPS support...

Post by G8OGJ »

I'm running 4.1.2 on my mobile hotspot and I have hooked up a USB GPS receiver and enabled the feature. The GPS receiver appears as /dev/ttyUSB0 and so I have set that in the config along with 4800bps.

I know that this GPS receiver works because I have tried it previously using OpenCPN and I am sure that it was dishing out NMEA0183 sentences at 4800bps although I cannot be certain of the bit rate.

What I don't know is whether it is possible to monitor the output of the GPS receiver or whether pi-star gives any indication that it can see the thing now that the feature is enabled.

Also I saw somewhere that you have to set the location Lat/Long to 0.0/0.0 which I have done. I am presuming that the MobileGPS is not working because (and only because) Brandmeister self-care shows the location as 0.0/0.0. Is that a fair assumption?

Any guidance would be gratefully received.

Ian
Amateur Radio Station G8OGJ
AF6VN
Posts: 821
Joined: Fri Jul 20, 2018 1:15 am

Re: MobileGPS support...

Post by AF6VN »

The closest I've found on Google is

viewtopic.php?t=1724#p7637

which runs a shell script to read the GPS info and send it to some server.

Nothing I've read indicates that Pi-Star, as delivered, makes use of an external GPS -- even if it shows a configuration block for it.

--
AF6VN
Dennis L Bieber
G8OGJ
Posts: 64
Joined: Mon May 06, 2019 8:13 pm
Location: Matlock
Contact:

Re: MobileGPS support...

Post by G8OGJ »

I've managed to validate my GPS receivers using a (free, of course) tool called VisualGPSView (Windows).

One USB receiver was running at 38,400bps and the other was running at 4,800bps.

However, as suggested by a correspondent above setting the pi-star to the appropriate receiver port and baud-rate has not apparently fixed anything - Brandmeister self-care for the relevant hotspot shows Lat/Long as 0.0/0.0.

Any further thoughts gratefully received. If it is the case that this is not a complete feature in pi-star then I would vote for two auxilliary tools namely: a port-checker to see which port the gps is connected to; and an NMEA monitor to verify that the relevant NMEA0183 sentences are being seen (baud-rate checker in effect).

Ian
Amateur Radio Station G8OGJ
AF6VN
Posts: 821
Joined: Fri Jul 20, 2018 1:15 am

Re: MobileGPS support...

Post by AF6VN »

G8OGJ wrote: Thu Aug 27, 2020 5:10 pm Any further thoughts gratefully received. If it is the case that this is not a complete feature in pi-star then I would vote for two auxilliary tools namely: a port-checker to see which port the gps is connected to; and an NMEA monitor to verify that the relevant NMEA0183 sentences are being seen (baud-rate checker in effect).
If USB, determining the "port" is probably nothing more complicated than doing something like

ls /dev

before plugging in the device, and repeat after plugging it in, looking for differences. You could also try just plugging it in and then running "dmesg", looking for the last serial port registered. https://www.cyberciti.biz/faq/find-out- ... setserial/

I don't have one so I can't confirm, but that is the method many sites suggest for finding what "name" a hot-plug able device has been assigned (SD cards, USB flash drives, etc). And since the data stream is simple 8N1 text using <cr><lf> to terminate lines (though formally, NMEA specifies RS(EIA)-422 [balanced transmission line] a lot of stuff is simple RS(EIA)-232 compatible) any application that can open a serial port would suffice to confirm traffic. https://www.cyberciti.biz/tips/connect- ... nicom.html (that example is using a Linux desktop to connect to an embedded Linux board, but you'd be SSH to the R-Pi, and then run minicom on the R-Pi to connect to the serial port(s).

--
AF6VN
Dennis L Bieber
G8OGJ
Posts: 64
Joined: Mon May 06, 2019 8:13 pm
Location: Matlock
Contact:

Re: MobileGPS support...

Post by G8OGJ »

I'm familiar with lsusb and dmesg etc and I'm confident that I have set the port correctly on the linux device. The issue was (in the absence of a serial terminal packaged on the minimally configured RPi) how to verivy that the default baud rate output by the device was known - I did that through Windows but I am aware that if I had had a second linux machine around I could have done the same.

The issue with NMEA raised above is not relevant - NMEA0183 specifies an electrical interface (ie RS422 four-wire) and a set of messages. The messages are what is being referred to and I have validated that the two GPS receivers are both pumping out the relevant messages namely GGA, GLL, GNS, GSA and RMC and one of them also pumps out ROT and will provide a GNS message when relevant (satellife fault detection).

The issue being raised was how, and how to verify, pi-star uses that data when the service is enabled - for which I cannot find any documentation.

Ian
Amateur Radio Station G8OGJ
AF6VN
Posts: 821
Joined: Fri Jul 20, 2018 1:15 am

Re: MobileGPS support...

Post by AF6VN »

And you probably won't...

The ONLY link that showed a means of having dynamic updates to an APRS server required running a custom script which extracted position information and created a valid submission to the APRS server.

For anything else, Pi-Star appears to read the location once from config file /on startup/. It may have a config block for GPS, but no one has reported that it does anything with that configuration.

https://github.com/g4klx/MMDVMHost/issues/627 Newer -- but does Pi-Star include the version of MMDVMHost in question, and built with GPS support.

https://github.com/g4klx/MMDVMHost/issues/620 Has updated within the last hour, so this part quite certainly is NOT in a Pi-Star release. ("bold" is my emphasis, and I'll restate, that comment was posted within the last hour!)
As part of my changes to the APRS protocol, I've moved the GPSD handling into DMR Gateway and other changes. I have also added the ability for the DMR Gateway to report its position to APRS-IS in the same way as the YSF Gateway and others. If you get the SImpleDMR version of the DMR Gateway, and the SimpleDMR version of the MMDVM Host and try those, after making note of the configuration changes, it may do what you want it to do.
Going by https://github.com/AndyTaylorTweet/Pi-Star_Binaries MMDVMHOST and DMRGateway have not been updated in two years. Suspect these are v3.x since https://github.com/AndyTaylorTweet/Pi-S ... naries_Bin shows both updated two months ago (so still wouldn't have the update of the previous paragraph)

Even more... https://github.com/g4klx/MMDVMHost/comm ... 0d89a8d9bc indicates a major change in the GPS code took place after the Pi-Star updates (the name MobileGPS is out, gpsd is in)

--
AF6VN
Dennis L Bieber
WA1OKB
Posts: 14
Joined: Mon Mar 23, 2020 5:11 am

Re: MobileGPS support...

Post by WA1OKB »

Seems the best option might just be to install Direwolf in Pi-Star and have it read the GPS data from gpsd and send a position beacon to APRS
DD3XK
Posts: 1
Joined: Mon Jul 26, 2021 3:51 pm

Re: MobileGPS support...

Post by DD3XK »

Not for me. I'm using a dual-HAT-Hotspot with pistar 4.1.5 and there is no way to start the direwolf automaticly. Have tried many ways, but there is no chance. Seemed, that the pistor-image is such blocked, that there is no way neither crontab nor other ways.

Surching for in good idea to start direwolf with reboot, because I think, that Andy has not the disire to integrate in the normal pistar-configuration as the community wishes to have. :cry:
NQ4T
Posts: 51
Joined: Mon Aug 06, 2018 11:48 pm

Re: MobileGPS support...

Post by NQ4T »

AF6VN wrote: Wed Aug 26, 2020 10:09 pm The closest I've found on Google is

viewtopic.php?t=1724#p7637

which runs a shell script to read the GPS info and send it to some server.

Nothing I've read indicates that Pi-Star, as delivered, makes use of an external GPS -- even if it shows a configuration block for it.
It was sending it directly to APRS-IS. The idea was the script would scrape the TG/Reflector information from the hotspot, poll GPSD for the NEMA sentences, then scrape/format/extract the correct information from those NEMA sentences, blast it out to APRS-IS using NCAT. I did it because I was taking a very long road trip and wanted to update both my location and group information in real-time.

The downside is it was done around using another RPi with a GPS Hat that was actually built as a stratum-1 ntpd that was gps-sourced for off-grid time-sync. It was able to use "GPS Tether" apps on android...if you could actually find the IP address of your phone's hotspot network and make everything talk. It was never designed to be a plug-and-play solution...or at least it hadn't gotten to that. I never developed it much further and since I can't travel anymore....I instead took those ideas and implemented it in to another idea.

When I last looked at MobileGPS stuff a couple years ago...it was not geared toward real-time stuff. It seemed like it was more for getting the GPS information the hotspot itself reports to networks. It didn't look like it had a very fast poll time. I did dig around using what was already in there before trying to bolt things on.

If your hotspot doesn't move, then there's virtually no reason to have GPS on it. If your hotspot is mobile..then I think GPSD only updates when the device is booted. It's not going to keep track of where you are. If that's what you want...then you need to hack on your own stuff (or borrow my code and get it working....but I make no guarantees as it was written for older pi-star). I know for a fact the way it scrapes for TG information won't work anymore...since I have another project that does that for displaying on a webpage.
DD3XK wrote: Tue Sep 28, 2021 1:54 pm Seemed, that the pistor-image is such blocked, that there is no way neither crontab nor other ways.
This seems wrong...although I haven't dug around the latest pi-star to check. Blocking cron is usually bad mojo on systems. But...if there is some funky mojo that's preventing a user from doing it normally...it's done because the vast majority of users don't know the OS very well and Andy is trying to avoid lots of people asking for help on such things.
Post Reply