Skip to content

Commit

Permalink
Merge pull request #607 from jprochazka/vdlm2
Browse files Browse the repository at this point in the history
v2.8.7 (VDLM2, Readsb, Graph1090, and tar1090 support added.)
  • Loading branch information
jprochazka authored Aug 24, 2024
2 parents 1779d02 + f082ed6 commit 9536582
Show file tree
Hide file tree
Showing 89 changed files with 1,588 additions and 2,441 deletions.
7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,16 @@ build/beast-splitter
build/duckdns
build/dump1090-fa
build/dump978-fa
build/dumpvld2
build/flightradar24
build/flyitalyadsb
build/graphs1090
build/libacars
build/piaware_builder
build/planefinder
build/package-archive
build/portal/graphs/__pycache__/
build/portal/graphs/__pycache__
build/readsb
build/tar1090
build/vdlm2dec
logs
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,20 @@

The following is a history of the changes made to this project.

## v2.8.7 *(August 23rd)*

* The ability to install dumpvdl2 is now available as a decoder option.
* The ability to install vdlm2dec is now available as a decoder option.
* The ability to install Readsb is now available as a decoder option.
* The ability to install Graphs1090 is now available as an extras option.
* The ability to install tar1090 is now available as an extras option.
* Added missing Noble dependency to PiAware install script.
* Fixed Noble detection problem found within the PiAware install script.
* All decoder menus have been modified to support additional installation options.
* Device assignment scripting has been modified to work within functions.sh.
* Cleanup and consolidation performed on the PHP ADS-B Portal installation scripts.
* Merged the dump1090-tools copyright notice into the file dump1090.py.

## v2.8.6 *(August 13th, 2024)*

* The option to install ACARSDEC and ACARSSERV is now available as a decoder option.
Expand Down
35 changes: 20 additions & 15 deletions CREDITS.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,27 @@
First and foremost I would like to thank the collaborators and contributors who have contributed to
the project directly. Their time and effort is greatly appreciated by myself as well as many others.

* @mgunther68
* @jdwall
* @leearmstrong
* @wiedehopf
* @vitaliy-sk
* @target-drone
* @dschaper
* @adamkaplan
* @atbPy
* @bitpixdigital
* @BudBundi
* @charlie-foxtrot
* @dschaper
* @espinielli
* @g0wfv
* @jdwall
* @jsloyer
* @kylegordon
* @BudBundi
* @kuchel77
* @atbPy
* @g0wfv
* @ttsak
* @kylegordon
* @leearmstrong
* @mgunther68
* @mkrzysztofowicz
* @espinielli
* @bitpixdigital
* @RensHijdra
* @Romeo-Golf
* @g0wfv
* @target-drone
* @ttsak
* @vitaliy-sk
* @wiedehopf

## The Flight Tracking Community

Expand Down Expand Up @@ -56,8 +56,13 @@ hard work and dedication to their respective projects this project would not hav
* Dump1090 (FlightAware): https://github.com/flightaware/dump1090
* Dump1090-Tools: https://github.com/mutability/dump1090-tools
* Dump978 (FlightAware): https://github.com/flightaware/dump978
* Dumpvdl2: https://github.com/szpajder/dumpvdl2
* Fly Italy ADS-B Client: https://github.com/flyitalyadsb/fly-italy-adsb
* Graphs1090: https://github.com/wiedehopf/graphs1090
* PiAware (FlightAware): https://github.com/flightaware/piaware
* Readsb (wiedehopf): https://github.com/wiedehopf/readsb
* tar1090: https://github.com/wiedehopf/tar1090
* VDLM2DEC: https://github.com/TLeconte/vdlm2dec

Thanks also goes out to the developers and the businesses that employ them who work to supply us
with quality closed source packages which they have made available to the community.
Expand Down
17 changes: 11 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# The ADS-B Receiver Project :airplane:

## Run ADS-B/UAT/ACARS related applications without the overhead!
## Easily install ADS-B/UAT/ACARS/VDLM2 related applications!

This project continues to realize that for some, Docker and premade images are not the most optimal solution.

It would seem as of late the move towards premade as well as Docker and other PaaS images with preinstalled software has become popular within the community. Docker images require additional software and in some cases result in additional overhead when running. Most of these solutions also come with preinstalled software one may never use as part of the image as well. This project offers the ability to choose and install only what you want or need natively across a wide range of devices with minimal command line experience.
It would seem as of late the move towards premade as well as Docker and other PaaS images with preinstalled software has become popular within the community. Docker images require additional software and, in some cases, result in additional overhead as well as making trivial configuration changes more complicated than they should be. Most of these solutions also come with preinstalled software one may never use as part of the image as well. This project offers the ability to choose and install only what you want or need natively across a wide range of devices with minimal command line experience.

## Obtaining And Using This Software

### Manual installations...
### New installations...

sudo apt-get update
sudo apt-get install git
Expand All @@ -33,7 +33,7 @@ The following software can be installed using these scripts.
Included is the option to install the ADS-B Portal which offers the following features.

* Saves all flights seen as well as displays a plot for the flight.
* Saves all ACARS messages received as well as the ability to view these messages.
* Saves all ACARS and VDLM2 messages received and offers the ability to view them.
* Control what is displayed online via a web based administration area.
* A more uniform website site layout that can be easily navigated.
* Web accessible dump1090 and system performance graphs.
Expand All @@ -45,13 +45,16 @@ Included is the option to install the ADS-B Portal which offers the following fe

When setting up the portal you will have to choose between a lite or advanced installation. Advanced features add flight logging and plotting and should only be chosen on devices running a sturdy data storage solution.

*It is highly recommended that anyone using a SD card as they storage medium not attempt to use the advanced features.*
*It is highly recommended that anyone using a SD card as thier storage medium not attempt to use the advanced features.*

### Decoders

* ACARSDEC: https://github.com/TLeconte/acarsdec
* Dump1090 (FlightAware): https://github.com/flightaware/dump1090
* Dump978 (FlightAware): https://github.com/flightaware/dump978
* ACARSDEC: https://github.com/TLeconte/acarsdec
* Dumpvdl2: https://github.com/szpajder/dumpvdl2
* Readsb: https://github.com/wiedehopf/readsb
* VDLM2DEC: https://github.com/TLeconte/vdlm2dec

### Feeders

Expand All @@ -67,6 +70,8 @@ When setting up the portal you will have to choose between a lite or advanced in

* Beast-Splitter: https://github.com/flightaware/beast-splitter
* DuckDNS.org Support: https://www.duckdns.org
* Graphs1090: https://github.com/wiedehopf/graphs1090
* tar1090: https://github.com/wiedehopf/tar1090

## Supported Operating Systems

Expand Down
149 changes: 14 additions & 135 deletions bash/decoders/acarsdec.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,121 +49,24 @@ if [[ $exit_status != 0 ]]; then
exit 1
fi

log_heading "Gather information required to configure the decoder(s)"

log_message "Checking if an ADS-B decoder is installed"
adsb_decoder_installed="false"
if [[ $(dpkg-query -W -f='${STATUS}' dump1090-fa 2>/dev/null | grep -c "ok installed") -eq 1 ]]; then
log_message "An ADS-B decoder appears to be installed"
adsb_decoder_installed="true"
fi

log_message "Checking if a UAT decoder is installed"
uat_decoder_installed="false"
if [[ $(dpkg-query -W -f='${STATUS}' dump978-fa 2>/dev/null | grep -c "ok installed") -eq 1 ]]; then
log_message "An ADS-B decoder appears to be installed"
uat_decoder_installed="true"
fi

log_message "Checking if an ACARS decoder is installed"
acars_decoder_installed="false"
if [[ -f /usr/local/bin/acarsdec ]]; then
log_message "An ACARS decoder appears to be installed"
acars_decoder_installed="true"
fi

if [[ "${adsb_decoder_installed}" == "true" || "${uat_decoder_installed}" == "true" ]]; then
log_message "Informing the user that existing decoder(s) appears to be installed"
whiptail --backtitle "ACARSDEC Decoder Configuration" \
--title "RTL-SDR Dongle Assignments" \
--msgbox "It appears that existing decoder(s) have been installed on this device. In order to run ACARSDEC in tandem with other decoders you will need to specifiy which RTL-SDR dongle each decoder is to use.\n\nKeep in mind in order to run multiple decoders on a single device you will need to have multiple RTL-SDR devices connected to your device." \
12 78

if [[ "${adsb_decoder_installed}" == "true" ]]; then
log_message "Determining which device is currently assigned to the ADS-B decoder"
current_adsb_device_number=`get_config "RECEIVER_SERIAL" "/etc/default/dump1090-fa"`
log_message "Asking the user to assign a RTL-SDR device number to the ADS-B decoder"
adsb_device_number_title="Enter the ADS-B Decoder RTL-SDR Device Number"
while [[ -z $adsb_device_number ]] ; do
adsb_device_number=$(whiptail --backtitle "ACARSDEC Decoder Configuration" \
--title "${adsb_device_number_title}" \
--inputbox "Enter the RTL-SDR device number to assign your ADS-B decoder." \
8 78 \
"${current_adsb_device_number}" 3>&1 1>&2 2>&3)
exit_status=$?
if [[ $exit_status != 0 ]]; then
log_alert_heading "INSTALLATION HALTED"
log_alert_message "Setup has been halted due to lack of required information"
echo ""
log_title_message "------------------------------------------------------------------------------"
log_title_heading "ACARSDEC decoder setup halted"
exit 1
fi
adsb_device_number_title="Enter the ADS-B Decoder RTL-SDR Device Number (REQUIRED)"
done
fi

if [[ "${uat_decoder_installed}" == "true" ]]; then
log_message "Determining which device is currently assigned to the UAT decoder"
receiver_options=`get_config "RECEIVER_OPTIONS" "/etc/default/dump978-fa"`
current_uat_device_number=$receiver_options | grep -o -P '(?<=serial=).*(?= --)'
log_message "Asking the user to assign a RTL-SDR device number to the UAT decoder"
uat_device_number_title="Enter the UAT Decoder RTL-SDR Device Number"
while [[ -z $uat_device_number ]] ; do
uat_device_number=$(whiptail --backtitle "ACARSDEC Decoder Configuration" \
--title "${uat_device_number_title}" \
--inputbox "Enter the RTL-SDR device number to assign your UAT decoder." \
8 78 \
"${current_uat_device_number}" 3>&1 1>&2 2>&3)
exit_status=$?
if [[ $exit_status != 0 ]]; then
log_alert_heading "INSTALLATION HALTED"
log_alert_message "Setup has been halted due to lack of required information"
echo ""
log_title_message "------------------------------------------------------------------------------"
log_title_heading "ACARSDEC decoder setup halted"
exit 1
fi
uat_device_number_title="Enter the UAT Decoder RTL-SDR Device Number (REQUIRED)"
done
fi

current_acars_device_number=""
if [[ "${acars_decoder_installed}" == "true" ]]; then
log_message "Determining which device is currently assigned to the UAT decoder"
exec_start=`get_config "ExecStart" "/etc/systemd/system/acarsdec.service"`
current_acars_device_number=`echo $exec_start | grep -o -P '(?<=-r ).*(?= -A)'`
fi
log_message "Asking the user to assign a RTL-SDR device number to ACARSDEC"
acars_device_number_title="Enter the ACARSDEC RTL-SDR Device Number"
while [[ -z $acars_device_number ]]; do
acars_device_number=$(whiptail --backtitle "ACARSDEC Decoder Configuration" \
--title "${acars_device_number_title}" \
--inputbox "Enter the RTL-SDR device number to assign your ACARSDEC decoder." \
8 78 \
"${current_acars_device_number}" 3>&1 1>&2 2>&3)
exit_status=$?
if [[ $exit_status != 0 ]]; then
log_alert_heading "INSTALLATION HALTED"
log_alert_message "Setup has been halted due to lack of required information"
echo ""
log_title_message "------------------------------------------------------------------------------"
log_title_heading "ACARSDEC decoder setup halted"
exit 1
fi
acars_device_number_title="Enter the ACARSDEC RTL-SDR Device Number (REQUIRED)"
done
ask_for_device_assignments "acarsdec"
if [[ $? -ne 0 ]] ; then
log_alert_heading "INSTALLATION HALTED"
log_alert_message "Setup has been halted due to lack of required information"
echo ""
log_title_message "------------------------------------------------------------------------------"
log_title_heading "ACARSDEC decoder setup halted"
exit 1
fi

if [[ -z $acars_device_number ]]; then
acars_device_number="0"
if [[ -z $RECEIVER_DEVICE_ASSIGNED_TO_ACARS_DECODER ]]; then
RECEIVER_DEVICE_ASSIGNED_TO_ACARS_DECODER="0"
fi

current_acars_frequencies="130.025 130.425 130.450 131.125 131.550"
if [[ "${acars_decoder_installed}" == "true" ]]; then
log_message "Determining which frequencies are currently assigned"
exec_start=`get_config "ExecStart" "/etc/systemd/system/acarsdec.service"`
current_acars_frequencies=`sed -e "s#.*-r ${acars_device_number} \(\)#\1#" <<< "${exec_start}"`
current_acars_frequencies=`sed -e "s#.*-r ${RECEIVER_DEVICE_ASSIGNED_TO_ACARS_DECODER} \(\)#\1#" <<< "${exec_start}"`
fi
log_message "Asking the user for ACARS frequencies to monitor"
acars_fequencies_title="Enter ACARS Frequencies"
Expand Down Expand Up @@ -362,9 +265,9 @@ else
fi


## BUILD AND INSTALL THE ACARSDEC BINARY
## BUILD AND INSTALL THE ACARSSERV BINARY

log_heading "Building the ACARSDEC binary"
log_heading "Building the ACARSSERV binary"

log_message "Entering the acarsserv build directory"
cd $RECEIVER_BUILD_DIRECTORY/acarsserv
Expand Down Expand Up @@ -424,31 +327,7 @@ sudo systemctl enable --now acarsserv.service

## CONFIGURATION

if [[ "${adsb_decoder_installed}" == "true" || "${uat_decoder_installed}" == "true" ]]; then

log_heading "Configuring the decoders so they can work in tandem"

if [[ "${adsb_decoder_installed}" == "true" ]]; then
log_message "Assigning RTL-SDR device number ${adsb_device_number} to the FlightAware Dump1090 decoder"
change_config "RECEIVER_SERIAL" $adsb_device_number "/etc/default/dump1090-fa"
log_message "Restarting dump1090-fa"
sudo systemctl restart dump1090-fa
fi

if [[ "${uat_decoder_installed}" == "true" ]]; then
log_message "Assigning RTL-SDR device number ${uat_device_number} to the FlightAware Dump978 decoder"
sudo sed -i -e "s|driver=rtlsdr|driver=rtlsdr,serial=${uat_device_number}|g" /etc/default/dump978-fa
log_message "Restarting dump978-fa"
sudo systemctl restart dump978-fa
fi

log_message "Assigning RTL-SDR device number ${acars_device_number} to ACARSDEC"
sudo sed -i -e "s|\(.*-r \)\([0-9]\+\)\( .*\)|\1${acars_device_number}\3|g" /etc/systemd/system/acarsdec.service
log_message "Reloading systemd units"
sudo systemctl daemon-reload
log_message "Restarting ACARSDEC"
sudo systemctl restart acarsdec
fi
assign_devices_to_decoders


## POST INSTALLATION OPERATIONS
Expand Down
Loading

0 comments on commit 9536582

Please sign in to comment.