From 43bdc6e2c6b3c998f96146e968cccbbac069ccf1 Mon Sep 17 00:00:00 2001 From: Nico Rey Date: Thu, 20 Aug 2020 18:49:52 -0300 Subject: [PATCH] Add testing tool and usage guide --- test_reception.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/test_reception.sh b/test_reception.sh index efdec6a..f20e8da 100755 --- a/test_reception.sh +++ b/test_reception.sh @@ -7,7 +7,7 @@ fi command_exists() { if ! command -v "$1" &> /dev/null; then - echo "Required command not found: $1" + log "Required command not found: $1" "ERROR" exit 1 fi } @@ -21,6 +21,12 @@ command_exists "socat" IP=$(ip route | grep "link src" | awk {'print $NF'}) +if pgrep "rtl_fm" > /dev/null +then + log "There is an existing rtl_fm instance running, I quit" "ERROR" + exit 1 +fi + echo "$(tput setaf 2) The server is in testing mode tuned to $1 Mhz! Open a terminal in your computer and paste: