diff --git a/apps/VARA HF/credits b/apps/VARA HF/credits new file mode 100644 index 0000000000..04451aed8e --- /dev/null +++ b/apps/VARA HF/credits @@ -0,0 +1,9 @@ +Added to pi-apps by Eric Wiessner (KI7POL) + +Special thanks: Sebastien "ptitSeb" Chevalier (box86/box64), Esme "madewokherd" Povirk (wine-mono functions), +MarcoDT (Artemis, early programming encouragement), Botspot / theofficialgman (Pi-Apps Wine installer), +everyone who's helped and inspired Winelink (OH8STN, K0SWE, KD2ROS, PE1RRR, LB4PJ, K7MHI, WH6AZ, KM4ACK, KR0SIV), +Pat team (LA5NTA, K0SWE), proof-of-concept Winlink on Linux guides (K6ETA, DCJ21), ARDOP devs (KN6KB, G8BPQ, KG4JJA), +those who got me interested in ham radio (N7ACW, AD7HE, KK6FVG), and everyone who tries to keep ham radio open source. + +"My humanity is bound up in yours, for we can only be human together" - Nelson Mandela diff --git a/apps/VARA HF/description b/apps/VARA HF/description new file mode 100644 index 0000000000..aa5dad8e31 --- /dev/null +++ b/apps/VARA HF/description @@ -0,0 +1,8 @@ +A shareware HF modem for amateur radio messaging. + +VARA modems require a messaging app (such as Pat, Winlink Express, VarAC, or VARAChat), an amateur radio transceiver, and cables to connect audio and PTT control from your Pi to the transceiver. + +Run from Menu: Menu -> Accessories -> VARA +Run from Terminal: wine "C:\VARA\VARA.exe" + +This app runs with the help of box86 and wine. diff --git a/apps/VARA HF/icon-24.png b/apps/VARA HF/icon-24.png new file mode 100644 index 0000000000..0feb9c72ff Binary files /dev/null and b/apps/VARA HF/icon-24.png differ diff --git a/apps/VARA HF/icon-64.png b/apps/VARA HF/icon-64.png new file mode 100644 index 0000000000..55bd93d787 Binary files /dev/null and b/apps/VARA HF/icon-64.png differ diff --git a/apps/VARA HF/install b/apps/VARA HF/install new file mode 100755 index 0000000000..2404b0980b --- /dev/null +++ b/apps/VARA HF/install @@ -0,0 +1,66 @@ +#!/bin/bash + +#version=4.8.7 #version changes often +APPDIR=${HOME}/.local/share/applications + +#Installing wine +if [ $arch == 32 ]; then + "$DIRECTORY/manage" install-if-not-installed 'Wine (x86)' || error 'Failed to install wine' +elif [ $arch == 64 ]; then + "$DIRECTORY/manage" install-if-not-installed 'Wine (x64)' || error 'Failed to install wine' +fi + +#Configuring wineprefix for VARA programs +BOX86_DYNAREC=0 BOX64_DYNAREC=0 BOX86_NOBANNER=1 BOX64_NOBANNER=1 winetricks -q vb6run pdh_nt4 sound=alsa + +#Downloading VARA HF +VARAHFDIR=/tmp/VARAHF +mkdir "${VARAHFDIR}" 2>/dev/null +wget -q -r -l1 -np -nd "https://downloads.winlink.org/VARA%20Products" -A "VARA HF*setup.zip" -P "${VARAHFDIR}" || echo "failed to download" + +#Extracting VARA HF installer archives +unzip -o "${VARAHFDIR}/VARA HF*setup.zip" -d "${VARAHFDIR}" || error 'Failed to unzip VARA HF archive' + +#Running VARA HF setup with autohotkey so we can auto-close its OK button +# note: Instead of installing, we could just extract VARA's program files, copy them into wine, and manually install OCX files, but we would have to know which wineprefix the user is running. +# downloading AutoHotKey +echo -e "Downloading AutoHotKey..." +AHKDIR=/tmp/AHK +mkdir "${AHKDIR}" 2>/dev/null +wget -q "https://github.com/AutoHotkey/AutoHotkey/releases/download/v1.1.36.02/AutoHotkey_1.1.36.02_setup.exe" -P ${AHKDIR} || error 'Failed to download AutoHotKey from Github.' # autohokey v2+ uses different ahk script syntax. winetricks uses autohotkey v1. +# creating varahf_install.ahk (autohotkey script) +echo '; AHK script to make VARA installer run completely silent' > ${VARAHFDIR}/varahf_install.ahk +echo 'SetTitleMatchMode, 2' >> ${VARAHFDIR}/varahf_install.ahk +echo 'SetTitleMatchMode, slow' >> ${VARAHFDIR}/varahf_install.ahk +echo ' Run, VARA setup (Run as Administrator).exe /SILENT /c:"VARA setup (Run as Administrator).exe"' >> ${VARAHFDIR}/varahf_install.ahk +echo ' WinWait, VARA Setup ; Wait for the "VARA installed successfully" window' >> ${VARAHFDIR}/varahf_install.ahk +echo ' ControlClick, Button1, VARA Setup ; Click the OK button' >> ${VARAHFDIR}/varahf_install.ahk +echo ' WinWaitClose' >> ${VARAHFDIR}/varahf_install.ahk +# running varahf_install.ahk +sudo apt-get install -y p7zip-full || error 'Failed to install p7zip-full.' +7z e -y -bsp0 -bso0 ${AHKDIR}/AutoHotkey_1.1.36.02_setup.exe AutoHotkeyU32.exe -o"${VARAHFDIR}" || error 'Failed to extract AutoHotKey archive.' +echo -e "\nInstalling VARA HF . . ." +BOX86_DYNAREC=0 BOX86_NOBANNER=1 BOX86_DYNAREC_BIGBLOCK=0 WINEDEBUG=-all wine ${VARAHFDIR}/AutoHotkeyU32.exe ${VARAHFDIR}/varahf_install.ahk || error 'AutoHotKey failed to launch.' + +#Removing tmp files +rm -rf ${AHKDIR} ${VARAHFDIR} + +#Adding the user to the USB dialout group so that they can access radio USB CAT control later. +sudo usermod -a -G dialout $USER + +#Creating Desktop Entry +mkdir -p $APPDIR/VARA +echo "[Desktop Entry] +Name=VARA HF +GenericName=VARA HF +Comment=VARA HF is a shareware ham radio OFDM software modem for RMS Express and other messaging clients. +Exec=env WINEDEBUG=-all wine \"C:\\VARA\\VARA.exe\" +Icon=$(dirname "$0")/icon-64.png +Terminal=false +StartupNotify=false +Type=Application +StartupWMClass=vara.exe +Categories=Utility;" > $APPDIR/VARA/varahf.desktop || error 'Failed to create menu button!' +sudo rm -rf ${APPDIR}/wine/Programs/VARA # remove wine's auto-generated VARA HF program icon from the start menu + +exit diff --git a/apps/VARA HF/uninstall b/apps/VARA HF/uninstall new file mode 100755 index 0000000000..99d510b0b0 --- /dev/null +++ b/apps/VARA HF/uninstall @@ -0,0 +1,17 @@ +#!/bin/bash + +APPDIR=${HOME}/.local/share/applications +WINEDIR=${HOME}/.wine + +#Unregistering OCX/DLL files from your wineprefix +BOX86_NOBANNER=1 BOX64_NOBANNER=1 WINEDEBUG=-all wine regsvr32 ${WINEDIR}/drive_c/VARA/OCX/* /u /s # note: some DLL's don't have built-in register/unregister functions and will error + +#Removing program files (keeping any VARA.ini settings files) +mv ${WINEDIR}/drive_c/VARA/VARA.ini /tmp/VARA.ini 2>/dev/null +rm -rf ${WINEDIR}/drive_c/VARA/* 2>/dev/null || error 'Could not remove VARA program files.' +mv /tmp/VARA.ini ${WINEDIR}/drive_c/VARA/VARA.ini 2>/dev/null +if [ $(ls -A "${WINEDIR}/drive_c/VARA" | wc -l) -eq 0 ]; then rm -rf "${WINEDIR}/drive_c/VARA" 2>/dev/null; fi #also delete directory if empty + +#Removing Desktop Entry +rm ${APPDIR}/VARA/varahf.desktop 2>/dev/null || echo "Could not remove menu button." +if [ $(ls -A "${APPDIR}/VARA" | wc -l) -eq 0 ]; then rm -rf "${APPDIR}/VARA" 2>/dev/null; fi #also delete directory if empty diff --git a/apps/VARA HF/website b/apps/VARA HF/website new file mode 100644 index 0000000000..87aef5c824 --- /dev/null +++ b/apps/VARA HF/website @@ -0,0 +1 @@ +https://rosmodem.wordpress.com/ diff --git a/etc/categories b/etc/categories index d74d72bc2f..1fd4bd2b2b 100644 --- a/etc/categories +++ b/etc/categories @@ -204,6 +204,7 @@ Ulauncher|Appearance Unciv|Games Update Buddy|System Management USBImager|Tools +VARA HF|Engineering VeraCrypt|Tools Visual Studio Code|Programming Vivaldi|Internet/Browsers