Skip to content

Instantly share code, notes, and snippets.

@jh4xsy
Last active November 11, 2023 02:47
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
satnogs-clientでMETEOR M2-3を処理するpost-observation script
#!/bin/sh
ID="$1"
DATE="$4"
TLE="$3"
NORAD=$(echo "$TLE" | jq .tle2 | awk '{print $2}')
if [ ${NORAD} -ne "57166" ]
then
exit
fi
demod=/usr/local/bin/meteor_demod
decode=/usr/local/bin/meteor_decode
cp /tmp/.satnogs/iq.dat /tmp/${ID}.dat
if [ $(date '+%H') -gt 12 ]; then
# IR-image
${demod} --batch --quiet -O 8 -f 128 -r 72000 -s 160000 -m oqpsk --bps 16 /tmp/${ID}.dat --stdout - | \
${decode} --diff -a 67,67,67 -o /tmp/.satnogs/data/data_${ID}_${DATE}.png -
else
# Visible-image
${demod} --batch --quiet -O 8 -f 128 -r 72000 -s 160000 -m oqpsk --bps 16 /tmp/${ID}.dat --stdout - | \
${decode} --diff -a 65,65,64 -o /tmp/.satnogs/data/data_${ID}_${DATE}.png -
fi
rm -f /tmp/${ID}.dat
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment