APRSD is a Ham radio APRS message command gateway built on python.
APRSD listens on amateur radio aprs-is network for messages and respond to them. It has a plugin architecture for extensibility. Users of APRSD can write their own plugins that can respond to APRS-IS messages.
You must have an amateur radio callsign to use this software. APRSD gets messages for the configured HAM callsign, and sends those messages to a list of plugins for processing. There are a set of core plugins that provide responding to messages to check email, get location, ping, time of day, get weather, and fortune telling as well as version information of aprsd itself.
Please read the docs to learn more!
- APRSD Overview Diagram
- Typical use case
- Current list of built-in plugins
- Installation
- Example usage
- Help
- Commands
- Configuration
- server
- send-message
- SEND EMAIL (radio to smtp server)
- RECEIVE EMAIL (imap server to radio)
- LOCATION
- Development
- Workflow
- Release
- Docker Container
- Building
- Official Build
- Development Build
- Running the container
Ham radio operator using an APRS enabled HAM radio sends a message to check the weather. An APRS message is sent, and then picked up by APRSD. The APRS packet is decoded, and the message is sent through the list of plugins for processing. For example, the WeatherPlugin picks up the message, fetches the weather for the area around the user who sent the request, and then responds with the weather conditions in that area. Also includes a watch list of HAM callsigns to look out for. The watch list can notify you when a HAM callsign in the list is seen and now available to message on the APRS network.
ββ> aprsd list-plugins π APRSD Built-in Plugins π βββββββββββββββββββββ³βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ³βββββββββββββββ³ββββββββββββββββββββββββββββββββββββββββββ β Plugin Name β Info β Type β Plugin Path β β‘ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ© β AVWXWeatherPlugin β AVWX weather of GPS Beacon location β RegexCommand β aprsd.plugins.weather.AVWXWeatherPlugin β β EmailPlugin β Send and Receive email β RegexCommand β aprsd.plugins.email.EmailPlugin β β FortunePlugin β Give me a fortune β RegexCommand β aprsd.plugins.fortune.FortunePlugin β β LocationPlugin β Where in the world is a CALLSIGN's last GPS beacon? β RegexCommand β aprsd.plugins.location.LocationPlugin β β NotifySeenPlugin β Notify me when a CALLSIGN is recently seen on APRS-IS β WatchList β aprsd.plugins.notify.NotifySeenPlugin β β OWMWeatherPlugin β OpenWeatherMap weather of GPS Beacon location β RegexCommand β aprsd.plugins.weather.OWMWeatherPlugin β β PingPlugin β reply with a Pong! β RegexCommand β aprsd.plugins.ping.PingPlugin β β QueryPlugin β APRSD Owner command to query messages in the MsgTrack β RegexCommand β aprsd.plugins.query.QueryPlugin β β TimeOWMPlugin β Current time of GPS beacon's timezone. Uses OpenWeatherMap β RegexCommand β aprsd.plugins.time.TimeOWMPlugin β β TimePlugin β What is the current local time. β RegexCommand β aprsd.plugins.time.TimePlugin β β USMetarPlugin β USA only METAR of GPS Beacon location β RegexCommand β aprsd.plugins.weather.USMetarPlugin β β USWeatherPlugin β Provide USA only weather of GPS Beacon location β RegexCommand β aprsd.plugins.weather.USWeatherPlugin β β VersionPlugin β What is the APRSD Version β RegexCommand β aprsd.plugins.version.VersionPlugin β βββββββββββββββββββββ΄βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ΄βββββββββββββββ΄ββββββββββββββββββββββββββββββββββββββββββ Pypi.org APRSD Installable Plugin Packages Install any of the following plugins with 'pip install <Plugin Package Name>' ββββββββββββββββββββββββββββββββ³βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ³ββββββββββ³βββββββββββββββ³βββββββββββββ β Plugin Package Name β Description β Version β Released β Installed? β β‘ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ© β π aprsd-stock-plugin β Ham Radio APRSD Plugin for fetching stock quotes β 0.1.3 β Dec 2, 2022 β No β β π aprsd-sentry-plugin β Ham radio APRSD plugin that does.... β 0.1.2 β Dec 2, 2022 β No β β π aprsd-timeopencage-plugin β APRSD plugin for fetching time based on GPS location β 0.1.0 β Dec 2, 2022 β No β β π aprsd-weewx-plugin β HAM Radio APRSD that reports weather from a weewx weather station. β 0.1.4 β Dec 7, 2021 β Yes β β π aprsd-repeat-plugins β APRSD Plugins for the REPEAT service β 1.0.12 β Dec 2, 2022 β No β β π aprsd-telegram-plugin β Ham Radio APRS APRSD plugin for Telegram IM service β 0.1.3 β Dec 2, 2022 β No β β π aprsd-twitter-plugin β Python APRSD plugin to send tweets β 0.3.0 β Dec 7, 2021 β No β β π aprsd-slack-plugin β Amateur radio APRS daemon which listens for messages and responds β 1.0.5 β Dec 18, 2022 β No β ββββββββββββββββββββββββββββββββ΄βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ΄ββββββββββ΄βββββββββββββββ΄βββββββββββββ π APRSD Installed 3rd party Plugins π ββββββββββββββββββββββ³ββββββββββββββββββ³ββββββββββ³βββββββββββββββ³βββββββββββββββββββββββββββββββββββββββββββ β Package Name β Plugin Name β Version β Type β Plugin Path β β‘βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ© β aprsd-weewx-plugin β WeewxMQTTPlugin β 1.0 β RegexCommand β aprsd_weewx_plugin.weewx.WeewxMQTTPlugin β ββββββββββββββββββββββ΄ββββββββββββββββββ΄ββββββββββ΄βββββββββββββββ΄βββββββββββββββββββββββββββββββββββββββββββ
To install aprsd
, use Pip:
pip install aprsd
aprsd -h
ββ> aprsd -h Usage: aprsd [OPTIONS] COMMAND [ARGS]... Options: --version Show the version and exit. -h, --help Show this message and exit. Commands: check-version Check this version against the latest in pypi.org. completion Click Completion subcommands dev Development type subcommands healthcheck Check the health of the running aprsd server. list-plugins List the built in plugins available to APRSD. listen Listen to packets on the APRS-IS Network based on FILTER. sample-config Generate a sample Config file from aprsd and all... send-message Send a message to a callsign via APRS_IS. server Start the aprsd server gateway process. version Show the APRSD version. webchat Web based HAM Radio chat program!
This command outputs a sample config yml formatted block that you can edit
and use to pass in to aprsd
with -c
. By default aprsd looks in ~/.config/aprsd/aprsd.yml
aprsd sample-config
ββ> aprsd sample-config ...
This is the main server command that will listen to APRS-IS servers and look for incomming commands to the callsign configured in the config file
ββ[$] > aprsd server --help Usage: aprsd server [OPTIONS] Start the aprsd server gateway process. Options: --loglevel [CRITICAL|ERROR|WARNING|INFO|DEBUG] The log level to use for aprsd.log [default: INFO] -c, --config TEXT The aprsd config file to use for options. [default: /Users/i530566/.config/aprsd/aprsd.yml] --quiet Don't log to stdout -f, --flush Flush out all old aged messages on disk. [default: False] -h, --help Show this message and exit. ββ> aprsd server Load config 12/07/2021 03:16:17 PM MainThread INFO APRSD is up to date server.py:51 12/07/2021 03:16:17 PM MainThread INFO APRSD Started version: 2.5.6 server.py:52 12/07/2021 03:16:17 PM MainThread INFO Using CONFIG values: server.py:55 12/07/2021 03:16:17 PM MainThread INFO ham.callsign = WB4BOR server.py:60 12/07/2021 03:16:17 PM MainThread INFO aprs.login = WB4BOR-12 server.py:60 12/07/2021 03:16:17 PM MainThread INFO aprs.password = XXXXXXXXXXXXXXXXXXX server.py:58 12/07/2021 03:16:17 PM MainThread INFO aprs.host = noam.aprs2.net server.py:60 12/07/2021 03:16:17 PM MainThread INFO aprs.port = 14580 server.py:60 12/07/2021 03:16:17 PM MainThread INFO aprs.logfile = /tmp/aprsd.log server.py:60
This command is typically used for development to send another aprsd instance test messages
ββ[$] > aprsd send-message -h Usage: aprsd send-message [OPTIONS] TOCALLSIGN COMMAND... Send a message to a callsign via APRS_IS. Options: --loglevel [CRITICAL|ERROR|WARNING|INFO|DEBUG] The log level to use for aprsd.log [default: INFO] -c, --config TEXT The aprsd config file to use for options. [default: /Users/i530566/.config/aprsd/aprsd.yml] --quiet Don't log to stdout --aprs-login TEXT What callsign to send the message from. [env var: APRS_LOGIN] --aprs-password TEXT the APRS-IS password for APRS_LOGIN [env var: APRS_PASSWORD] -n, --no-ack Don't wait for an ack, just sent it to APRS- IS and bail. [default: False] -w, --wait-response Wait for a response to the message? [default: False] --raw TEXT Send a raw message. Implies --no-ack -h, --help Show this message and exit.
Received message______________ Raw : KM6XXX>APY400,WIDE1-1,qAO,KM6XXX-1::KM6XXX-9 :[email protected] test new shortcuts global, radio to pc{29 From : KM6XXX Message : [email protected] test new shortcuts global, radio to pc Msg number : 29 Sending Email_________________ To : [email protected] Subject : KM6XXX Body : test new shortcuts global, radio to pc Sending ack __________________ Tx(3) Raw : KM6XXX-9>APRS::KM6XXX :ack29 To : KM6XXX Ack number : 29
Sending message_______________ 6(Tx3) Raw : KM6XXX-9>APRS::KM6XXX :[email protected] email from internet to radio{6 To : KM6XXX Message : [email protected] email from internet to radio Received message______________ Raw : KM6XXX>APY400,WIDE1-1,qAO,KM6XXX-1::KM6XXX-9 :ack6 From : KM6XXX Message : ack6 Msg number : 0
Received Message _______________ Raw : KM6XXX-6>APRS,TCPIP*,qAC,T2CAEAST::KM6XXX-14:location{2 From : KM6XXX-6 Message : location Msg number : 2 Received Message _______________ Complete Sending Message _______________ Raw : KM6XXX-14>APRS::KM6XXX-6 :KM6XXX-6: 8 Miles E Auburn CA 0' 0,-120.93584 1873.7h ago{2 To : KM6XXX-6 Message : KM6XXX-6: 8 Miles E Auburn CA 0' 0,-120.93584 1873.7h ago Msg number : 2 Sending Message _______________ Complete Sending ack _______________ Raw : KM6XXX-14>APRS::KM6XXX-6 :ack2 To : KM6XXX-6 Ack : 2 Sending ack _______________ Complete
AND... ping, fortune, time.....
git clone [email protected]:craigerl/aprsd.git
cd aprsd
make
While working aprsd, The workflow is as follows:
Checkout a new branch to work on by running
git checkout -b mybranch
Make your changes to the code
Run Tox with the following options:
tox -epep8
tox -efmt
tox -p
Commit your changes. This will run the pre-commit hooks which does checks too
git commit
Once you are done with all of your commits, then push up the branch to github with:
git push -u origin mybranch
Create a pull request from your branch so github tests can run and we can do a code review.
To do release to pypi:
Tag release with:
git tag -v1.XX -m "New release"
Push release tag:
git push origin master --tags
Do a test build and verify build is valid by running:
make build
Once twine is happy, upload release to pypi:
make upload
There are 2 versions of the container Dockerfile that can be used. The main Dockerfile, which is for building the official release container based off of the pip install version of aprsd and the Dockerfile-dev, which is used for building a container based off of a git branch of the repo.
docker build -t hemna6969/aprsd:latest .
docker build -t hemna6969/aprsd:latest -f Dockerfile-dev .
There is a docker-compose.yml
file in the docker/
directory
that can be used to run your container. To provide the container
an aprsd.conf
configuration file, change your
docker-compose.yml
as shown below:
volumes: - $HOME/.config/aprsd:/config
To install plugins at container start time, pass in a list of
comma-separated list of plugins on PyPI using the APRSD_PLUGINS
environment variable in the docker-compose.yml
file. Note that
version constraints may also be provided. For example:
environment: - APRSD_PLUGINS=aprsd-slack-plugin>=1.0.2,aprsd-twitter-plugin