GithubHelp home page GithubHelp logo

kemenril / ir-aprsisd Goto Github PK

View Code? Open in Web Editor NEW
10.0 5.0 5.0 98 KB

Garmin/DeLorme inReach (or possibly other) KML feed to APRS-IS forwarding daemon

License: BSD 3-Clause "New" or "Revised" License

Python 100.00%

ir-aprsisd's Introduction

iR-APRSISD

Garmin/DeLorme inReach (or possibly other) KML feed to APRS-IS forwarding daemon

Hwaet!

This is a KML-feed to APRS-IS forwarding daemon. It was written for Garmin/DeLorme inReach devices, but might work elsewhere too. It polls a KML feed in which it expects to find a point in rougly the form that the inReach online feeds use, with attendant course, speed, and elevation data. It synthesizes an APRS position report for each point found there, complete with course, speed, and elevation data, and sends it to APRS-IS. If the packet came with an attached SMS message (this happens when you send a message to "mapshare" from your device), the text from that message is included in the APRS comment field.

This makes it possible to track an Iridium-based satellite device, say, on aprs.fi with all of the amateur radio stuff. All you need is a machine -- with the aprslib Python module installed -- attached to the internet to run the daemon, and a device that's publishing a KML feed.

Set up of Garmin Mapshare

In order to use this software, you must have a KML feed that gets location information from your device. Garmin can be told to publish it for you if you have an inReach. Roughly, the KML feed is available on the "social" tab of your Garmin account. You'll probably need to enable Mapshare. You can set a password or not. if you do set one, you will need to provide this password in the configuration file or on the command line to access your feed. Once it's turned on, you can click the "feed" link to see the feed URL and a few other things.

Set up of the forwarding daemon

First, download the files here to your Unix machine of choice. Just cloning the repository would do fine. You must have or be willing to get Python 3 and the Python aprslib. Most new enough installs will have Python 3. With luck, you may be able to install aprslib with something like:

pip3 install aprslib

... or:

pip install aprslib

Then do these things:

  • Edit the configuration file to contain your inReach username, your APRS SSID, and your APRS-IS passcode. Make any other changes you see fit.

  • Optionally, install the config file in /etc. You can otherwise leave it in the current directory.

  • Run the daemon. It should begin to scan your KML feed.

Note: I thought about just automatically calculating an APRS passcode rather than requiring it in the configuration, but this would be pretty catastrophic in case of typographical errors. If you don't already have the correct passcode, there is a command-line option, --genpass, that will calculate it for you. At least this way, the software will print the SSID for which you've asked it to generate a code back to you, and you're likely to notice if it's not actually yours. If it is yours, you can just cut and paste the code into the configuration. Hopefully this prevents me from encouraging people to use SSIDs which should be assigned to other stations. You can generate a passcode like this:

ir-aprsisd --genpass --ssid N0CALL-66

If you leave out the ssid option, a passcode will be generated for the SSID in the APRS section of the configuration file.

Multiple inReach devices

Support is now included for multiple inReach devices on the same feed. There are a few strategies for dealing with multiple devices. I do not have a way to test it on my own, but it has been tested and I'm told it works. I will do my best not to break it in an update. You can do any one of the following things:

  • Just define a single SSID in the configuration file, leave the Devices section undefined, and the software will increment the number on your SSID for each new IMEI it finds in the feed. Mappings generated this way will be consistent within a single run, but may -- or may not -- change if you run the service again.

  • Still define the SSID in the APRS section, since it's used for the APRS gate address and the login to APRS-IS, but also define the Devices section. Each line should have an SSID = IMEI mapping. All devices not present in the Devices section will be ignored.

  • Run multiple instances of the daemon, each with an IMEI specified on the command-line, or each with a new configuration file and a Devices section that includes some but not all of the devices you want to watch.

If you have multiple inReach devices, that should get them all tracking.

ir-aprsisd's People

Contributors

kemenril avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

ir-aprsisd's Issues

AttributeError: 'NoneType' object has no attribute 'groups'

Hello, I just performed a fresh install of Ubuntu on my VPS wanted to try our this iR to APRS. I initially started on 20.04 LTS and then 18.04 LTS. I get the same error on both attempts when running the daemon:

Traceback (most recent call last):
  File "./ir-aprsisd", line 118, in <module>
    (Call,SSNum) = re.search('(\w+)-(\d+)$',conf['APRS']['SSID']).groups()
AttributeError: 'NoneType' object has no attribute 'groups'

Was not sure was to what was causing this issue so figured I would start here.

Thanks for any help you can provide.

Script fails in the middle of running. Operating in Georgia.

`----------------Packet Forwarding Summary----------------
| 2021-07-29 07:43
| SSID DevID Packets forwarded
| EW1EM-12 0

----------------Packet Forwarding Summary----------------
| 2021-07-29 07:48
| SSID DevID Packets forwarded
| EW1EM-12 0

Traceback (most recent call last):
File "./ir-aprsisd", line 365, in
for packet in getEvents():
File "./ir-aprsisd", line 269, in getEvents
res = parsePlacemark(PM)
File "./ir-aprsisd", line 235, in parsePlacemark
elevation = float(elevation) * 3.2808399
ValueError: could not convert string to float: '-1.00 m from MSL'`

Not working

Hello,
unfortunately the script doesn't work.
However, no packages will be sent.
Can someone fix the script?
Greeting

Multiple inreach Devices

I ran across this on reddit. Thanks for it (and for sharing it).

I'm the user that said he had multiple devices. I am going to test them both out this weekend. I can provide the KML file to you if you'd like to see it - and then maybe we can tweak this to be able to handle multiple IMEI's in a KML file / mapshare url?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.