mirror of
https://github.com/thetechprepper/emcomm-tools-os-community.git
synced 2026-09-17 15:41:44 -04:00
Merged feature/direwolf-packet-digipeater for ETC R3 Build #16
This commit is contained in:
+7
-6
@@ -1,21 +1,22 @@
|
|||||||
# Author : Gaston Gonzalez
|
# Author : Gaston Gonzalez
|
||||||
# Date : 6 November 2024
|
# Date : 6 November 2024
|
||||||
# Purpose : User systemd unit file for EmComm Tools Dire Wolf digipeater packet
|
# Updated : 8 November
|
||||||
|
# Purpose : User systemd unit file for EmComm Tools Dire Wolf APRS digipeater packet
|
||||||
# : service.
|
# : service.
|
||||||
#
|
#
|
||||||
# Usage:
|
# Usage:
|
||||||
# Check status : systemctl --user status et-service-direwolf-digipeater
|
# Check status : systemctl --user status et-service-direwolf-aprs-digipeater
|
||||||
# Start service : systemctl --user start et-service-direwolf-digipeater
|
# Start service : systemctl --user start et-service-direwolf-aprs-digipeater
|
||||||
# Stop service : systemctl --user stop et-service-direwolf-digipeater
|
# Stop service : systemctl --user stop et-service-direwolf-aprs-digipeater
|
||||||
# Reload this config : systemctl --user daemon-reload
|
# Reload this config : systemctl --user daemon-reload
|
||||||
|
|
||||||
[Unit]
|
[Unit]
|
||||||
Description=EmComm Tools Dire Wolf simple packet service
|
Description=EmComm Tools Dire Wolf APRS digipeater service
|
||||||
# Disable conditional check for audio device. Allow et-ardop to enforce.
|
# Disable conditional check for audio device. Allow et-ardop to enforce.
|
||||||
#ConditionPathExists=/dev/et-audio
|
#ConditionPathExists=/dev/et-audio
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
ExecStart=/opt/emcomm-tools/bin/et-direwolf start digipeater
|
ExecStart=/opt/emcomm-tools/bin/et-direwolf start aprs-digipeater
|
||||||
Restart=no
|
Restart=no
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
# Author : Gaston Gonzalez
|
||||||
|
# Date : 8 November 2024
|
||||||
|
# Purpose : User systemd unit file for EmComm Tools Dire Wolf packet digipeater packet
|
||||||
|
# : service.
|
||||||
|
#
|
||||||
|
# Usage:
|
||||||
|
# Check status : systemctl --user status et-service-direwolf-packet-digipeater
|
||||||
|
# Start service : systemctl --user start et-service-direwolf-packet-digipeater
|
||||||
|
# Stop service : systemctl --user stop et-service-direwolf-packet-digipeater
|
||||||
|
# Reload this config : systemctl --user daemon-reload
|
||||||
|
|
||||||
|
[Unit]
|
||||||
|
Description=EmComm Tools Dire Wolf packet digipeater service
|
||||||
|
# Disable conditional check for audio device. Allow et-ardop to enforce.
|
||||||
|
#ConditionPathExists=/dev/et-audio
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
ExecStart=/opt/emcomm-tools/bin/et-direwolf start packet-digipeater
|
||||||
|
Restart=no
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
@@ -40,9 +40,9 @@ ${font DejaVu Sans:bold:size=10}${color #8d5133}${alignc}OPERATOR
|
|||||||
${font DejaVu Sans Mono:size=11}${color yellow}Callsign: ${execpi 10 et-system-info callsign}
|
${font DejaVu Sans Mono:size=11}${color yellow}Callsign: ${execpi 10 et-system-info callsign}
|
||||||
Grid : ${execpi 10 et-system-info grid}
|
Grid : ${execpi 10 et-system-info grid}
|
||||||
|
|
||||||
${font DejaVu Sans:bold:size=10}${color #8d5133}${alignc}MODE
|
${font DejaVu Sans:bold:size=10}${color white}${alignc}MODE
|
||||||
${font DejaVu Sans:bold:size=11}${color red}${alignc}${execpi 10 et-system-info et-mode}
|
${font DejaVu Sans:bold:size=11}${color red}${alignc}${execpi 10 et-system-info et-mode}
|
||||||
|
|
||||||
${font DejaVu Sans:bold:size=9}${color white}${alignc}${execp /opt/emcomm-tools/bin/et-system-info release}
|
${font DejaVu Sans:bold:size=9}${color grey}${alignc}${execp /opt/emcomm-tools/bin/et-system-info release}
|
||||||
]];
|
]];
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
# Author : Gaston Gonzalez
|
# Author : Gaston Gonzalez
|
||||||
# Date : 1 November 2024
|
# Date : 1 November 2024
|
||||||
# Updated : 7 November 2024
|
# Updated : 8 November 2024
|
||||||
# Purpose : Wrapper script for starting Dire Wolf with PnP support
|
# Purpose : Wrapper script for starting Dire Wolf with PnP support
|
||||||
#
|
#
|
||||||
# Preconditions:
|
# Preconditions:
|
||||||
@@ -21,7 +21,8 @@ usage() {
|
|||||||
echo " update-config - Update configuration for selected mode"
|
echo " update-config - Update configuration for selected mode"
|
||||||
echo ""
|
echo ""
|
||||||
echo " <type>"
|
echo " <type>"
|
||||||
echo " digipeater - Run in RF-only digipeater mode"
|
echo " aprs-digipeater - Run in RF-only APRS digipeater mode"
|
||||||
|
echo " packet-digipeater - Run in RF-only packet digipeater mode"
|
||||||
echo " simple - Run in simple packet mode"
|
echo " simple - Run in simple packet mode"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -32,7 +33,10 @@ fi
|
|||||||
|
|
||||||
MODE=$2
|
MODE=$2
|
||||||
case "${MODE}" in
|
case "${MODE}" in
|
||||||
digipeater)
|
aprs-digipeater)
|
||||||
|
DIREWOLF_TEMPLATE_CONF_FILE="${ET_HOME}/conf/template.d/packet/direwolf.${MODE}.conf"
|
||||||
|
;;
|
||||||
|
packet-digipeater)
|
||||||
DIREWOLF_TEMPLATE_CONF_FILE="${ET_HOME}/conf/template.d/packet/direwolf.${MODE}.conf"
|
DIREWOLF_TEMPLATE_CONF_FILE="${ET_HOME}/conf/template.d/packet/direwolf.${MODE}.conf"
|
||||||
;;
|
;;
|
||||||
simple)
|
simple)
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
# Author : Gaston Gonzalez
|
# Author : Gaston Gonzalez
|
||||||
# Date : 6 November 2024
|
# Date : 6 November 2024
|
||||||
# Updated : 7 November 2024
|
# Updated : 8 November 2024
|
||||||
# Purpose : Configures the system for a specific mode of operation
|
# Purpose : Configures the system for a specific mode of operation
|
||||||
|
|
||||||
# Use a simple text file to save the state of the last mode selected
|
# Use a simple text file to save the state of the last mode selected
|
||||||
@@ -12,17 +12,19 @@ MODE_STATUS_FILE="${HOME}/.config/emcomm-tools/et-mode"
|
|||||||
MODE_ID_NONE="none"
|
MODE_ID_NONE="none"
|
||||||
MODE_ID_APRS_DIGIPEATER="aprs-digipeater"
|
MODE_ID_APRS_DIGIPEATER="aprs-digipeater"
|
||||||
MODE_ID_APRS_CLIENT="aprs-client"
|
MODE_ID_APRS_CLIENT="aprs-client"
|
||||||
|
MODE_ID_PACKET_DIGIPEATER="packet-digipeater"
|
||||||
MODE_ID_WINLINK_ARDOP="winlink-ardop"
|
MODE_ID_WINLINK_ARDOP="winlink-ardop"
|
||||||
MODE_ID_WINLINK_PACKET="winlink-packet"
|
MODE_ID_WINLINK_PACKET="winlink-packet"
|
||||||
|
|
||||||
# 1. Attempt to stop all EmComm Tools services regardless if they are running.
|
# 1. Attempt to stop all EmComm Tools services regardless if they are running.
|
||||||
# 2. Stop the applications first, then the modems
|
# 2. Stop the applications first, then the modems.
|
||||||
stop_all_services() {
|
stop_all_services() {
|
||||||
systemctl --user stop et-service-winlink-ardop
|
systemctl --user stop et-service-winlink-ardop
|
||||||
systemctl --user stop et-service-winlink-packet
|
systemctl --user stop et-service-winlink-packet
|
||||||
systemctl --user stop et-service-ardop
|
systemctl --user stop et-service-ardop
|
||||||
systemctl --user stop et-service-direwolf-simple
|
systemctl --user stop et-service-direwolf-simple
|
||||||
systemctl --user stop et-service-direwolf-digipeater
|
systemctl --user stop et-service-direwolf-aprs-digipeater
|
||||||
|
systemctl --user stop et-service-direwolf-packet-digipeater
|
||||||
}
|
}
|
||||||
|
|
||||||
exit_on_service_failure() {
|
exit_on_service_failure() {
|
||||||
@@ -69,11 +71,12 @@ options=()
|
|||||||
options+=("${MODE_ID_NONE}" "No mode selected")
|
options+=("${MODE_ID_NONE}" "No mode selected")
|
||||||
options+=("${MODE_ID_APRS_CLIENT}" "APRS Client (YAAC)")
|
options+=("${MODE_ID_APRS_CLIENT}" "APRS Client (YAAC)")
|
||||||
options+=("${MODE_ID_APRS_DIGIPEATER}" "APRS Digipeater")
|
options+=("${MODE_ID_APRS_DIGIPEATER}" "APRS Digipeater")
|
||||||
|
options+=("${MODE_ID_PACKET_DIGIPEATER}" "Packet Digipeater")
|
||||||
options+=("${MODE_ID_WINLINK_ARDOP}" "Winlink ARDOP")
|
options+=("${MODE_ID_WINLINK_ARDOP}" "Winlink ARDOP")
|
||||||
options+=("${MODE_ID_WINLINK_PACKET}" "Winlink Packet")
|
options+=("${MODE_ID_WINLINK_PACKET}" "Winlink Packet")
|
||||||
|
|
||||||
# Prompt user for option and save exit status
|
# Prompt user for option and save exit status
|
||||||
SELECTED_MODE=$(dialog --clear --menu "Select a mode:" 30 40 10 "${options[@]}" 3>&1 1>&2 2>&3)
|
SELECTED_MODE=$(dialog --clear --menu "Select a mode:" 15 50 10 "${options[@]}" 3>&1 1>&2 2>&3)
|
||||||
exit_status=$?
|
exit_status=$?
|
||||||
|
|
||||||
tput sgr 0 && clear
|
tput sgr 0 && clear
|
||||||
@@ -89,13 +92,17 @@ if [ $exit_status -eq 0 ]; then
|
|||||||
et-log "No mode selected"
|
et-log "No mode selected"
|
||||||
;;
|
;;
|
||||||
${MODE_ID_APRS_DIGIPEATER})
|
${MODE_ID_APRS_DIGIPEATER})
|
||||||
systemctl --user start et-service-direwolf-digipeater
|
systemctl --user start et-service-direwolf-aprs-digipeater
|
||||||
et-log "APRS digipeater now running."
|
et-log "APRS digipeater now running."
|
||||||
;;
|
;;
|
||||||
${MODE_ID_APRS_CLIENT})
|
${MODE_ID_APRS_CLIENT})
|
||||||
start_and_wait_for_service et-service-direwolf-simple
|
start_and_wait_for_service et-service-direwolf-simple
|
||||||
et-yaac start
|
et-yaac start
|
||||||
;;
|
;;
|
||||||
|
${MODE_ID_PACKET_DIGIPEATER})
|
||||||
|
systemctl --user start et-service-direwolf-packet-digipeater
|
||||||
|
et-log "Packet digipeater now running."
|
||||||
|
;;
|
||||||
${MODE_ID_WINLINK_ARDOP})
|
${MODE_ID_WINLINK_ARDOP})
|
||||||
start_and_wait_for_service et-service-ardop
|
start_and_wait_for_service et-service-ardop
|
||||||
start_and_wait_for_service et-service-winlink-ardop
|
start_and_wait_for_service et-service-winlink-ardop
|
||||||
@@ -112,7 +119,6 @@ if [ $exit_status -eq 0 ]; then
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
|
||||||
else
|
else
|
||||||
et-log "No mode selected"
|
et-log "No mode selected"
|
||||||
echo ${MODE_ID_NONE} > ${MODE_STATUS_FILE}
|
echo ${MODE_ID_NONE} > ${MODE_STATUS_FILE}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
# Author : Gaston Gonzalez
|
# Author : Gaston Gonzalez
|
||||||
# Date : 6 October 2024
|
# Date : 6 October 2024
|
||||||
# Updated : 7 November 2024
|
# Updated : 8 November 2024
|
||||||
# Purpose : Utility script for dumping system information
|
# Purpose : Utility script for dumping system information
|
||||||
|
|
||||||
function usage() {
|
function usage() {
|
||||||
@@ -175,6 +175,7 @@ case $1 in
|
|||||||
|
|
||||||
MODE_ID_NONE="none"
|
MODE_ID_NONE="none"
|
||||||
MODE_ID_APRS_DIGIPEATER="aprs-digipeater"
|
MODE_ID_APRS_DIGIPEATER="aprs-digipeater"
|
||||||
|
MODE_ID_PACKET_DIGIPEATER="packet-digipeater"
|
||||||
MODE_ID_APRS_CLIENT="aprs-client"
|
MODE_ID_APRS_CLIENT="aprs-client"
|
||||||
MODE_ID_WINLINK_ARDOP="winlink-ardop"
|
MODE_ID_WINLINK_ARDOP="winlink-ardop"
|
||||||
MODE_ID_WINLINK_PACKET="winlink-packet"
|
MODE_ID_WINLINK_PACKET="winlink-packet"
|
||||||
@@ -190,11 +191,14 @@ case $1 in
|
|||||||
echo "Run 'et-mode' to set"
|
echo "Run 'et-mode' to set"
|
||||||
;;
|
;;
|
||||||
${MODE_ID_APRS_DIGIPEATER})
|
${MODE_ID_APRS_DIGIPEATER})
|
||||||
echo "Digipeater"
|
echo "APRS Digipeater"
|
||||||
;;
|
;;
|
||||||
${MODE_ID_APRS_CLIENT})
|
${MODE_ID_APRS_CLIENT})
|
||||||
echo "APRS"
|
echo "APRS"
|
||||||
;;
|
;;
|
||||||
|
${MODE_ID_PACKET_DIGIPEATER})
|
||||||
|
echo "Packet Digipeater"
|
||||||
|
;;
|
||||||
${MODE_ID_WINLINK_ARDOP})
|
${MODE_ID_WINLINK_ARDOP})
|
||||||
echo "Winlink ARDOP"
|
echo "Winlink ARDOP"
|
||||||
;;
|
;;
|
||||||
|
|||||||
@@ -0,0 +1,26 @@
|
|||||||
|
# Author : Gaston Gonzalez
|
||||||
|
# Date : 8 November 2024
|
||||||
|
# Purpose : Dire Wolf template for RF-only packet digipeater operation
|
||||||
|
# A big thanks to Jason KM4ACK for introducing me to CBEACON
|
||||||
|
# as I was about to add linbpq just to support a digipeater
|
||||||
|
|
||||||
|
# Audio settings
|
||||||
|
ADEVICE {{ET_AUDIO_DEVICE}}
|
||||||
|
CHANNEL 0
|
||||||
|
|
||||||
|
# User settings
|
||||||
|
MYCALL {{ET_CALLSIGN}}-2
|
||||||
|
|
||||||
|
# Modem settings
|
||||||
|
MODEM 1200
|
||||||
|
|
||||||
|
# Rig control settings. Do not change this.
|
||||||
|
# EmComm Tools uses Hamlib's rig control daemon for all radio interfaces.
|
||||||
|
PTT RIG 2 localhost:4532
|
||||||
|
|
||||||
|
# Enable ports to allow other applications use Dire Wolf as the packet engine
|
||||||
|
AGWPORT 8000
|
||||||
|
KISSPORT 8001
|
||||||
|
|
||||||
|
CBEACON delay=1 every=30 overlay=S symbol="digi" 28 info="EmComm Tools packet digi" via=WIDE1-1
|
||||||
|
CDIGIPEAT 0 0
|
||||||
+12
-2
@@ -1,15 +1,25 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# Author : Gaston Gonzalez
|
# Author : Gaston Gonzalez
|
||||||
# Date : 3 November 2024
|
# Date : 3 November 2024
|
||||||
|
# Updated : 8 November 2024
|
||||||
# Purpose : Post installation validation script
|
# Purpose : Post installation validation script
|
||||||
|
|
||||||
PATH=.:$PATH
|
PATH=.:$PATH
|
||||||
|
|
||||||
|
YELLOW="\033[1;33m"
|
||||||
|
GREEN="\033[0;32m"
|
||||||
|
RED="\033[0;31m"
|
||||||
|
NC="\033[0m"
|
||||||
|
|
||||||
|
echo -e "${YELLOW}---------------------------------------"
|
||||||
|
echo "EmComm Tools Post Validation Test Suite"
|
||||||
|
echo -e "---------------------------------------${NC}"
|
||||||
|
|
||||||
ls test-*.sh | while read test_case; do
|
ls test-*.sh | while read test_case; do
|
||||||
eval ${test_case}
|
eval ${test_case}
|
||||||
if [[ $? -eq 0 ]]; then
|
if [[ $? -eq 0 ]]; then
|
||||||
printf "%20s %s\n" "${test_case}" "[PASSED]"
|
printf "%20s ${GREEN}%s${NC}\n" "${test_case}" "[PASSED]"
|
||||||
else
|
else
|
||||||
printf "%20s %s\n" "${test_case}" "[FAILED]"
|
printf "%20s ${RED}%s${NC}\n" "${test_case}" "[FAILED]"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|||||||
Executable
+7
@@ -0,0 +1,7 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# Author : Gaston Gonzalez
|
||||||
|
# Date : 8 November 2024
|
||||||
|
# Purpose : Test direwolf installation
|
||||||
|
|
||||||
|
OUT=$(which direwolf)
|
||||||
|
exit $?
|
||||||
Reference in New Issue
Block a user