Decode SatNOGS audio

master
debian 2019-11-22 11:44:32 -07:00
parent 55c87d071e
commit e2d45cb91a
7 changed files with 227 additions and 0 deletions

View File

@ -1,2 +1,4 @@
# satnogs-cruft
Scripts, etc. for SatNOGS.
https://satnogs.org/

View File

@ -0,0 +1,63 @@
#!/bin/bash
# APRS
# From ISS
# sox -t ogg satnogs_1209115_2019-11-18T03-37-31.ogg -esigned-integer -b 16 -r 48000 -t raw - | direwolf -B 1200 -b 16 -n 1 -r 48000 -q hd -t 0 -q h -q d -d p -d t -a 0 -
redstone-ogg2raw "$1"
echo
rm -f "`basename $1 .ogg`".txt
multimon-ng \
-q \
-t raw \
-a AFSK1200 \
-m \
"`basename $1 .ogg`".raw \
>> \
"`basename $1 .ogg`".txt
cat "`basename $1 .ogg`".txt
rm "`basename $1 .ogg`".raw
echo
exit 0
-q \
-m \
Available demodulators: POCSAG512 POCSAG1200 POCSAG2400 FLEX EAS UFSK1200 CLIPFSK FMSFSK AFSK1200 AFSK2400 AFSK2400_2 AFSK2400_3 HAPN4800 FSK9600 DTMF ZVEI1 ZVEI2 ZVEI3 DZVEI PZVEI EEA EIA CCIR MORSE_CW DUMPCSV X10 SCOPE
Usage: multimon-ng [file] [file] [file] ...
If no [file] is given, input will be read from your default sound
hardware. A filename of "-" denotes standard input.
-t <type> : Input file type (any other type than raw requires sox)
-a <demod> : Add demodulator
-s <demod> : Subtract demodulator
-c : Remove all demodulators (must be added with -a <demod>)
-q : Quiet
-v <level> : Level of verbosity (e.g. '-v 3')
For POCSAG and MORSE_CW '-v1' prints decoding statistics.
-h : This help
-A : APRS mode (TNC2 text output)
-m : Mute SoX warnings
-r : Call SoX in repeatable mode (e.g. fixed random seed for dithering)
-n : Don't flush stdout, increases performance.
-e : POCSAG: Hide empty messages.
-u : POCSAG: Heuristically prune unlikely decodes.
-i : POCSAG: Inverts the input samples. Try this if decoding fails.
-p : POCSAG: Show partially received messages.
-f <mode> : POCSAG: Disables auto-detection and forces decoding of data as <mode>
(<mode> can be 'numeric', 'alpha' and 'skyper')
-b <level> : POCSAG: BCH bit error correction level. Set 0 to disable, default is 2.
Lower levels increase performance and lower false positives.
-C <cs> : POCSAG: Set Charset.
-o : CW: Set threshold for dit detection (default: 500)
-d : CW: Dit length in ms (default: 50)
-g : CW: Gap length in ms (default: 50)
-x : CW: Disable auto threshold detection
-y : CW: Disable auto timing detection
--timestamp: Add a time stamp in front of every printed line
--label : Add a label to the front of every printed line
Raw input requires one channel, 16 bit, signed integer (platform-native)
samples at the demodulator's input sampling rate, which is
usually 22050 Hz. Raw input is assumed and required if piped input is used.

View File

@ -0,0 +1,84 @@
#!/bin/bash
redstone-ogg2raw "$1"
echo
multimon-ng \
-q \
-t raw \
-a AFSK1200 \
-a AFSK2400 \
-a AFSK2400_2 \
-a AFSK2400_3 \
-a CCIR \
-a CLIPFSK \
-a DTMF \
-a DUMPCSV \
-a DZVEI \
-a EAS \
-a EEA \
-a EIA \
-a FLEX \
-a FMSFSK \
-a FSK9600 \
-a HAPN4800 \
-a MORSE_CW \
-a POCSAG512 \
-a POCSAG1200 \
-a POCSAG2400 \
-a PZVEI \
-a UFSK1200 \
-a X10 \
-a ZVEI1 \
-a ZVEI2 \
-a ZVEI3 \
-m \
"`basename $1 .ogg`".raw | \
sed -e "s/^FSK9600: //g" | \
grep -a -v ^fm \
> \
"`basename $1 .ogg`".txt
cat "`basename $1 .ogg`".txt
rm "`basename $1 .ogg`".raw
echo
exit 0
Available demodulators: POCSAG512 POCSAG1200 POCSAG2400 FLEX EAS UFSK1200 CLIPFSK FMSFSK AFSK1200 AFSK2400 AFSK2400_2 AFSK2400_3 HAPN4800 FSK9600 DTMF ZVEI1 ZVEI2 ZVEI3 DZVEI PZVEI EEA EIA CCIR MORSE_CW DUMPCSV X10 SCOPE
Usage: multimon-ng [file] [file] [file] ...
If no [file] is given, input will be read from your default sound
hardware. A filename of "-" denotes standard input.
-t <type> : Input file type (any other type than raw requires sox)
-a <demod> : Add demodulator
-s <demod> : Subtract demodulator
-c : Remove all demodulators (must be added with -a <demod>)
-q : Quiet
-v <level> : Level of verbosity (e.g. '-v 3')
For POCSAG and MORSE_CW '-v1' prints decoding statistics.
-h : This help
-A : APRS mode (TNC2 text output)
-m : Mute SoX warnings
-r : Call SoX in repeatable mode (e.g. fixed random seed for dithering)
-n : Don't flush stdout, increases performance.
-e : POCSAG: Hide empty messages.
-u : POCSAG: Heuristically prune unlikely decodes.
-i : POCSAG: Inverts the input samples. Try this if decoding fails.
-p : POCSAG: Show partially received messages.
-f <mode> : POCSAG: Disables auto-detection and forces decoding of data as <mode>
(<mode> can be 'numeric', 'alpha' and 'skyper')
-b <level> : POCSAG: BCH bit error correction level. Set 0 to disable, default is 2.
Lower levels increase performance and lower false positives.
-C <cs> : POCSAG: Set Charset.
-o : CW: Set threshold for dit detection (default: 500)
-d : CW: Dit length in ms (default: 50)
-g : CW: Gap length in ms (default: 50)
-x : CW: Disable auto threshold detection
-y : CW: Disable auto timing detection
--timestamp: Add a time stamp in front of every printed line
--label : Add a label to the front of every printed line
Raw input requires one channel, 16 bit, signed integer (platform-native)
samples at the demodulator's input sampling rate, which is
usually 22050 Hz. Raw input is assumed and required if piped input is used.

View File

@ -0,0 +1,33 @@
#!/bin/bash
# APRS
# From ISS
# sox -t ogg satnogs_1209115_2019-11-18T03-37-31.ogg -esigned-integer -b 16 -r 48000 -t raw - | direwolf -B 1200 -b 16 -n 1 -r 48000 -q hd -t 0 -q h -q d -d p -d t -a 0 -
set -x
sox \
-t ogg \
$1 \
-esigned-integer \
-b 16 \
-r 48000 \
-t raw - | \
direwolf \
-c /home/jebba/.config/direwolf.conf \
-B 1200 \
-b 16 \
-n 1 \
-r 48000 \
-t 1 \
-a 0 \
-q hd \
-d t \
-
exit 0
-q hd \
-q h \
-q d \
-d p \
-d t \

View File

@ -0,0 +1,17 @@
#!/bin/bash
redstone-ogg2raw "$1"
multimon-ng \
-q \
-m \
-n \
-t raw \
-a MORSE_CW \
"`basename $1 .ogg`".raw > \
"`basename $1 .ogg`".txt
cat "`basename $1 .ogg`".txt
rm "`basename $1 .ogg`".raw

View File

@ -0,0 +1,18 @@
#!/bin/bash
redstone-ogg2raw "$1"
multimon-ng \
-q \
-t raw \
-a FSK9600 \
-m \
"`basename $1 .ogg`".raw | \
sed -e "s/^FSK9600: //g" | \
grep -a -v ^fm \
> \
"`basename $1 .ogg`".txt
cat "`basename $1 .ogg`".txt
rm "`basename $1 .ogg`".raw

View File

@ -0,0 +1,10 @@
#!/bin/bash
#sox $1 -q -G -r 22050 `basename $1 .ogg`.raw gain 0
#sox $1 -q -G -r 22050 `basename $1 .ogg`.raw gain 1
#sox $1 -q -G -r 22050 `basename $1 .ogg`.raw gain 2
#sox $1 -q -G -r 22050 `basename $1 .ogg`.raw gain 3
#sox $1 -q -G -r 22050 `basename $1 .ogg`.raw gain 4
#sox $1 -q -G -r 22050 `basename $1 .ogg`.raw gain 5
sox $1 -q -G -r 22050 `basename $1 .ogg`.raw gain 6 2>/dev/null