Update temp.inc.sh
This commit is contained in:
@@ -712,6 +712,7 @@ 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=$(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 [ "${temp_c}" != "" ]; then
|
||||||
if [ "${1}" == "ServerRoom_Monitor_Front" ]; then
|
if [ "${1}" == "ServerRoom_Monitor_Front" ]; then
|
||||||
|
echo "\"${PW_ESP_USER}:${PW_ESP_PASS}\" http://${PW_REMOTE_SENSORS[${1}]}:8090/sensor/front_humidity"
|
||||||
curl -m 8 -s -u "${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)
|
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"
|
echo "1: $temp_h"
|
||||||
|
|||||||
Reference in New Issue
Block a user