From f500382b0f2fe79ad865d731c2b34c077320fad0 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Sat, 13 Sep 2025 19:54:54 -0500 Subject: [PATCH] Update temp.inc.sh --- inc/temp.inc.sh | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/inc/temp.inc.sh b/inc/temp.inc.sh index 7f79d73a..bfaf1e85 100644 --- a/inc/temp.inc.sh +++ b/inc/temp.inc.sh @@ -126,7 +126,7 @@ CHECKTEMP(){ [ ${REPORT} -eq 0 ] && echo -en "\r\033[K${idsCL[White]}${idsST[Bold]}${SENSOR_DESC}${idsST[Reset]}${spc}${idsCL[Default]}: ${idsCL[Yellow]}Pulling data ... " if [ ! -f ${PW_TMPFOLDER}/${SENSOR}.down ]; then - CHECKTEMPSENSOR ${SENSOR} + # CHECKTEMPSENSOR ${SENSOR} IFS=: read -r temp_f temp_h <<< $(CHECKTEMPSENSOR ${SENSOR}); unset IFS if [ "${temp_f}" != "timeout" ] && [ "${temp_f}" != "offline" ]; then [ "${PW_SENSOR_TYPE[${SENSOR}]}" == "system" ] && [[ "${SENSOR}" = *"FAN"* ]] && temp_f_disp=$(IDS_NUMBER_FORMAT ${temp_f} 0) || temp_f_disp=${temp_f} @@ -712,19 +712,12 @@ CHECKTEMPSENSOR(){ if ! temp_c=$(curl -m 8 -s -u "${PW_ESP_USER}:${PW_ESP_PASS}" http://${PW_REMOTE_SENSORS[${1}]}:8090/sensor/${PW_SENSOR_DEVICEID[${1}]} | jq '.value'); then TIMEOUT=1; fi if [ "${temp_c}" != "" ]; then if [ "${1}" == "ServerRoom_Monitor_Front" ]; then - echo "\"${PW_ESP_USER}:${PW_ESP_PASS}\" http://${PW_REMOTE_SENSORS[${1}]}:8090/sensor/front_humidity | jq '.value" - curl -m 8 -s -u "${PW_ESP_USER}:${PW_ESP_PASS}" http://${PW_REMOTE_SENSORS[${1}]}:8090/sensor/front_humidity | jq '.value' temp_h=`IDS_NUMBER_FORMAT $(curl -m 8 -s -u "${PW_ESP_USER}:${PW_ESP_PASS}" http://${PW_REMOTE_SENSORS[${1}]}:8090/sensor/front_humidity | jq '.value') 2 yes` - echo "1: $temp_h" elif [ "${1}" == "ServerRoom_Monitor_Back" ]; then - echo "\"${PW_ESP_USER}:${PW_ESP_PASS}\" http://${PW_REMOTE_SENSORS[${1}]}:8090/sensor/back_humidity | jq '.value" - curl -m 8 -s -u "${PW_ESP_USER}:${PW_ESP_PASS}" http://${PW_REMOTE_SENSORS[${1}]}:8090/sensor/back_humidity | jq '.value' temp_h=`IDS_NUMBER_FORMAT $(curl -m 8 -s -u "${PW_ESP_USER}:${PW_ESP_PASS}" http://${PW_REMOTE_SENSORS[${1}]}:8090/sensor/back_humidity | jq '.value') 2 yes` - echo "2: $temp_h" else temp_h=`IDS_NUMBER_FORMAT $(curl -m 8 -s -u "${PW_ESP_USER}:${PW_ESP_PASS}" http://${PW_REMOTE_SENSORS[${1}]}:8090/sensor/${PW_SENSOR_DEVICEID[${1}]/temperature/humidity} | jq '.value') 2 yes` fi - echo "3: $temp_h" fi elif [ "${PW_SENSOR_TYPE[${1}]}" == "tuya" ]; then IFS=: read -r temp_c temp_h <<< $(GET_TUYA_TEMP ${1}); unset IFS