Winlink - Enable listener for both AX.25 and ARDOP when the corresponding mode is started. Allows for P2P use

This commit is contained in:
Gaston Gonzalez
2024-12-12 15:41:26 -07:00
parent 4d5e433a3e
commit 1332b2290d
2 changed files with 27 additions and 21 deletions
+1 -1
View File
@@ -13,7 +13,7 @@
"connect_aliases": { "connect_aliases": {
"telnet": "telnet://{mycall}:CMSTelnet@cms.winlink.org:8772/wl2k" "telnet": "telnet://{mycall}:CMSTelnet@cms.winlink.org:8772/wl2k"
}, },
"listen": [], "listen": [ "{{ET_WINLINK_LISTEN}}" ],
"hamlib_rigs": { "hamlib_rigs": {
"et-rig": { "et-rig": {
"address": "localhost:4532", "address": "localhost:4532",
+13 -7
View File
@@ -2,7 +2,7 @@
# #
# Author : Gaston Gonzalez # Author : Gaston Gonzalez
# Date : 4 November 2024 # Date : 4 November 2024
# Updated : 5 November 2024 # Updated : 12 December 2024
# Purpose : Wrapper script for starting YAAC with PnP support # Purpose : Wrapper script for starting YAAC with PnP support
# #
# Preconditions: # Preconditions:
@@ -21,7 +21,6 @@ usage() {
echo " <command>" echo " <command>"
echo " start-ardop - Start Pat Winlink in ardop mode" echo " start-ardop - Start Pat Winlink in ardop mode"
echo " start-packet - Start Pat Winlink in packet mode" echo " start-packet - Start Pat Winlink in packet mode"
echo " update-config - Update configuration for selected mode"
} }
if [ $# -ne 1 ]; then if [ $# -ne 1 ]; then
@@ -45,7 +44,7 @@ start_ardop() {
exit 1 exit 1
fi fi
update_config update_config ardop
CMD="pat http" CMD="pat http"
et-log "Starting Pat with: ${CMD}" et-log "Starting Pat with: ${CMD}"
@@ -62,7 +61,7 @@ start_packet() {
exit 1 exit 1
fi fi
update_config update_config packet
CMD="pat http" CMD="pat http"
et-log "Starting Pat with: ${CMD}" et-log "Starting Pat with: ${CMD}"
@@ -89,6 +88,16 @@ update_config () {
sed -i "s|{{ET_CALLSIGN}}|${CALLSIGN}|g" ${PAT_CONF_FILE} sed -i "s|{{ET_CALLSIGN}}|${CALLSIGN}|g" ${PAT_CONF_FILE}
sed -i "s|{{ET_WINLINK_PASSWD}}|${WINLINK_PASSWD}|g" ${PAT_CONF_FILE} sed -i "s|{{ET_WINLINK_PASSWD}}|${WINLINK_PASSWD}|g" ${PAT_CONF_FILE}
sed -i "s|{{ET_GRID}}|${GRID}|g" ${PAT_CONF_FILE} sed -i "s|{{ET_GRID}}|${GRID}|g" ${PAT_CONF_FILE}
# Enable the P2P listener for the current mode selected (ARDOP or AX.25)
case $1 in
ardop)
sed -i "s|{{ET_WINLINK_LISTEN}}|ardop|g" ${PAT_CONF_FILE}
;;
packet)
sed -i "s|{{ET_WINLINK_LISTEN}}|ax25|g" ${PAT_CONF_FILE}
;;
esac
} }
case $1 in case $1 in
@@ -98,9 +107,6 @@ case $1 in
start-packet) start-packet)
start_packet start_packet
;; ;;
update-config)
update_config
;;
*) *)
echo "Invalid command." echo "Invalid command."
usage usage