OpenWeatherMapAPI: add wind_gust

git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@24604 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
LeonGaultier 2021-06-09 18:49:19 +00:00
parent ef33372813
commit 992bfea64a
2 changed files with 15 additions and 1 deletions

View File

@ -1,5 +1,6 @@
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
# Do not insert empty lines here, update check depends on it.
- feature OpenWeatherMapAPI: add wind_gust
- bugfix: 50_HP1000: change time format for Internal SYSTEMTIME_UTC
- bugfix: 73_AutoShuttersControl: add multiple Condition
for fixing shutter drives

View File

@ -423,6 +423,10 @@ sub _ProcessingRetrieveData {
sprintf( "%.1f", ( $data->{wind}->{speed} * 3.6 ) )
+ 0.5
),
'wind_gust' => int(
sprintf( "%.1f", ( $data->{wind}->{gust} * 3.6 ) )
+ 0.5
),
'wind_direction' => $data->{wind}->{deg},
'cloudCover' => $data->{clouds}->{all},
'code' => $codes{ $data->{weather}->[0]->{id} },
@ -553,6 +557,15 @@ sub _ProcessingRetrieveData {
)
) + 0.5
),
'wind_gust' => int(
sprintf(
"%.1f",
(
$data->{list}->[$i]->{wind}
->{gust} * 3.6
)
) + 0.5
),
'cloudCover' =>
$data->{list}->[$i]->{clouds}->{all},
'code' => $codes{
@ -660,7 +673,7 @@ sub strftimeWrapper {
"abstract": "Wetter API für OpenWeatherMap"
}
},
"version": "v1.0.2",
"version": "v1.0.3",
"author": [
"Marko Oldenburg <leongaultier@gmail.com>"
],