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

Maximum temperature of current day #32

Closed zimbo86 closed 2 years ago

zimbo86 commented 3 years ago

Hi, I want to reopen Issue #6 https://github.com/c5te1n/node-red-contrib-dwd-local-weather/issues/6

I cant get it working. I inject at 6:00am with the following parameters: image For my understandig I should receive the maximum temperature from 6am to 6pm. However the temperature is way to low, injecting again at 10am gives me much higher values.

What is the correct syntax to get the maximum temperature of the whole day?

c5te1n commented 3 years ago

DWD provides one data point for TX every 12 hours, which seems to happen at 6:00am and pm z-time (GMT). That's 2 hours difference from German summer time (CEST). TX gives you the "Maximum temperature - within the last 12 hours". So to get the day max temperature you want to set the lookahead hours so that you are in the middle of the day (i. e. 10am as in your example) and then go forward to the next data point, which will be the max temperature in the last 12 hours (">°TX"). So just make sure that you set lookahead hours right - everything else seems to be correct already.

zimbo86 commented 2 years ago

youre absolutely correct. Just checked some kml files and got the way it works :)

For my project I inject twice a day: 4am and 4pm (my MOSMIX station updates data at 3am and 3pm). I set a lookahead of 5 hours to "ignore" the datapoint at 6am and 6pm, so I get TX and TN for day and night. (Because I need TX_day at 4am for irrigation).