>D pcurr=0 stufe1=0 stufe2=0 stufe3=0 stufe4=0 stufe5=0 >B =>sensor53 r >M 2 +1,12,s,16,9600,PV +2,3,s,16,9600,EWE 1,77070100020800ff@1000,Zählerstand Lieferung,kWh,export_total_kwh1,0 ;1,77070100010800ff@1000,Zählerstand Bezug,kWh,total_kwh1,0 1,77070100100700ff@1,aktuelle Leistung ,W,curr_w1,0 2,77070100020800ff@1000,Zählerstand Lieferung,kWh,export_total2_kwh,0 2,77070100010800ff@1000,Zählerstand Bezug,kWh,total_kwh2,0 2,77070100100700ff@1,aktuelle Leistung ,W,curr_w2,0 >T ; positv ist einfacher pcurr=0-EWE#curr_w2 >S ; Stufe 1 ein bei Einspeisung >1000 if pcurr>1000 then ;=>webquery http://192.168.179.201/relay/0/?turn=on GET ENDON stufe1=1 endif ;Stufe 2 ein bei Einspeisung >1000 und Stufe 1 ein if pcurr>1000 and stufe1==1 then ;=>webquery http://192.168.179.201/relay/0/?turn=of GET ENDON ;=>webquery http://192.168.179.202/relay/0/?turn=on GET ENDON stufe2=1 endif ;Stufe 3 ein bei Einspeisung >1000 und Stufe 2 ein if pcurr>1000 and stufe2==1 then ;=>webquery http://192.168.179.201/relay/0/?turn=on GET ENDON stufe3=1 endif ;Stufe 4 ein bei Einspeisung >1000 und Stufe 3 ein if pcurr>1000 and stufe3==1 then ;=>webquery http://192.168.179.201/relay/0/?turn=of GET ENDON ;=>webquery http://192.168.179.202/relay/0/?turn=of GET ENDON ;=>webquery http://192.168.179.203/relay/0/?turn=on GET ENDON stufe4=1 endif ;Stufe 5 ein bei Einspeisung >1000 und Stufe 4 ein if pcurr>1000 and stufe4==1 then ;=>webquery http://192.168.179.201/relay/0/?turn=on GET ENDON stufe5=1 endif ; Stufe 4 aus bei Einspeisung <250 und Stufe 5 an if pcurr<250 and stufe5==1 then ;=>webquery http://192.168.179.201/relay/0/?turn=of GET ENDON stufe5=0 endif ; Stufe 3 aus bei Einspeisung <250 und Stufe 4 an if pcurr<250 and stufe4==1 then ;=>webquery http://192.168.179.203/relay/0/?turn=of GET ENDON ;=>webquery http://192.168.179.201/relay/0/?turn=on GET ENDON ;=>webquery http://192.168.179.202/relay/0/?turn=on GET ENDON stufe4=0 endif ; Stufe 2 aus bei Einspeisung <250 und Stufe 3 an if pcurr<250 and stufe3==1 then ;=>webquery http://192.168.179.201/relay/0/?turn=of GET ENDON stufe3=0 endif ; Stufe 1 aus bei Einspeisung <250 und Stufe 2 an if pcurr<250 and stufe2==1 then ;=>webquery http://192.168.179.202/relay/0/?turn=of GET ENDON ;=>webquery http://192.168.179.201/relay/0/?turn=of GET ENDON stufe2=0 endif ; Stufe 0 aus bei Einspeisung <250 und Stufe 1 an if pcurr<250 and stufe1==1 then ;=>webquery http://192.168.179.201/relay/0/?turn=of GET ENDON stufe1=0 endif >W bu(stufe1 "Stufe 1 an" "Stufe 1 aus") bu(stufe2 "Stufe 2 an" "Stufe 2 aus") bu(stufe3 "Stufe 3 an" "Stufe 3 aus") bu(stufe3 "Stufe 3 an" "Stufe 4 aus") bu(stufe3 "Stufe 3 an" "Stufe 5 aus") #