Browse Source

added ppm-error config template

pull/131/head
Pascal 3 years ago
parent
commit
4a19066ab8
4 changed files with 9 additions and 4 deletions
  1. +2
    -2
      common.sh
  2. +1
    -1
      schedule_meteor.sh
  3. +4
    -0
      schedule_sat.sh
  4. +2
    -1
      templates/noaa.conf

+ 2
- 2
common.sh View File

@@ -1,4 +1,4 @@
#!/bin/bash
##!/bin/bash

## debug
# set -x
@@ -21,7 +21,7 @@ log() {

#log here
echo "${log_priority} : ${log_message}"
echo $(date '+%d-%m-%Y %H:%M') "${log_priority} : ${log_message}" >> /var/log/noaa.log
echo $(date '+%d-%m-%Y %H:%M') $0 "${log_priority} : ${log_message}" >> /var/log/noaa.log
}

## current date and folder structure


+ 1
- 1
schedule_meteor.sh View File

@@ -18,7 +18,7 @@ var2=$(echo "${PREDICTION_END}" | cut -d " " -f 1)
MAXELEV=$(predict -t "${NOAA_HOME}"/predict/weather.tle -p "${1}" | awk -v max=0 '{if($5>max){max=$5}}END{print max}')

while [ "$(date --date="@${var2}" +%D)" = "$(date +%D)" ]; do
log "Pass prediction in progress" "INFO"
log "Pass prediction for $1 in progress" "INFO"
START_TIME=$(echo "$PREDICTION_START" | cut -d " " -f 3-4)
var1=$(echo "$PREDICTION_START" | cut -d " " -f 1)
var3=$(echo "$START_TIME" | cut -d " " -f 2 | cut -d ":" -f 3)


+ 4
- 0
schedule_sat.sh View File

@@ -25,6 +25,8 @@ var2=$(echo "${PREDICTION_END}" | cut -d " " -f 1)

MAXELEV=$(predict -t "${NOAA_HOME}"/predict/weather.tle -p "${1}" | awk -v max=0 '{if($5>max){max=$5}}END{print max}')

log "Looking for passes of $1" INFO

while [ "$(date --date="@${var2}" +%D)" = "$(date +%D)" ]; do
START_TIME=$(echo "$PREDICTION_START" | cut -d " " -f 3-4)
var1=$(echo "$PREDICTION_START" | cut -d " " -f 1)
@@ -38,6 +40,8 @@ while [ "$(date --date="@${var2}" +%D)" = "$(date +%D)" ]; do
echo "${NOAA_HOME}/receive.sh \"${1}\" $2 ${SATNAME}${OUTDATE} "${NOAA_HOME}"/predict/weather.tle \
${var1} ${TIMER} ${MAXELEV}" | at "$(date --date="TZ=\"UTC\" ${START_TIME}" +"%H:%M %D")"
sqlite3 $HOME/raspberry-noaa/panel.db "insert or replace into predict_passes (sat_name,pass_start,pass_end,max_elev,is_active) values (\"$SATNAME\",$var1,$var2,$MAXELEV, 1);"
else
log "Max. elevation ${MAXELEV} too small for configured ${SAT_MIN_ELEV}" DEBUG
fi
NEXTPREDICT=$(expr "${var2}" + 60)
PREDICTION_START=$(predict -t "${NOAA_HOME}"/predict/weather.tle -p "${1}" "${NEXTPREDICT}" | head -1)


+ 2
- 1
templates/noaa.conf View File

@@ -11,5 +11,6 @@ LON=change_longitude
BIAS_TEE="enable_bias_tee"
DELETE_AUDIO="true"
FLIP_METEOR_IMG="true"
GAIN="-g 50"
GAIN="-g 50" #leave out for auto-gain
PPM_ERROR=0
SCHEDULE_ISS="false"

Loading…
Cancel
Save