Merge pull request #160 from km4ack/dev

Dev
pull/168/head
KM4ACK 2020-10-16 15:09:37 -05:00 zatwierdzone przez GitHub
commit f07dad37cc
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
12 zmienionych plików z 355 dodań i 35 usunięć

Wyświetl plik

@ -19,12 +19,7 @@ For Pat Winlink:
Winlink Password & Grid Square
# Install
This script is intended to run on a brand new installation of Buster. It should not be run on a pi that you have already started installing applications on. Install additional apps that you require after running this script.\
\
Get Debian Buster from https://cdimage.debian.org/debian-cd/current/arm64/iso-cd/ file debian-10.4.0-arm64-xfce-CD-1.iso
NOTE: The Debian Buster arm64 image does not come with RealVNC server pre-installed, as it does with Raspbian. The reason is that RealVNC package is currently compiled for the armhf version of libbcm_host.so, which is a hook into the Broadcom GPU chip. As of 2020-06-27, it is not yet possible to get Debian Buster ARM64 to work with VNC.
If this is a problem for you, then you will need to download Raspberry Pi OS (previously called Rasbian) 32-bit from https://downloads.raspberrypi.org/raspios_armhf_latest
Download Raspberry Pi OS (previously called Rasbian) 32-bit from https://downloads.raspberrypi.org/raspios_armhf_latest
Use a USB flash application such as Balena Etcher to copy the iso file to a USB key, get it at https://www.balena.io/etcher/

Wyświetl plik

@ -341,7 +341,6 @@ false "PAT-MENU" "Control for Pat Winlink" \
false "JS8CALL" "Weak Signal Digital Mode Software" \
false "M0IAX" "Tools for JS8Call Messages" \
false "WSJTX" "Weak Signal Digital Mode Software" \
false "JTDX" "Weak Signal Digital Mode Software" \
false "PYQSO" "Logging Software" \
false "CQRLOG" "Logging Software" \
false "XLOG" "Logging Software" \
@ -365,7 +364,7 @@ fi
if [ $BUT = 3 ]; then
ADDAPPS=(CONKY PI-APRS CHIRP GARIM PAT PAT-MENU JS8CALL M0IAX WSJTX PYQSO \
CQRLOG EES QSSTV GRIDTRACKER HAMCLOCK PROPAGATION YAAC XASTIR GPREDICT TQSL \
XLOG JTDX)
XLOG)
for i in "${ADDAPPS[@]}"
do
@ -416,6 +415,13 @@ false "TEMPCONVERT" "Temperature Converter" \
false "GPARTED" "Disk Utility Tool" \
false "SHOWLOG" "Log file viewer" \
false "PISTATS" "Pi3/4 Stats Monitor" \
false "TELNET" "Telnet Protocol" \
false "PITERM" "piQtTermTCP Terminal Program" \
false "SECURITY" "File Encryption Software" \
false "YGATE" "Yaesu APRS Software" \
false "BPQ" "LinBPQ Software" \
false "BATT" "Battery Test Script" \
false "VNC" "VNC Client Application" \
--button="Exit":1 \
--button="Check All and Continue":3 \
--button="Install Selected":2 > $UTILITY
@ -425,7 +431,7 @@ exit
fi
if [ $BUT = 3 ]; then
UTILAPPS=(DIPOLE CALLSIGN TEMPCONVERT GPARTED SHOWLOG PISTATS)
UTILAPPS=(DIPOLE CALLSIGN TEMPCONVERT GPARTED SHOWLOG PISTATS TELNET PITERM SECURITY YGATE BPQ BATT VNC)
for i in "${UTILAPPS[@]}"
do
echo "$i" >> $UTILITY

Wyświetl plik

@ -1,4 +1,22 @@
version=3.0.4
version=3.0.5
3.0.5 Fix RTC https://github.com/km4ack/pi-build/issues/139
Add Telnet https://github.com/km4ack/pi-build/issues/129
Fix GPS conflict https://github.com/km4ack/pi-build/issues/146
Add Security Tool File Encryption https://github.com/km4ack/pi-build/issues/148
Add PTT command to direwolf.conf (commented out by default)
Fix curl "body write fail" in update script
Fix https://github.com/km4ack/pi-build/issues/152
Fix https://github.com/km4ack/pi-build/issues/155
Add YGATE - https://github.com/craigerl/ygate/blob/master/ygate.py
Add XGPS menu item - https://github.com/km4ack/pi-build/issues/156
update README.md
add LinBPQ
fix https://github.com/km4ack/pi-build/issues/105 (Conky display issue)
add Battery Test Script
add piQtTermTCP
Remove JTDX (Website Down) see - https://github.com/km4ack/pi-build/issues/153
add VNC viewer
3.0.4 Add gitignore
Fix Issue #109 https://github.com/km4ack/pi-build/issues/109

Wyświetl plik

@ -25,7 +25,7 @@ no_buffers yes
uppercase no
cpu_avg_samples 2
net_avg_samples 1
override_utf8_locale no
override_utf8_locale yes
use_spacer right
TEXT

Wyświetl plik

@ -26,7 +26,7 @@ conky.config = {
uppercase = false,
cpu_avg_samples = 2,
net_avg_samples = 1,
override_utf8_locale = false,
override_utf8_locale = true,
use_spacer = 'right',
};

Wyświetl plik

@ -26,7 +26,7 @@ conky.config = {
uppercase = false,
cpu_avg_samples = 2,
net_avg_samples = 1,
override_utf8_locale = false,
override_utf8_locale = true,
use_spacer = 'right',
};

Wyświetl plik

@ -26,7 +26,7 @@ conky.config = {
uppercase = false,
cpu_avg_samples = 2,
net_avg_samples = 1,
override_utf8_locale = false,
override_utf8_locale = true,
use_spacer = 'right',
};

Wyświetl plik

@ -3,7 +3,7 @@
#get VFO of radio to display in conky
#20200428
source "$HOME/patmenu/config"
source "$HOME/patmenu2/config"
MAIN () {

Wyświetl plik

@ -121,6 +121,7 @@ CONKY(){
sudo apt install -y conky
fi
touch $HOME/Documents/mylog.txt #conky will fail to load if this file doesn't exist
touch /var/lib/misc/dnsmasq.leases #conky will fail to load if this file doesn't exist
sudo apt-get install -y ruby2.5
sudo gem install gpsd_client
sudo gem install maidenhead
@ -554,6 +555,10 @@ fi
##################################
# JTDX
##################################
#This code is left in place but no option is given during inital
#run or update because the jtdx website is down.
#see https://github.com/km4ack/pi-build/issues/153
#14OCT2020 KM4ACK
JTDX(){
cd $HOME

Wyświetl plik

@ -53,6 +53,21 @@ rm $DIR/gpsinstall
#GPS Variable set by main script or update script
#and placed in config file
sudo sed -i "s|DEVICES.*$|DEVICES=\"$GPS\"|g" /etc/default/gpsd
#add xgps to menu
cat > xgps.desktop <<EOF
[Desktop Entry]
Name=XGPS
GenericName=XGPS
Comment=GPS Date Viewer
Exec=/usr/bin/xgps
Icon=/usr/share/icons/Adwaita/scalable/devices/thunderbolt-symbolic.svg
Terminal=false
Type=Application
Categories=Utility
EOF
sudo mv xgps.desktop /usr/share/applications/
}
################################
@ -121,6 +136,7 @@ sudo make install
make install-conf
sed -i "s/N0CALL/$CALL/" "$HOME/direwolf.conf"
sed -i 's/# ADEVICE plughw:1,0/ADEVICE plughw:2,0/' $HOME/direwolf.conf
sed -i '/#PTT\ \/dev\/ttyUSB0\ RTS/a #Uncomment line below for PTT with sabrent sound card\n#PTT RIG 2 localhost:4532' $HOME/direwolf.conf
rm -rf $HOME/direwolf
}

Wyświetl plik

@ -119,8 +119,10 @@ yad --form --width=500 --text-align=center --center --title="Build-a-Pi" --text-
--image $LOGO --window-icon=$LOGO --image-on-top --separator="|" --item-separator="|" \
--text="Real Time Clock already installed" \
--button=gtk-close
exit 1
fi
#exit statement here causes script to exit without finishing. Reference link next line
#https://github.com/km4ack/pi-build/issues/139
else
IC2ACTIVE=$(ls /dev/*i2c*)
@ -183,6 +185,7 @@ yad --form --width=500 --text-align=center --center --title="Build-a-Pi" --text-
--button=gtk-close
fi
fi #close first if/then statement
}
@ -205,22 +208,218 @@ cd $HOME
rm -rf $PISTATDIR
}
##################################
# TELNET
##################################
TELNET(){
sudo apt install -y telnet
}
##################################
# PiQtTermTCP
##################################
PITERM(){
cd $DIR
wget https://www.cantab.net/users/john.wiseman/Downloads/Beta/piQtTermTCP
sudo chmod +x piQtTermTCP
sudo mv piQtTermTCP /usr/local/bin/
cat > piqttermtcp.desktop <<EOF
[Desktop Entry]
Name=PiQtTermTCP
GenericName=PiQtTermTCP
Comment=Terminal Program
Exec=/usr/local/bin/piQtTermTCP
Icon=/usr/share/icons/gnome/22x22/apps/xscreensaver.png
Terminal=false
Type=Application
Categories=Utility
EOF
sudo mv piqttermtcp.desktop /usr/share/applications/
}
##################################
# Security Tools
##################################
SECURITY(){
cd $HOME/bin
wget https://raw.githubusercontent.com/km4ack/pi-scripts/master/security-tools
bash security-tools
sudo mv $HOME/bin/securefile /usr/local/bin
cat > secure-file.desktop <<EOF
[Desktop Entry]
Name=SSE File Encryptor
GenericName=SSE File Encryptor
Comment=A program to encrypt files on the pi
Exec=/usr/local/bin/securefile
Icon=/usr/share/icons/gnome/22x22/actions/lock.png
Terminal=false
Type=Application
Categories=Utility
EOF
sudo mv secure-file.desktop /usr/share/applications/
}
##################################
# YGATE
##################################
YGATE(){
cd $HOME/bin
wget https://raw.githubusercontent.com/craigerl/ygate/master/ygate.py
chmod +x ygate.py
cat > ygate.desktop <<EOF
[Desktop Entry]
Name=YGATE
GenericName=YGATE
Comment=Yaesu APRS Application
Exec=$HOME/bin/ygate.py
Terminal=true
Type=Application
Categories=Utility
EOF
sudo mv ygate.desktop /usr/share/applications/
}
##################################
# BPQ
##################################
BPQ(){
source $HOME/pi-build/config
#install LinBPQ
cd
##########################################################################
#commands below this line were taken from John Wiseman's install script.
#and modded to pull the operators call sign from the BAP config file.
#http://www.cantab.net/users/john.wiseman/Downloads/installLinRMS
##########################################################################
export LINBPQ=pilinbpq;
export APRS=piBPQAPRS
echo "Downloading $LINBPQ and $APRS to linbpq and bpqaprs"
mkdir linbpq
cd linbpq
wget -nv http://www.cantab.net/users/john.wiseman/Downloads/Beta/$LINBPQ -O linbpq
chmod +x linbpq
wget -nv http://www.cantab.net/users/john.wiseman/Downloads/Beta/$APRS -O bpqaprs
chmod +x bpqaprs
echo "Downloading config files"
wget -nv http://www.cantab.net/users/john.wiseman/Downloads/SimpleRMSGateway_bpq32.cfg -O bpq32.cfg
echo "Downloading HTML Files"
mkdir HTML
cd HTML
wget -nv http://www.cantab.net/users/john.wiseman/Downloads/Beta/HTMLPages.zip
unzip -o -q HTMLPages.zip
rm HTMLPages.zip
cd ..
wget -nv http://www.cantab.net/users/john.wiseman/Downloads/LinBPQAPRS.zip
unzip -o -q LinBPQAPRS.zip
rm LinBPQAPRS.zip
echo "Updating your callsign in configuration files"
#read -e -p "Enter Your Callsign (Without SSID): " CALL
CALL=$(echo "$CALL" | tr '[:lower:]' '[:upper:]')
sed -i "s/MYCALL/$CALL/g" bpq32.cfg
#####################################################
#End John Wiseman install script
#####################################################
#install BPQ config generator
cd $HOME/linbpq
wget https://www.cantab.net/users/john.wiseman/Downloads/Beta/piBPQConfigGen
chmod +x piBPQConfigGen
cat > bpq-config.desktop <<EOF
[Desktop Entry]
Name=BPQ Config Generator
GenericName=BPQ Config Generator
Comment=Config File Generator for LinBPQ
Exec=$HOME/linbpq/piBPQConfigGen
Terminal=false
Type=Application
Categories=Utility
EOF
sudo mv bpq-config.desktop /usr/share/applications/
#add LinBPQ-README to desktop
FILE=$HOME/Desktop/LinBPQ-README
touch $FILE
cat << EOF > $FILE
LinBPQ was installed during the build.
You will find the config file generator
under utilities in the main pi menu.
NO CONFIGURATION was done for LinBPQ
during the build. Each individual
operator is responsible for configuring
his/her station.
After completing the config file, you can
start LinBPQ from the command line by running:
~/linbpq/.linbpq
Depending on your station setup, you may
need to start rig control, direwolf, or
other applications before running LinBPQ.
If you need help, you can find
the LinBPQ forums at
https://groups.io/g/bpq32/topics
and the main LinBPQ web page at
http://g8bpq.org.uk
EOF
}
##################################
# Battery Test Script
##################################
BATT(){
cd $HOME/bin
wget https://raw.githubusercontent.com/km4ack/pi-scripts/master/batt-test
chmod +x batt-test
cat > battery-test.desktop <<EOF
[Desktop Entry]
Name=Battery Test Script
GenericName=Battery Test Script
Comment=Battery Test Utility
Exec=$HOME/bin/batt-test
Terminal=true
Type=Application
Categories=Utility
EOF
sudo mv battery-test.desktop /usr/share/applications/
}
##################################
# VNC Viewer
##################################
VNC(){
cd $HOME
PACKAGE=$(curl -s https://www.realvnc.com/en/connect/download/viewer/raspberrypi/ | grep .deb | awk '{print $2}' | \
sed 's/href="\/download\/file\/viewer.files\///' | sed 's/"//')
wget https://realvnc.com/download/file/viewer.files/$PACKAGE
sudo dpkg -i $PACKAGE
rm $PACKAGE
}

85
update
Wyświetl plik

@ -62,7 +62,7 @@ mkdir -p $HOME/.config/autostart
echo "Checking for Build a Pi updates"
CURRENT=$(head -1 $MYPATH/changelog | sed s'/version=//')
LATEST=$(curl -s https://raw.githubusercontent.com/km4ack/pi-build/master/changelog | head -1 | sed 's/version=//')
LATEST=$(curl -s https://raw.githubusercontent.com/km4ack/pi-build/master/changelog | tac | tac | head -1 | sed 's/version=//')
if (( $(echo "$LATEST $CURRENT" | awk '{print ($1 > $2)}') ))
then
@ -653,8 +653,83 @@ fi
}
#----------------------------------------------------#
# TELNET
#----------------------------------------------------#
if ! hash telnet 2>/dev/null; then
TEL="Not Installed"
else
TEL="Installed"
fi
#----------------------------------------------------#
# piQtTermTCP
#----------------------------------------------------#
if [ -f /usr/local/bin/piQtTermTCP ]; then
PITERM="Installed"
else
PITERM="Not Installed"
fi
#----------------------------------------------------#
# Security Tools
#----------------------------------------------------#
if [ -f /usr/local/bin/securefile ]; then
SECURITY="Installed"
else
SECURITY="Not Installed"
fi
#----------------------------------------------------#
# YGATE
#----------------------------------------------------#
YGATE="$HOME/bin/ygate.py"
if [ ! -f "$YGATE" ]; then
YGATE="Not Installed"
else
YGATE="Installed"
fi
#----------------------------------------------------#
# BPQ
#----------------------------------------------------#
BPQ="$HOME/linbpq/linbpq"
if [ ! -f "$BPQ" ]; then
BPQ="Not Installed"
else
BPQ="Installed"
fi
#----------------------------------------------------#
# Battery Test Script :: BATT
#----------------------------------------------------#
BATT="$HOME/bin/batt-test"
if [ ! -f "$BATT" ]; then
BATT="Not Installed"
else
BATT="Installed"
fi
#----------------------------------------------------#
# VNC Viewer
#----------------------------------------------------#
if ! hash vncviewer 2>/dev/null; then
VNC="Not Installed"
else
VNC="Installed"
fi
CHECK
####################################################################
####################################################################
####################################################################
####################################################################
####################################################################
####################################################################
####################################################################
####################################################################
####################################################################
#####################################
# Get User Call
#####################################
@ -842,7 +917,6 @@ false "GARIM" "$GARIM" "File Transfer Program " \
false "M0IAX" "$M0IAX" "Tools for JS8Call messages" \
false "CONKY" "$CONKY" "System Information Display" \
false "WSJTX" "$FT8" "Weak signal digital mode software" \
false "JTDX" "$JTDX" "Weak signal digital mode software" \
false "JS8CALL" "$JS8" "Weak signal digital mode software" \
false "XASTIR" "$XASTIR" "APRS Client" \
false "YAAC" "$YAAC" "Yet Another APRS Client" \
@ -909,6 +983,13 @@ false "GPARTED" "$GPARTED" "Disk Utility Application" \
false "RTC" "$RTC" "Real Time Clock" \
false "SHOWLOG" "$SHOWLOG" "Log File Viewer" \
false "PISTATS" "$PISTATS" "Pi3/4 Stats Monitor" \
false "TELNET" "$TEL" "Telnet Protocol" \
false "PITERM" "$PITERM" "PiQTermTCP Terminal Program" \
false "SECURITY" "$SECURITY" "File Encryption Software" \
false "YGATE" "$YGATE" "Yaesu APRS Software" \
false "BPQ" "$BPQ" "LinBPQ Software" \
false "BATT" "$BATT" "Battery Test Script" \
false "VNC" "$VNC" "VNC Viewer Application" \
--button="Exit":1 \
--button="Install/Update Selected":2 > $UTILITY
BUT=$?