From 1e32f9633b43b284b47d8507f325925afbc9257d Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Mon, 11 Dec 2023 17:44:32 -0600 Subject: [PATCH] Update powerwall.sh --- powerwall.sh | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/powerwall.sh b/powerwall.sh index 304cbdd6..cbabe655 100755 --- a/powerwall.sh +++ b/powerwall.sh @@ -318,14 +318,13 @@ CHECKTEMP_SERVICE(){ if (( $(bc <<< "${temp_f} < ${temp_warn}") )); then echo 2 if (( $(bc <<< "${last_temp[${SENSOR}]} > 1") )); then - echo 3 SENDNOTICE "${SENSOR} BACK TO NORMAL" "NORMAL TEMP: ${temp_f}${GAUGESH} Previous Temp: ${last_temp[${SENSOR}]}${GAUGESH}" echo -e "($(date +'%Y-%m-%d %H:%M:%S')) - ${temp_f}${GAUGESH} - Back to NORMAL ${GAUGE} - Previous ${GAUGE}: ${last_temp[${SENSOR}]}${GAUGESH}" >> ${logtemp} echo -e "($(date +'%Y-%m-%d %H:%M:%S')) - ${temp_f}${GAUGESH} - ${SENSOR} - Back to NORMAL ${GAUGE}" >> ${PW_LOGFILE} # [ "$(compgen -G "${PW_TMPFOLDER}/power.*.off")" != "" ] && rm -f ${PW_TMPFOLDER}/power.*.off - elif (( $(bc <<< "${temp_diff} = 0") )); then + elif (( $(bc <<< "${last_temp[${SENSOR}]} = 0") )); then echo 4 # SENDNOTICE "${SENSOR} TEMP NORMAL" "Service Startup # NORMAL TEMP: ${temp_f}${GAUGESH}" @@ -334,11 +333,9 @@ Previous Temp: ${last_temp[${SENSOR}]}${GAUGESH}" # [ "$(compgen -G "${PW_TMPFOLDER}/power.*.off")" != "" ] && rm -f ${PW_TMPFOLDER}/power.*.off elif [ "${relog}" == "1" ]; then - echo 5 echo "($(date +'%Y-%m-%d %H:%M:%S')) - ${temp_f}${GAUGESH} - Normal ${GAUGE}" >> ${logtemp} fi - echo 6 rm -f ${PW_TMPFOLDER}/temp.* rm -f ${PW_TMPFOLDER}/power.${SENSORa}.off last_temp[${SENSOR}]=1