You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello I have forked your app to add mdns support because i needed it for my use case. This means you don't have to know the IP address of the gpsd UDP server as long as that UDP server is advertising a mDNS service discovery record with the service type _gpsd_.udp. and the service name equal to its hostname.
For example this is the avahi-daemon service unit XML file that I created on my server to advertise the GPSd service so the android app can discover it:
/etc/avahi/services/gpsd.service
<?xml version="1.0" standalone='no'?><!--*-nxml-*-->
<!DOCTYPE service-group SYSTEM "avahi-service.dtd">
<!-- See avahi.service(5) for more information about this configuration file -->
<service-group>
<!-- its important that we only include the %h here (hostname) because
the android app checks for this to match the hostname -->
<name replace-wildcards="yes">%h</name>
<service protocol="any">
<type>_gpsd._udp</type>
<port>4200</port>
</service>
</service-group>
ℹ️ INFO
I designed it like this (even tho it seemed wrong to me) because I wasn't able to figure out how to grab the machines hostname from the android NsdServiceManager. It looks like it only gives the service info, not the actual xyz.local domain names. So my hack was to make the service name equal to the domain name.
If you are interested in merging this contribution let me know and I might be willing to help you clean it up. Otherwise feel free to pull from my fork:
Sorry for the slow response, I've been busy and didn't check GitHub notifications.
Thanks, mDNS is a very nice to have feature. Unfortunately I don''t use it myself and wouldn't be interested in polishing up and testing the code to have it merged.
If you do clean it up and feel like it's good to be merged let me know; I'm happy to review a PR.
Hello I have forked your app to add mdns support because i needed it for my use case. This means you don't have to know the IP address of the gpsd UDP server as long as that UDP server is advertising a mDNS service discovery record with the service type
_gpsd_.udp.
and the service name equal to its hostname.For example this is the
avahi-daemon
service unit XML file that I created on my server to advertise the GPSd service so the android app can discover it:/etc/avahi/services/gpsd.service
If you are interested in merging this contribution let me know and I might be willing to help you clean it up. Otherwise feel free to pull from my fork:
ForestJohnson@fdc1598
The text was updated successfully, but these errors were encountered: