From 40ed50780141a88972a8c32cf4f4930125b2adb8 Mon Sep 17 00:00:00 2001 From: nasseeder1 Date: Sun, 17 Jul 2022 07:11:15 +0000 Subject: [PATCH] 76_SolarForecast.pm: contrib 0.65.5 git-svn-id: https://svn.fhem.de/fhem/trunk@26238 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/contrib/DS_Starter/76_SolarForecast.pm | 30 ++++++++++++--------- 1 file changed, 17 insertions(+), 13 deletions(-) diff --git a/fhem/contrib/DS_Starter/76_SolarForecast.pm b/fhem/contrib/DS_Starter/76_SolarForecast.pm index 175c84972..79e986005 100644 --- a/fhem/contrib/DS_Starter/76_SolarForecast.pm +++ b/fhem/contrib/DS_Starter/76_SolarForecast.pm @@ -396,10 +396,10 @@ my %htitles = ( DE => qq{Planungsstatus: \n\nEin: \nAus: } }, akorron => { EN => qq{Enable auto correction with:\nset pvCorrectionFactor_Auto on}, DE => qq{Einschalten Autokorrektur mit:\nset pvCorrectionFactor_Auto on} }, - splus => { EN => qq{PV surplus exists}, - DE => qq{PV-Überschuß ist vorhanden} }, - nosplus => { EN => qq{no PV surplus present}, - DE => qq{kein PV-Überschuß vorhanden} }, + splus => { EN => qq{PV surplus sufficient}, + DE => qq{PV-Überschuß ausreichend} }, + nosplus => { EN => qq{PV surplus insufficient}, + DE => qq{PV-Überschuß unzureichend} }, ); my %weather_ids = ( @@ -3508,13 +3508,15 @@ sub ___switchConsumerOn { $state = qq{switching Consumer "$calias" to "$oncom"}; - writeDataToFile ($hash, "consumers", $csmcache.$name); # Cache File Consumer schreiben + writeDataToFile ($hash, "consumers", $csmcache.$name); # Cache File Consumer schreiben Log3 ($name, 2, "$name - $state (Automatic = $auto)"); } } - elsif (((isInterruptable($hash, $c) == 1 && isConsRcmd ($hash, $c)) || isInterruptable($hash, $c) == 3) && # unterbrochenen Consumer fortsetzen - isInTimeframe ($hash, $c) && simplifyCstate ($pstate) =~ /interrupted|interrupting/xs && + elsif (((isInterruptable($hash, $c) == 1 && isConsRcmd ($hash, $c)) || # unterbrochenen Consumer fortsetzen + (isInterruptable($hash, $c) == 3 && isConsRcmd ($hash, $c))) && + isInTimeframe ($hash, $c) && + simplifyCstate ($pstate) =~ /interrupted|interrupting/xs && $auto && $oncom) { CommandSet(undef,"$cname $oncom"); @@ -3586,8 +3588,8 @@ sub ___switchConsumerOff { Log3 ($name, 2, "$name - $state (Automatic = $auto)"); } - elsif (((isInterruptable($hash, $c) == 1 && !isConsRcmd ($hash, $c)) || isInterruptable($hash, $c) == 2) && # Consumer unterbrechen - isInTimeframe ($hash, $c) && simplifyCstate ($pstate) =~ /started|continued|interrupting/xs && + elsif (((isInterruptable($hash, $c) && !isConsRcmd ($hash, $c)) || isInterruptable($hash, $c) == 2) && # Consumer unterbrechen + isInTimeframe ($hash, $c) && simplifyCstate ($pstate) =~ /started|continued|interrupting/xs && $auto && $offcom) { CommandSet(undef,"$cname $offcom"); @@ -8745,16 +8747,18 @@ Ein/Ausschaltzeiten sowie deren Ausführung vom SolarForecast Modul übernehmen 0 - Verbraucher wird nicht temporär unterbrochen falls der PV Überschuß die benötigte Energie unterschreitet (default) 1 - Verbraucher darf temporär unterbrochen werden falls der PV Überschuß die benötigte Energie unterschreitet Device:Reading:Regex - Verbraucher wird temporär unterbrochen wenn der Wert des angegebenen Device/Readings auf den Regex matched - Matched der Wert nicht mehr, wird der unterbrochene Verbraucher wieder eingeschaltet. + oder unzureichender PV Überschuß vorliegt. + Matched der Wert nicht mehr, wird der unterbrochene Verbraucher wieder eingeschaltet sofern ausreichender PV Überschuß vorliegt.
    Beispiele:
    - attr <name> consumer01 wallplug icon=scene_dishwasher@orange type=dishwasher mode=can power=2500 on=on off=off notafter=20 etotal=total:kWh:5
    - attr <name> consumer02 WPxw type=heater mode=can power=3000 mintime=180 on="on-for-timer 3600" notafter=12 auto=automatic
    - attr <name> consumer03 Shelly.shellyplug2 type=other power=300 mode=must icon=it_ups_on_battery mintime=120 on=on off=off swstate=state:on:off auto=automatic pcurr=relay_0_power:W etotal:relay_0_energy_Wh:Wh swoncond=EcoFlow:data_data_socSum:^-?([1-7][0-9]|[0-9])$ swoffcond:EcoFlow:data_data_socSum:100
    + attr <name> consumer01 wallplug icon=scene_dishwasher@orange type=dishwasher mode=can power=2500 on=on off=off notafter=20 etotal=total:kWh:5
    + attr <name> consumer02 WPxw type=heater mode=can power=3000 mintime=180 on="on-for-timer 3600" notafter=12 auto=automatic
    + attr <name> consumer03 Shelly.shellyplug2 type=other power=300 mode=must icon=it_ups_on_battery mintime=120 on=on off=off swstate=state:on:off auto=automatic pcurr=relay_0_power:W etotal:relay_0_energy_Wh:Wh swoncond=EcoFlow:data_data_socSum:^-?([1-7][0-9]|[0-9])$ swoffcond:EcoFlow:data_data_socSum:100
    + attr <name> consumer04 Shelly.shellyplug3 icon=scene_microwave_oven type=heater power=700 mode=must notbefore=07 mintime=480 on=on off=off etotal=relay_0_energy_Wh:Wh pcurr=relay_0_power:W auto=automatic interruptable=eg.az.wandthermostat:diff-temp:([0-9]).*