From e02a19b72ac60aa6d4c93ea5f25ccc3e6f91b224 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Mon, 11 Dec 2023 18:13:06 -0600 Subject: [PATCH] Update powerwall.sh --- powerwall.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/powerwall.sh b/powerwall.sh index 9620771a..4c9a56fc 100755 --- a/powerwall.sh +++ b/powerwall.sh @@ -246,6 +246,7 @@ CHECKTEMP_SERVICE(){ if [ "${SENSORS_CHECK}" != "" ]; then for SENSOR in "${SENSORS_CHECK[@]}"; do [ "${last_temp[${SENSOR//-/}]}" == "" ] && last_temp[${SENSOR//-/}]=0 + echo "${SENSOR//-/} - ${last_temp[${SENSOR//-/}]}" if [ "${PW_THRESHOLDS[${SENSORa}]}" != "" ]; then echo ${PW_THRESHOLDS[${SENSORa}]} | cut -d',' -f 1 | read temp_warn echo ${PW_THRESHOLDS[${SENSORa}]} | cut -d',' -f 2 | read temp_crit @@ -291,7 +292,7 @@ CHECKTEMP_SERVICE(){ temp_h='' fi - + echo "${SENSOR//-/} - ${last_temp[${SENSOR//-/}]}" logtemp=${PW_LOGFOLDER}/log-temp-${SENSOR} if [ "${temp_c}" != "null" ] && [ "${temp_c}" != "" ]; then [ "${PW_SENSOR_TYPE[${SENSORa}]}" == "cpu" ] && GAUGE="CPU-USAGE" || GAUGE="TEMP" @@ -302,6 +303,7 @@ CHECKTEMP_SERVICE(){ rm -f ${PW_TMPFOLDER}/${SENSOR}-error.reading fi + echo "${SENSOR//-/} - ${last_temp[${SENSOR//-/}]}" [ "${PW_SENSOR_TYPE[${SENSOR}]}" == "cpu" ] && temp_f=$(echo "scale=2; $temp_c/1" | bc -l) || temp_f=$(echo "scale=2; ${temp_c}*1.8 + 32" | bc) [ "${SENSOR}" == "ServerRoomTH" ] && temp_f=`echo "scale=2; ${temp_f}+${PW_ServerRoomTH_Dev}" | bc`