Hey Gary!
Your help is allowing me to make some progress on this problem. Thanks!
> Does it send NMEA, by default, when you turn it on? Otherwise not
> gonna work with gpsd.
> > > > I can read data from this device using:
> > > > stty -F /dev/ttyXTRX0 speed 9600 && cat /dev/ttyXTRX0.
> > > You fail to note whehter that is as root, or a user.
> >
> > This command is being run as user.
> A user in the dialout group?
Yes, the user is in the dialout group.
sail@gr110:~/workarea/workarea/gr-fosphor/build$ groups
sail adm dialout cdrom sudo dip plugdev lxd wireshark
> What does the cat show you?
The cat seems to be showing me NMEA data. I know that the XTRX doesn't have satellite lock, but I'm more
concerned with gpsd being able to read from the device at the moment.
sail@gr110:~/workarea/workarea/gr-fosphor/build$ stty -F /dev/ttyXTRX0 speed 9600 && cat /dev/ttyXTRX0
9600
�$PMTK011,MTKGPS*08
$PMTK010,001*2E
$PMTK011,MTKGPS*08
$PMTK010,002*2D
$PMTK011,MTKGPS$PMTK001,10,1*03
$PMTK011,MTKGPS$PMTK001,10,1*03
$GNGGA,235942.870,,,,,0,0,,,M,,M,,*52
$GPGSA,A,1,,,,,,,,,,,,,,,*1E
$GLGSA,A,1,,,,,,,,,,,,,,,*02
$GPGSV,1,1,00*79
> You gotta make a choice, are you going to run gpsd under systemd(umber),
> or not. You can not do both.
I found the systemd services that gpsd used with this command:
sail@gr110:~/workarea/workarea/gr-fosphor/build$ systemctl list-unit-files | grep gpsd
gpsd.service disabled enabled
gpsdctl@.service static enabled
gpsd.socket disabled enabled
Then for each service I made sure to run disable and stop by running these commands as root:
$ systemctl stop gpsd.service
$ systemctl disable gpsd.service
$ systemctl stop gpsd.socket
$ systemctl disable gpsd.socket
After disabling the services systemd was running, port 2947 cleared up, and I no longer got an error
about port 2947 being in use.
> Try this, as root:
> lsof /dev/ttyXRX0
root@gr110:/home/sail/workarea/workarea/gr-fosphor/build# lsof /dev/ttyXTRX0
lsof: WARNING: can't stat() fuse file system /run/user/1000/doc
Output information may be incomplete.
> Run gpsd as root, or do not bother. Running as not root breaks things
> that you are not prepared to deal with.
Will do. This is the output. Same permission error as before.
root@gr110:/home/sail/workarea/icmtgui-dev# gpsd -n -N /dev/ttyXTRX0
gpsd:ERROR: SER: device open of /dev/ttyXTRX0 failed: Permission denied - retrying read-only
gpsd:ERROR: SER: read-only device open of /dev/ttyXTRX0 failed: Permission denied
gpsd:ERROR: initial GPS device /dev/ttyXTRX0 open failed
gpsd:ERROR: can't run with neither control socket nor devices open
root@gr110:/home/sail/workarea/icmtgui-dev# gpsd -n -N -D5 /dev/ttyXTRX0
gpsd:INFO: launching (Version 3.20)
gpsd:IO: opening IPv4 socket
gpsd:IO: opening IPv6 socket
gpsd:INFO: listening on port gpsd
gpsd:PROG: NTP: shmat(32778,0,0) succeeded, segment 0
gpsd:PROG: NTP: shmat(32779,0,0) succeeded, segment 1
gpsd:PROG: NTP: shmat(32780,0,0) succeeded, segment 2
gpsd:PROG: NTP: shmat(32781,0,0) succeeded, segment 3
gpsd:PROG: NTP: shmat(32782,0,0) succeeded, segment 4
gpsd:PROG: NTP: shmat(32783,0,0) succeeded, segment 5
gpsd:PROG: NTP: shmat(32785,0,0) succeeded, segment 6
gpsd:PROG: NTP: shmat(32786,0,0) succeeded, segment 7
gpsd:PROG: successfully connected to the DBUS system bus
gpsd:PROG: shmget(0x47505344, 24024, 0666) for SHM export succeeded
gpsd:PROG: shmat() for SHM export succeeded, segment 32788
gpsd:INFO: stashing device /dev/ttyXTRX0 at slot 0
gpsd:PROG: no /etc/gpsd/device-hook present, skipped running ACTIVATE hook
gpsd:INFO: SER: opening GPS data source type 2 at '/dev/ttyXTRX0'
gpsd:ERROR: SER: device open of /dev/ttyXTRX0 failed: Permission denied - retrying read-only
gpsd:ERROR: SER: read-only device open of /dev/ttyXTRX0 failed: Permission denied
gpsd:ERROR: initial GPS device /dev/ttyXTRX0 open failed
gpsd:ERROR: can't run with neither control socket nor devices open
> Fun, another stingray clone?
Yeah, that's the idea of the project. The idea is to do the RF side of things with a software based radio
we can listen to any frequency and perform different demodulations. In this way we hope to be able to
detect and identify as much as possible with just an XTRX and a second radio that goes up to 6GHz.
Thanks for your time again Gary.
-Bradley