How can you run two post observation scripts?

I would like to run commands to turn off the Bias T and also the script to upload raw IQ files to Dropbox.
Is it just a matter of using a semicolon or & ?

I want to combine

/home/pi/rtl-sdr-blog/build/src/rtl_biast -b 0

with

/usr/local/bin/satnogs-post {{ID}} {{FREQ}} {{TLE}} {{TIMESTAMP}} {{BAUD}} {{SCRIPT_NAME}}

Just create a single script that calls the two scripts?

2 Likes

sometimes the obvious answer is the best. thank you

1 Like

so just combine them into one like this, and pass the same arguments?

#!/bin/bash
RC_REMOTE=remote
DB_DIR=IQ_files
if [ -n “$IQ_DUMP_FILENAME” ] && [ -f “$IQ_DUMP_FILENAME” ]
then
SATNAME=$(echo “$3” | jq .tle0 | sed -e ‘s/ //g’ | sed -e 's/[^A-Za-z0-9.-]
//g’)
IQ_DIR=$(dirname “${IQ_DUMP_FILENAME}”)
IQ_NAME=“$1”_“$SATNAME”.wav.xz
IQ_FILE=“$IQ_DIR”/“$IQ_NAME”
TEMPFILE=$(mktemp -p /tmp/.satnogs/)
mv “$IQ_DUMP_FILENAME” “$TEMPFILE”
nice -n19 xz -c -6 -T2 “$TEMPFILE” > “$IQ_FILE” && rm “$TEMPFILE”
rclone move “$IQ_FILE” “$RC_REMOTE:$DB_DIR”
fi
/home/pi/rtl-sdr-blog/build/src/rtl_biast -b 0

Looks good, but I wouldn’t trust a visual inspection. Run it to make sure it does what you want.

I will once I figure out the remaining command to convert the IQ file into one that can be used by SDR sharp… thank you for your help earlier