diff --git a/inc/temp.inc.sh b/inc/temp.inc.sh index fb3b2231..249a48eb 100644 --- a/inc/temp.inc.sh +++ b/inc/temp.inc.sh @@ -1051,7 +1051,7 @@ CHECKTEMP_SERVICE_RUNSENSOR(){ if [ "${SENSORa}" == "Powerwall-CPU-Usage" ]; then temp_c=$(awk '{u=$2+$4; t=$2+$4+$5; if (NR==1){u1=u; t1=t;} else print ($2+$4-u1) * 100 / (t-t1) "%"; }' <(grep 'cpu ' /proc/stat) <(sleep 1;grep 'cpu ' /proc/stat) | sed -e 's/%//g') else - temp_c=$(${SSHCMD} root@${PW_REMOTE_SENSORS[${SENSORa}]} "/opt/idssys/defaults/get-data.sh cpu-usage") + temp_c=$(${SSHCMD} root@${PW_REMOTE_SENSORS[${SENSORa}]} "/opt/idssys/defaults/get-data.sh cpu-usage" | tr -d $'\r') fi temp_h=''