Update powerwall.sh

This commit is contained in:
2023-10-31 14:17:56 -05:00
parent 3aed70d436
commit 627f91798e

View File

@@ -531,6 +531,11 @@ check_GETHOSTPOWER(){
CHECKPOWER(){ CHECKPOWER(){
start=`date +%s` start=`date +%s`
echo -e "\n${idsCL[Yellow]}Power Information"
DIVIDER . yellow 75
if [ "${1}" == "" ] || [ "${1}" == "sensors" ]; then
for SENSOR in ${PW_SENSOR_ORD[@]}; do for SENSOR in ${PW_SENSOR_ORD[@]}; do
if [ "${PW_HOST_IDRACS[${SENSOR}]}" != "" ]; then if [ "${PW_HOST_IDRACS[${SENSOR}]}" != "" ]; then
GETHOSTPOWER ${PW_HOST_IDRACS[${SENSOR}]} & GETHOSTPOWER ${PW_HOST_IDRACS[${SENSOR}]} &
@@ -538,10 +543,6 @@ CHECKPOWER(){
done done
check_GETHOSTPOWER & check_GETHOSTPOWER &
echo -e "\n${idsCL[Yellow]}Power Information"
DIVIDER . yellow 75
if [ "${1}" == "" ] || [ "${1}" == "sensors" ]; then
if [ "$(CHECK_HOST inv1.scity.us)" != "false" ]; then if [ "$(CHECK_HOST inv1.scity.us)" != "false" ]; then
INVSTATSINFO=$(curl -s "https://inv1.scity.us/stats.json") INVSTATSINFO=$(curl -s "https://inv1.scity.us/stats.json")
INPUTV=`echo ${INVSTATSINFO} | jq '.inputs .inV'` INPUTV=`echo ${INVSTATSINFO} | jq '.inputs .inV'`