kopia lustrzana https://github.com/jprochazka/adsb-receiver
Added support for some of @wiedehopf's offerings.
rodzic
dc56aba0ce
commit
7a173fa93e
|
@ -6,6 +6,9 @@ The following is a history of the changes made to this project.
|
||||||
|
|
||||||
* The ability to install dumpvdl2 is now available as a decoder option.
|
* 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 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.
|
||||||
* All decoder menus have been modified to support additional options in the future.
|
* All decoder menus have been modified to support additional options in the future.
|
||||||
* Cleanup and consolidation performed on the PHP ADS-B Portal installation scripts.
|
* Cleanup and consolidation performed on the PHP ADS-B Portal installation scripts.
|
||||||
* Merged the dump1090-tools copyright notice into the file dump1090.py.
|
* Merged the dump1090-tools copyright notice into the file dump1090.py.
|
||||||
|
|
|
@ -58,7 +58,10 @@ hard work and dedication to their respective projects this project would not hav
|
||||||
* Dump978 (FlightAware): https://github.com/flightaware/dump978
|
* Dump978 (FlightAware): https://github.com/flightaware/dump978
|
||||||
* Dumpvdl2: https://github.com/szpajder/dumpvdl2
|
* Dumpvdl2: https://github.com/szpajder/dumpvdl2
|
||||||
* Fly Italy ADS-B Client: https://github.com/flyitalyadsb/fly-italy-adsb
|
* 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
|
* 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
|
* VDLM2DEC: https://github.com/TLeconte/vdlm2dec
|
||||||
|
|
||||||
Thanks also goes out to the developers and the businesses that employ them who work to supply us
|
Thanks also goes out to the developers and the businesses that employ them who work to supply us
|
||||||
|
|
|
@ -49,10 +49,11 @@ When setting up the portal you will have to choose between a lite or advanced in
|
||||||
|
|
||||||
### Decoders
|
### Decoders
|
||||||
|
|
||||||
|
* ACARSDEC: https://github.com/TLeconte/acarsdec
|
||||||
* Dump1090 (FlightAware): https://github.com/flightaware/dump1090
|
* Dump1090 (FlightAware): https://github.com/flightaware/dump1090
|
||||||
* Dump978 (FlightAware): https://github.com/flightaware/dump978
|
* Dump978 (FlightAware): https://github.com/flightaware/dump978
|
||||||
* Dumpvdl2: https://github.com/szpajder/dumpvdl2
|
* Dumpvdl2: https://github.com/szpajder/dumpvdl2
|
||||||
* ACARSDEC: https://github.com/TLeconte/acarsdec
|
* Readsb: https://github.com/wiedehopf/readsb
|
||||||
* VDLM2DEC: https://github.com/TLeconte/vdlm2dec
|
* VDLM2DEC: https://github.com/TLeconte/vdlm2dec
|
||||||
|
|
||||||
### Feeders
|
### Feeders
|
||||||
|
@ -69,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
|
* Beast-Splitter: https://github.com/flightaware/beast-splitter
|
||||||
* DuckDNS.org Support: https://www.duckdns.org
|
* DuckDNS.org Support: https://www.duckdns.org
|
||||||
|
* Graphs1090: https://github.com/wiedehopf/graphs1090
|
||||||
|
* tar1090: https://github.com/wiedehopf/tar1090
|
||||||
|
|
||||||
## Supported Operating Systems
|
## Supported Operating Systems
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,168 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# LIBRTLSDR SO VERSION ISSUE
|
||||||
|
# -----------------------------------------------------------------------------------
|
||||||
|
# Ubuntu Noble Numbat is currently built on librtlsdr v2.0.1 which mislabled the SO
|
||||||
|
# version as 2 instead of 0 causing a package naming problem between Debain Bookworm
|
||||||
|
# and Ubuntu Noble Numbat. Until the Noble package is built using v2.0.2 a temporary
|
||||||
|
# hack/fix was put in place to change references to the package librtlsdr0 to
|
||||||
|
# librtlsdr2 when Ubuntu Noble Numbat is detected.
|
||||||
|
|
||||||
|
## PRE INSTALLATION OPERATIONS
|
||||||
|
|
||||||
|
source $RECEIVER_BASH_DIRECTORY/variables.sh
|
||||||
|
source $RECEIVER_BASH_DIRECTORY/functions.sh
|
||||||
|
|
||||||
|
clear
|
||||||
|
log_project_title
|
||||||
|
log_title_heading "Setting up the Readsb decoder"
|
||||||
|
log_title_message "------------------------------------------------------------------------------"
|
||||||
|
if ! whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
||||||
|
--title "Readsb Decoder Setup" \
|
||||||
|
--yesno "Readsb is a Mode-S/ADSB/TIS decoder for RTLSDR, BladeRF, Modes-Beast and GNS5894 devices.\n\nRepository: https://github.com/wiedehopf/readsb\n\nWould you like to begin the setup process now?" \
|
||||||
|
14 78; then
|
||||||
|
echo ""
|
||||||
|
log_alert_heading "INSTALLATION HALTED"
|
||||||
|
log_alert_message "Setup has been halted at the request of the user"
|
||||||
|
echo ""
|
||||||
|
log_title_message "------------------------------------------------------------------------------"
|
||||||
|
log_title_heading "Readsb decoder setup halted"
|
||||||
|
echo ""
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
## GATHER REQUIRED INFORMATION FROM THE USER
|
||||||
|
|
||||||
|
ask_for_device_assignments "readsb"
|
||||||
|
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 "Readsb decoder setup halted"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
## CHECK FOR PREREQUISITE PACKAGES
|
||||||
|
|
||||||
|
log_heading "Installing packages needed to fulfill FlightAware Dump1090 decoder dependencies"
|
||||||
|
|
||||||
|
check_package build-essential
|
||||||
|
check_package debhelper
|
||||||
|
check_package git
|
||||||
|
check_package fakeroot
|
||||||
|
check_package libncurses-dev
|
||||||
|
check_package librtlsdr-dev
|
||||||
|
check_package libusb-1.0-0-dev
|
||||||
|
check_package libzstd1
|
||||||
|
check_package libzstd-dev
|
||||||
|
check_package pkg-config
|
||||||
|
check_package zlib1g
|
||||||
|
check_package zlib1g-dev
|
||||||
|
|
||||||
|
|
||||||
|
## BLACKLIST UNWANTED RTL-SDR MODULES
|
||||||
|
|
||||||
|
log_heading "Blacklist unwanted RTL-SDR kernel modules."
|
||||||
|
|
||||||
|
blacklist_modules
|
||||||
|
|
||||||
|
|
||||||
|
## CLONE OR PULL THE READSB DECODER SOURCE
|
||||||
|
|
||||||
|
log_heading "Preparing the Readsb Git repository"
|
||||||
|
|
||||||
|
if [[ -d $RECEIVER_BUILD_DIRECTORY/readsb/readsb && -d $RECEIVER_BUILD_DIRECTORY/readsb/readsb/.git ]]; then
|
||||||
|
log_message "Entering the Readsb git repository directory"
|
||||||
|
cd $RECEIVER_BUILD_DIRECTORY/readsb/readsb
|
||||||
|
log_message "Pulling the Readsb git repository"
|
||||||
|
echo ""
|
||||||
|
git pull 2>&1 | tee -a $RECEIVER_LOG_FILE
|
||||||
|
else
|
||||||
|
log_message "Creating the Readsb Project build directory"
|
||||||
|
echo ""
|
||||||
|
mkdir -v $RECEIVER_BUILD_DIRECTORY/readsb 2>&1 | tee -a $RECEIVER_LOG_FILE
|
||||||
|
echo ""
|
||||||
|
log_message "Entering the Readsb Project build directory"
|
||||||
|
cd $RECEIVER_BUILD_DIRECTORY/readsb
|
||||||
|
log_message "Cloning the readsb git repository"
|
||||||
|
echo ""
|
||||||
|
git clone https://github.com/wiedehopf/readsb.git 2>&1 | tee -a $RECEIVER_LOG_FILE
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Temporary fix for package name issue.
|
||||||
|
if [[ "${RECEIVER_OS_CODE_NAME}" == "noble" ]]; then
|
||||||
|
log_message "Applying fix for Noble librtlsdr package name issue"
|
||||||
|
sed -i -e 's/librtlsdr0/librtlsdr2/g' $RECEIVER_BUILD_DIRECTORY/readsb/readsb/debian/control
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
## BUILD AND INSTALL THE DUMP1090-FA PACKAGE
|
||||||
|
|
||||||
|
log_heading "Building the FlightAware dump1090-fa package"
|
||||||
|
|
||||||
|
log_message "Entering the dump1090 Git repository"
|
||||||
|
cd $RECEIVER_BUILD_DIRECTORY/readsb
|
||||||
|
log_message "Setting build options"
|
||||||
|
export DEB_BUILD_OPTIONS=noddebs
|
||||||
|
log_message "Building the Readsb Debian package"
|
||||||
|
echo ""
|
||||||
|
dpkg-buildpackage -b -Prtlsdr -ui -uc -us
|
||||||
|
echo ""
|
||||||
|
log_message "Installing the Readsb Debian package"
|
||||||
|
echo ""
|
||||||
|
sudo dpkg -i $RECEIVER_BUILD_DIRECTORY/readsb/readsb_*.deb
|
||||||
|
|
||||||
|
log_message "Checking that the Readsb Debian package was installed"
|
||||||
|
if [[ $(dpkg-query -W -f='${STATUS}' readsb 2>/dev/null | grep -c "ok installed") -eq 0 ]]; then
|
||||||
|
echo ""
|
||||||
|
log_alert_heading "INSTALLATION HALTED"
|
||||||
|
echo ""
|
||||||
|
log_alert_message "The Readsb Debian package failed to install"
|
||||||
|
log_alert_message "Setup has been terminated"
|
||||||
|
echo ""
|
||||||
|
log_title_message "------------------------------------------------------------------------------"
|
||||||
|
log_title_heading "Readsb decoder setup halted"
|
||||||
|
echo ""
|
||||||
|
read -p "Press enter to continue..." discard
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ ! -d $RECEIVER_BUILD_DIRECTORY/package-archive ]]; then
|
||||||
|
log_message "Creating the Debian package archive directory"
|
||||||
|
echo ""
|
||||||
|
mkdir -v $RECEIVER_BUILD_DIRECTORY/package-archive 2>&1 | tee -a $RECEIVER_LOG_FILE
|
||||||
|
echo ""
|
||||||
|
fi
|
||||||
|
log_message "Copying the Readsb Debian package into the Debian package archive directory"
|
||||||
|
echo ""
|
||||||
|
cp -vf $RECEIVER_BUILD_DIRECTORY/readsb/*.deb $RECEIVER_BUILD_DIRECTORY/package-archive/ 2>&1 | tee -a $RECEIVER_LOG_FILE
|
||||||
|
|
||||||
|
|
||||||
|
## CONFIGURATION
|
||||||
|
|
||||||
|
assign_devices_to_decoders
|
||||||
|
|
||||||
|
|
||||||
|
## POST INSTALLATION OPERATIONS
|
||||||
|
|
||||||
|
log_heading "Performing post installation operations"
|
||||||
|
|
||||||
|
log_message "Unsetting build options"
|
||||||
|
unset DEB_BUILD_OPTIONS
|
||||||
|
|
||||||
|
|
||||||
|
## SETUP COMPLETE
|
||||||
|
|
||||||
|
log_message "Returning to ${RECEIVER_PROJECT_TITLE} root directory"
|
||||||
|
cd $RECEIVER_ROOT_DIRECTORY
|
||||||
|
|
||||||
|
echo ""
|
||||||
|
log_title_message "------------------------------------------------------------------------------"
|
||||||
|
log_title_heading "Readsb decoder setup is complete"
|
||||||
|
echo ""
|
||||||
|
read -p "Press enter to continue..." discard
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,56 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
## PRE INSTALLATION OPERATIONS
|
||||||
|
|
||||||
|
source $RECEIVER_BASH_DIRECTORY/variables.sh
|
||||||
|
source $RECEIVER_BASH_DIRECTORY/functions.sh
|
||||||
|
|
||||||
|
clear
|
||||||
|
log_project_title
|
||||||
|
log_title_heading "Setting up Graphs1090"
|
||||||
|
log_title_message "------------------------------------------------------------------------------"
|
||||||
|
if ! whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
||||||
|
--title "Beast-Splitter Setup" \
|
||||||
|
--yesno "Graphs for readsb and dump1090-fa based on dump1090-tools by mutability.\n\nRepository: https://github.com/wiedehopf/graphs1090\n\nWould you like to begin the setup process now?" \
|
||||||
|
15 78; then
|
||||||
|
echo ""
|
||||||
|
echo -e "\e[91m \e[5mINSTALLATION HALTED!\e[25m"
|
||||||
|
echo -e " Setup has been halted at the request of the user."
|
||||||
|
echo -e ""
|
||||||
|
echo -e "\e[93m ------------------------------------------------------------------------------\e[96m"
|
||||||
|
echo -e "\e[92m Graphs1090 setup halted.\e[39m"
|
||||||
|
echo -e ""
|
||||||
|
read -p "Press enter to continue..." discard
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
## DOWNLOAD THEN EXECUTE THE INSTALLATION SCRIPT
|
||||||
|
|
||||||
|
log_heading "Preparing to install graphs1090"
|
||||||
|
|
||||||
|
if [[ ! -d $RECEIVER_BUILD_DIRECTORY/graphs1090 ]]; then
|
||||||
|
log_message "Creating the Graphs1090 build directory"
|
||||||
|
cd $RECEIVER_BUILD_DIRECTORY/graphs1090
|
||||||
|
fi
|
||||||
|
log_message "Entering the Graphs1090 build directory"
|
||||||
|
cd $RECEIVER_BUILD_DIRECTORY/graphs1090
|
||||||
|
log_message "Downloading the Graphs1090 install script"
|
||||||
|
wget -v -O $RECEIVER_BUILD_DIRECTORY/graphs1090/install.sh https://github.com/wiedehopf/graphs1090/raw/master/install.sh 2>&1 | tee -a $RECEIVER_LOG_FILE
|
||||||
|
log_message "Executing the Graphs1090 install script"
|
||||||
|
echo ""
|
||||||
|
sudo bash $RECEIVER_BUILD_DIRECTORY/graphs1090/install.sh
|
||||||
|
echo ""
|
||||||
|
|
||||||
|
|
||||||
|
## SETUP COMPLETE
|
||||||
|
|
||||||
|
log_message "Returning to ${RECEIVER_PROJECT_TITLE} root directory"
|
||||||
|
cd $RECEIVER_ROOT_DIRECTORY
|
||||||
|
|
||||||
|
echo ""
|
||||||
|
log_title_message "------------------------------------------------------------------------------"
|
||||||
|
log_title_heading "Graphs1090 setup is complete"
|
||||||
|
echo ""
|
||||||
|
read -p "Press enter to continue..." discard
|
||||||
|
|
||||||
|
exit 0
|
|
@ -0,0 +1,56 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
## PRE INSTALLATION OPERATIONS
|
||||||
|
|
||||||
|
source $RECEIVER_BASH_DIRECTORY/variables.sh
|
||||||
|
source $RECEIVER_BASH_DIRECTORY/functions.sh
|
||||||
|
|
||||||
|
clear
|
||||||
|
log_project_title
|
||||||
|
log_title_heading "Setting up tar1090"
|
||||||
|
log_title_message "------------------------------------------------------------------------------"
|
||||||
|
if ! whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
||||||
|
--title "Beast-Splitter Setup" \
|
||||||
|
--yesno "Tar1090 provides an improved webinterface for use with ADS-B decoders readsb / dump1090-fa.\n\nRepository: https://github.com/wiedehopf/tar1090\n\nWould you like to begin the setup process now?" \
|
||||||
|
15 78; then
|
||||||
|
echo ""
|
||||||
|
echo -e "\e[91m \e[5mINSTALLATION HALTED!\e[25m"
|
||||||
|
echo -e " Setup has been halted at the request of the user."
|
||||||
|
echo -e ""
|
||||||
|
echo -e "\e[93m ------------------------------------------------------------------------------\e[96m"
|
||||||
|
echo -e "\e[92m Tar1090 setup halted.\e[39m"
|
||||||
|
echo -e ""
|
||||||
|
read -p "Press enter to continue..." discard
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
## DOWNLOAD THEN EXECUTE THE INSTALLATION SCRIPT
|
||||||
|
|
||||||
|
log_heading "Preparing to install tar1090"
|
||||||
|
|
||||||
|
if [[ ! -d $RECEIVER_BUILD_DIRECTORY/tar1090 ]]; then
|
||||||
|
log_message "Creating the tar1090 build directory"
|
||||||
|
cd $RECEIVER_BUILD_DIRECTORY/tar1090
|
||||||
|
fi
|
||||||
|
log_message "Entering the tar1090 build directory"
|
||||||
|
cd $RECEIVER_BUILD_DIRECTORY/tar1090
|
||||||
|
log_message "Downloading the tar1090 install script"
|
||||||
|
wget -v -O $RECEIVER_BUILD_DIRECTORY/tar1090/install.sh https://raw.githubusercontent.com/wiedehopf/tar1090/master/install.sh 2>&1 | tee -a $RECEIVER_LOG_FILE
|
||||||
|
log_message "Executing the tar1090 install script"
|
||||||
|
echo ""
|
||||||
|
sudo bash $RECEIVER_BUILD_DIRECTORY/tar1090/install.sh
|
||||||
|
echo ""
|
||||||
|
|
||||||
|
|
||||||
|
## SETUP COMPLETE
|
||||||
|
|
||||||
|
log_message "Returning to ${RECEIVER_PROJECT_TITLE} root directory"
|
||||||
|
cd $RECEIVER_ROOT_DIRECTORY
|
||||||
|
|
||||||
|
echo ""
|
||||||
|
log_title_message "------------------------------------------------------------------------------"
|
||||||
|
log_title_heading "Tar1090 setup is complete"
|
||||||
|
echo ""
|
||||||
|
read -p "Press enter to continue..." discard
|
||||||
|
|
||||||
|
exit 0
|
|
@ -1,58 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# TODO: UDPrepeater should now reside within the bin directory within the repository.
|
|
||||||
# https://github.com/json-parser/json-parser
|
|
||||||
# https://troydhanson.github.io/uthash/ (uthash-dev package available)
|
|
||||||
|
|
||||||
## PRE INSTALLATION OPERATIONS
|
|
||||||
|
|
||||||
source $RECEIVER_BASH_DIRECTORY/variables.sh
|
|
||||||
source $RECEIVER_BASH_DIRECTORY/functions.sh
|
|
||||||
|
|
||||||
clear
|
|
||||||
log_project_title
|
|
||||||
log_title_heading "Setting up UDPrepeater"
|
|
||||||
log_title_message "------------------------------------------------------------------------------"
|
|
||||||
if ! whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
|
||||||
--title "UDPrepeater Setup" \
|
|
||||||
--yesno "UDPrepeater is a general purpose, configurable UDP forwarding/repeating daemon for Linux. It is useful for repeating one-way streams of data from a single sender to multiple receivers, and for forwarding UDP traffic to different receivers based upon source or destination IP addresses or UDP ports.\n\n https://github.com/UnionPacific/udp-repeater\n\nContinue UDPrepeater setup?" \
|
|
||||||
15 78; then
|
|
||||||
echo ""
|
|
||||||
echo -e "\e[91m \e[5mINSTALLATION HALTED!\e[25m"
|
|
||||||
echo -e " Setup has been halted at the request of the user."
|
|
||||||
echo -e ""
|
|
||||||
echo -e "\e[93m ------------------------------------------------------------------------------\e[96m"
|
|
||||||
echo -e "\e[92m UDPrepeater setup halted.\e[39m"
|
|
||||||
echo -e ""
|
|
||||||
read -p "Press enter to continue..." discard
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
## CLONE OR PULL THE UDPREPEATER DECODER SOURCE
|
|
||||||
|
|
||||||
log_heading "Preparing the UDPrepeater Git repository"
|
|
||||||
|
|
||||||
if [[ -d $RECEIVER_BUILD_DIRECTORY/udp-repeater && -d $RECEIVER_BUILD_DIRECTORY/udp-repeater/.git ]]; then
|
|
||||||
log_message "Entering the UDPrepeater git repository directory"
|
|
||||||
cd $RECEIVER_BUILD_DIRECTORY/udp-repeater
|
|
||||||
log_message "Updating the local UDPrepeater git repository"
|
|
||||||
echo ""
|
|
||||||
git pull
|
|
||||||
else
|
|
||||||
log_message "Entering the build directory"
|
|
||||||
cd $RECEIVER_BUILD_DIRECTORY
|
|
||||||
log_message "Cloning the UDPrepeater git repository locally"
|
|
||||||
echo ""
|
|
||||||
git clone https://github.com/UnionPacific/udp-repeater
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
## BUILD THE UDPREPEATER BINARY
|
|
||||||
|
|
||||||
log_heading "Building the UDPrepeater binary"
|
|
||||||
|
|
||||||
log_message "Entering the UDPrepeater src repository"
|
|
||||||
cd $RECEIVER_BUILD_DIRECTORY/udp-repeater/src
|
|
||||||
log_message "Running the make command"
|
|
||||||
make
|
|
78
bash/main.sh
78
bash/main.sh
|
@ -11,10 +11,10 @@ source ${RECEIVER_BASH_DIRECTORY}/functions.sh
|
||||||
adsb_decoder_installed="false"
|
adsb_decoder_installed="false"
|
||||||
install_adsb_decoder="false"
|
install_adsb_decoder="false"
|
||||||
|
|
||||||
if [[ $(dpkg-query -W -f='${STATUS}' dump1090-fa 2>/dev/null | grep -c "ok installed") == 1 ]] ; then
|
if [[ $(dpkg-query -W -f='${STATUS}' dump1090-fa 2>/dev/null | grep -c "ok installed") == 1 ]]; then
|
||||||
adsb_decoder_installed="true"
|
adsb_decoder_installed="true"
|
||||||
chosen_adsb_decoder="dump1090-fa"
|
chosen_adsb_decoder="dump1090-fa"
|
||||||
if [[ $(sudo dpkg -s dump1090-fa 2>/dev/null | grep -c "Version: ${dump1090_fa_current_version}") == 0 ]] ; then
|
if [[ $(sudo dpkg -s dump1090-fa 2>/dev/null | grep -c "Version: ${dump1090_fa_current_version}") == 0 ]]; then
|
||||||
whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
||||||
--title "FlightAware Dump1090 Upgrade Available" \
|
--title "FlightAware Dump1090 Upgrade Available" \
|
||||||
--defaultno \
|
--defaultno \
|
||||||
|
@ -34,6 +34,19 @@ if [[ $(dpkg-query -W -f='${STATUS}' dump1090-fa 2>/dev/null | grep -c "ok insta
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ $(dpkg-query -W -f='${STATUS}' readsb 2>/dev/null | grep -c "ok installed") == 1 ]]; then
|
||||||
|
adsb_decoder_installed="true"
|
||||||
|
chosen_adsb_decoder="readsb"
|
||||||
|
whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
||||||
|
--title "Reinstall Readsb Decoder" \
|
||||||
|
--defaultno \
|
||||||
|
--yesno "The option to rebuild and reinstall Readsb is available.\n\nWould you like to rebuild and reinstall Readsb?" \
|
||||||
|
9 65
|
||||||
|
if [[ $? == 0 ]]; then
|
||||||
|
install_adsb_decoder="true"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ "${adsb_decoder_installed}" == "false" ]]; then
|
if [[ "${adsb_decoder_installed}" == "false" ]]; then
|
||||||
chosen_adsb_decoder=$(whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
chosen_adsb_decoder=$(whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
||||||
--title "ADS-B Decoder Selection" \
|
--title "ADS-B Decoder Selection" \
|
||||||
|
@ -41,6 +54,7 @@ if [[ "${adsb_decoder_installed}" == "false" ]]; then
|
||||||
16 100 9 \
|
16 100 9 \
|
||||||
"None" "Do not install an ADS-B decoder." \
|
"None" "Do not install an ADS-B decoder." \
|
||||||
"dump1090-fa" "FlightAware's version of the dump1090 decoder." \
|
"dump1090-fa" "FlightAware's version of the dump1090 decoder." \
|
||||||
|
"readsb" "Wiedehopf's detached fork of readsb." \
|
||||||
3>&2 2>&1 1>&3)
|
3>&2 2>&1 1>&3)
|
||||||
exit_status=$?
|
exit_status=$?
|
||||||
if [[ $exit_status != 0 || "${chosen_uat_decoder}" == "None" ]]; then
|
if [[ $exit_status != 0 || "${chosen_uat_decoder}" == "None" ]]; then
|
||||||
|
@ -56,6 +70,14 @@ function install_dump1090_fa() {
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function install_readsb() {
|
||||||
|
chmod +x ${RECEIVER_BASH_DIRECTORY}/decoders/readsb.sh
|
||||||
|
${RECEIVER_BASH_DIRECTORY}/decoders/readsb.sh
|
||||||
|
if [[ $? != 0 ]] ; then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
## UAT DECODERS
|
## UAT DECODERS
|
||||||
|
|
||||||
|
@ -420,10 +442,8 @@ function install_beastsplitter() {
|
||||||
|
|
||||||
# Duck DNS
|
# Duck DNS
|
||||||
if [[ ! -f "${RECEIVER_BUILD_DIRECTORY}/duckdns/duck.sh" ]]; then
|
if [[ ! -f "${RECEIVER_BUILD_DIRECTORY}/duckdns/duck.sh" ]]; then
|
||||||
# Duck DNS does not appear to be set up on this device.
|
|
||||||
extras_list=("${extras_list[@]}" 'Duck DNS Free Dynamic DNS Hosting' '' OFF)
|
extras_list=("${extras_list[@]}" 'Duck DNS Free Dynamic DNS Hosting' '' OFF)
|
||||||
else
|
else
|
||||||
# Offer the option to install/setup Duck DNS once more.
|
|
||||||
extras_list=("${extras_list[@]}" 'Duck DNS Free Dynamic DNS Hosting (reinstall)' '' OFF)
|
extras_list=("${extras_list[@]}" 'Duck DNS Free Dynamic DNS Hosting (reinstall)' '' OFF)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -435,6 +455,36 @@ function install_duckdns() {
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Graphs1090
|
||||||
|
if [[ ! -f /lib/systemd/system/graphs1090.service ]]; then
|
||||||
|
extras_list=("${extras_list[@]}" 'Graphs1090' '' OFF)
|
||||||
|
else
|
||||||
|
extras_list=("${extras_list[@]}" 'Graphs1090 (reinstall)' '' OFF)
|
||||||
|
fi
|
||||||
|
|
||||||
|
function install_graphs1090() {
|
||||||
|
chmod +x ${RECEIVER_BASH_DIRECTORY}/extras/graphs1090.sh
|
||||||
|
${RECEIVER_BASH_DIRECTORY}/extras/graphs1090.sh
|
||||||
|
if [[ $? != 0 ]] ; then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# tar1090
|
||||||
|
if [[ ! -f /lib/systemd/system/tar1090.service ]]; then
|
||||||
|
extras_list=("${extras_list[@]}" 'tar1090' '' OFF)
|
||||||
|
else
|
||||||
|
extras_list=("${extras_list[@]}" 'tar1090 (reinstall)' '' OFF)
|
||||||
|
fi
|
||||||
|
|
||||||
|
function install_tar1090() {
|
||||||
|
chmod +x ${RECEIVER_BASH_DIRECTORY}/extras/tar1090.sh
|
||||||
|
${RECEIVER_BASH_DIRECTORY}/extras/tar1090.sh
|
||||||
|
if [[ $? != 0 ]] ; then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
whiptail --backtitle "${RECEIVER_PROJECT_TITLE}" \
|
||||||
--title "Extras Installation Options" \
|
--title "Extras Installation Options" \
|
||||||
--checklist \
|
--checklist \
|
||||||
|
@ -465,6 +515,9 @@ else
|
||||||
"dump1090-fa")
|
"dump1090-fa")
|
||||||
confirmation_message="${confirmation_message}\n * FlightAware dump1090"
|
confirmation_message="${confirmation_message}\n * FlightAware dump1090"
|
||||||
;;
|
;;
|
||||||
|
"readsb")
|
||||||
|
confirmation_message="${confirmation_message}\n * Readsb"
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -539,6 +592,9 @@ if [[ "${install_adsb_decoder}" == "true" ]]; then
|
||||||
"dump1090-fa")
|
"dump1090-fa")
|
||||||
install_dump1090_fa
|
install_dump1090_fa
|
||||||
;;
|
;;
|
||||||
|
"Readsb")
|
||||||
|
install_readsb
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -658,6 +714,12 @@ if [[ -s "${RECEIVER_ROOT_DIRECTORY}/EXTRAS_CHOICES" ]]; then
|
||||||
"Duck DNS Free Dynamic DNS Hosting"|"Duck DNS Free Dynamic DNS Hosting (reinstall)")
|
"Duck DNS Free Dynamic DNS Hosting"|"Duck DNS Free Dynamic DNS Hosting (reinstall)")
|
||||||
run_duckdns_script="true"
|
run_duckdns_script="true"
|
||||||
;;
|
;;
|
||||||
|
"Graphs1090"|"Graphs1090 (reinstall)")
|
||||||
|
run_graphs1090_script="true"
|
||||||
|
;;
|
||||||
|
"tar1090"|"tar1090 (reinstall)")
|
||||||
|
run_tar1090_script="true"
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
done < ${RECEIVER_ROOT_DIRECTORY}/EXTRAS_CHOICES
|
done < ${RECEIVER_ROOT_DIRECTORY}/EXTRAS_CHOICES
|
||||||
fi
|
fi
|
||||||
|
@ -670,4 +732,12 @@ if [[ "${run_duckdns_script}" == "true" ]]; then
|
||||||
install_duckdns
|
install_duckdns
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ "${run_graphs1090_script}" == "true" ]]; then
|
||||||
|
install_graphs1090
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "${run_tar1090_script}" == "true" ]]; then
|
||||||
|
install_tar1090
|
||||||
|
fi
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
|
|
Ładowanie…
Reference in New Issue