Update powerwall.sh

This commit is contained in:
2022-09-11 14:44:42 -05:00
parent 7a30a147a2
commit 7af11f15a6

View File

@@ -120,7 +120,7 @@ CHECKACV_SERVICE(){
[ $volt_diff -lt 0 ] && volt_diff=$(($volt_diff * -1))
if [ ${INPUTACV%.*} -ge ${min_volt} ]; then
echo "($datetime) normal voltage: ${INPUTACV}V"
if [ $volt_diff -gt 1 ]; then
if [ $last_volt -lt ${min_volt} ]; then
echo -e "($datetime) Normal voltage detected\nVOLTAGE: ${INPUTACV}V" | mail -s "POWER NOMINAL AGAIN" $email_alert
elif [ "$last_volt" = "0" ]; then
echo -e "($datetime) Normal voltage detected\nVOLTAGE: ${INPUTACV}V" | mail -s "Power Nominal" $email_alert