c5te1n / node-red-contrib-dwd-local-weather

Node Red node to retrieve local weather forecast from DWD (Germany)
Apache License 2.0
13 stars 11 forks source link

precipitation (24 h) and look ahead (for less than 24 h) deliver predictions for different points in time #54

Open ekkards opened 7 months ago

ekkards commented 7 months ago

Use case: Show weather forecast on a pixel clock

Expectation: By choosing a suitable look ahead time a consistent data set of temperature and precipitation can be obtained from the node-red module.

Observation: The time intervals for temperature and precipation do not match

The value "precipitationNext24h" is generated as follows, apparently containing 24 h as a fixed value. "precipitationNext24h" : Math.round(sumFutureValue(node.mosmixStation, "RR1c", 24, forecastDate) * 10) / 10,

Workarounds: Attempted workaround with using "additional fields" also has its short coming

Suggested change: For look ahead time < 24 h, deliver a value for precipitation, wich is only summed up until the look ahead time. "precipitationNext24h" : Math.round(sumFutureValue(node.mosmixStation, "RR1c", lookAheadHours, forecastDate) * 10) / 10,

SmartyKNX commented 6 months ago

Unfortunately you will not get reliable values anyway for the next hours anyway, because the MOSMIX L dataset is only updated 4 times a day.

I would prefer using the MOSMIX S dataset for this usecase, but therefor the code needs to modified to extract a single station from the KMZ-File containing all stations. (I have no idea, why DWD has no single station files for the MOSMIX S dataset.)