mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 00:36:25 +00:00
76_SolarForecast: possible asynchron mode for Meter & Inverter
git-svn-id: https://svn.fhem.de/fhem/trunk@29404 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
cc4dfe95c9
commit
a9ac0a1c14
@ -5526,7 +5526,7 @@ sub Attr {
|
||||
if ($init_done && $aName eq 'ctrlInterval') {
|
||||
_newCycTime ($hash, time, $aVal);
|
||||
my $nct = CurrentVal ($hash, 'nextCycleTime', 0); # gespeicherte nächste CyleTime
|
||||
readingsSingleUpdate ($hash, 'nextCycletime', (!$nct ? 'Manual' : FmtTime($nct)), 0);
|
||||
readingsSingleUpdate ($hash, 'nextCycletime', (!$nct ? 'Manual / Event-controlled' : FmtTime($nct)), 0);
|
||||
return;
|
||||
}
|
||||
}
|
||||
@ -6982,8 +6982,8 @@ sub runTask {
|
||||
my ($interval, $disabled, $inactive) = controller ($name);
|
||||
|
||||
if (!$interval) {
|
||||
$hash->{MODE} = 'Manual';
|
||||
storeReading ('nextCycletime', 'Manual');
|
||||
$hash->{MODE} = 'Manual / Event-controlled';
|
||||
storeReading ('nextCycletime', 'Manual / Event-controlled');
|
||||
return;
|
||||
}
|
||||
|
||||
@ -7048,14 +7048,14 @@ sub _newCycTime {
|
||||
my $interval = shift;
|
||||
|
||||
if (!$interval) {
|
||||
$hash->{MODE} = 'Manual';
|
||||
$hash->{MODE} = 'Manual / Event-controlled';
|
||||
$data{$hash->{TYPE}}{$hash->{NAME}}{current}{nextCycleTime} = 0;
|
||||
storeReading ('nextCycletime', 'Manual');
|
||||
storeReading ('nextCycletime', 'Manual / Event-controlled');
|
||||
return;
|
||||
}
|
||||
|
||||
my $new = $t + $interval; # nächste Wiederholungszeit
|
||||
$hash->{MODE} = 'Automatic - next Cycletime: '.FmtTime($new);
|
||||
$hash->{MODE} = 'Automatic / Event-controlled - next planned Cycletime: '.FmtTime($new);
|
||||
|
||||
$data{$hash->{TYPE}}{$hash->{NAME}}{current}{nextCycleTime} = $new;
|
||||
storeReading ('nextCycletime', FmtTime($new));
|
||||
|
Loading…
Reference in New Issue
Block a user