diff --git a/inc/temp.inc.sh b/inc/temp.inc.sh index 0af42a7e..529abb47 100644 --- a/inc/temp.inc.sh +++ b/inc/temp.inc.sh @@ -81,7 +81,7 @@ CHECKTEMP(){ reading=$(CHECKTEMPSENSOR ${SENSOR} . . . . ${avgdays}) echo -e "\r\033[K${idsCL[White]}${idsST[Bold]}${SENSOR}${idsST[Reset]}${spc}${idsCL[Default]}: ${reading}${idsCL[Default]}" else - echo -e "\r\033[K${idsCL[White]}${idsST[Bold]}${SENSOR}${idsST[Reset]}${spc}${idsCL[Default]}: ${idsCL[Yellow]}Sensor Offline1${idsCL[Default]}" + echo -e "\r\033[K${idsCL[White]}${idsST[Bold]}${SENSOR}${idsST[Reset]}${spc}${idsCL[Default]}: ${idsCL[Yellow]}Sensor Offline${idsCL[Default]}" fi echo fi @@ -119,12 +119,16 @@ CHECKTEMPSENSOR(){ temp_probe_c=`IDS_NUMBER_FORMAT $(echo ${INFO} | jq -r '.device0 .obs[].probe_temp') 2 yes` elif [ "${PW_SENSOR_TYPE[${1}]}" == "system" ]; then + echo "H1: ${1}" if [[ "${1}" = %"CPU"% ]]; then + echo 1 temp_c=$(vcgencmd measure_temp) temp_c=${temp_c%\'*}; temp_c=${temp_c#*=} elif [[ "${1}" = %"FAN"% ]]; then + echo 2 temp_c=$(cat /sys/class/hwmon/hwmon2/fan1_input) fi + echo 3 elif [ "${PW_SENSOR_TYPE[${1}]}" == "remotesystem" ]; then temp_c=$(ssh -q -o ConnectTimeout=1 -o ConnectionAttempts=1 root@${PW_REMOTE_SENSORS[${1}]} vcgencmd measure_temp) @@ -221,7 +225,7 @@ CHECKTEMPSENSOR(){ fi else - echo -e "${idsCL[Yellow]}Sensor Offline2${idsCL[Default]}" + echo -e "${idsCL[Yellow]}Sensor Offline${idsCL[Default]}" fi } AVERAGETEMP(){