mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-10 09:16:53 +00:00
76_Solarforcast: contrib 0.1.0
git-svn-id: https://svn.fhem.de/fhem/trunk@23361 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
e62a8c4ae2
commit
3faacc7c34
@ -640,6 +640,8 @@ sub _transferForecastValues {
|
|||||||
push @$daref, "Tomorrow_HourSunRise:".$fc1_SunRise;
|
push @$daref, "Tomorrow_HourSunRise:".$fc1_SunRise;
|
||||||
push @$daref, "Tomorrow_HourSunSet:". $fc1_SunSet;
|
push @$daref, "Tomorrow_HourSunSet:". $fc1_SunSet;
|
||||||
|
|
||||||
|
deleteReadingspec ($myHash, "NextHour.*");
|
||||||
|
|
||||||
for my $num (0..47) {
|
for my $num (0..47) {
|
||||||
my $fh = $chour + $num;
|
my $fh = $chour + $num;
|
||||||
$fd = int ($fh / 24) ;
|
$fd = int ($fh / 24) ;
|
||||||
@ -1876,6 +1878,23 @@ sub createReadings {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
################################################################
|
||||||
|
# alle Readings eines Devices oder nur Reaging-Regex
|
||||||
|
# löschen
|
||||||
|
################################################################
|
||||||
|
sub deleteReadingspec {
|
||||||
|
my $hash = shift;
|
||||||
|
my $spec = shift // ".*";
|
||||||
|
|
||||||
|
my $readingspec = '^'.$spec.'$';
|
||||||
|
|
||||||
|
for my $reading ( grep { /$readingspec/ } keys %{$hash->{READINGS}} ) {
|
||||||
|
readingsDelete($hash, $reading);
|
||||||
|
}
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
######################################################################################
|
######################################################################################
|
||||||
# NOTIFYDEV erstellen
|
# NOTIFYDEV erstellen
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
Loading…
x
Reference in New Issue
Block a user