Overview Weather (Internet)

With this function block, a simple weather forecast can be integrated. This block is connected to the control element Internet Weather.

Important

  • If this function block is used, the controller must necessarily have a connection to the internet and be able to resolve the domain. Without an internet connection or with an unreachable DNS server, the watchdog may trigger under certain circumstances and the controller is restarted.
  • An update of the weather data cannot be interrupted. If a query is active and there is no internet connection or the domain name cannot be resolved, loading the project may not be possible under certain circumstances; in this case the end of the query or timeout must be waited for.
  • This block should not be used for control tasks such as heating control, as the data for this is far too inaccurate.
  • The controller must be able to access the internet permanently in order to retrieve the data. Switching off the internet connection, for example overnight or during absence, may under certain circumstances lead to a triggering of the controller's watchdog.
  • The data of the service can be very inaccurate in some areas.
  • The service is either OpenWeather (https://openweathermap.org/) or Open-Meteo (https://open-meteo.com/), see parameter Data source. OpenWeather requires an account; in the account you receive an API key which must be entered in this function block. Open-Meteo works without registration; according to the provider the free access is intended for non-commercial use, for commercial use Open-Meteo offers a paid access with API key. No guarantee can be given for the future availability of the service or the correctness of the weather data.



Inputs




Outputs

KF
Query error
Communication error when the data could not be retrieved.
TP
Temperature
Temperature in °C
LF
Humidity
Relative humidity in percent
LD
Air pressure hPa
Air pressure in hPa
WK
Wind km/h
Wind in km/h
BW
Cloud cover
Cloud cover in %
Rain Rain
1 when rain
ID ID
Weather condition as ID, see Openweathermap Weather condition codes. These IDs are also output with the data source Open-Meteo, the weather condition is converted to them.
GR ID group ID as group, see Openweathermap Weather condition codes

When an ID of 500 to 531 is output, category rain, 5 is output at this output. This provides the distinction between rain, storm etc.

Parameters

Longitude
Longitude in decimal degrees
Latitude
Latitude in decimal degrees
Data source Service that provides the weather data: OpenWeather or Open-Meteo. The default is OpenWeather, i.e. the previous behaviour. The controls display both sources in the same way; with Open-Meteo the weather description comes in the language of the APP.
Update
Update interval. OpenWeatherMap provides the weather data in the free account only every 3 hours; a smaller interval therefore does not bring higher accuracy in the free variant.
API key API key that is generated during registration. Required for OpenWeather, for Open-Meteo only for the paid, commercial access.
Language Language of the weather description: German, English, Slovenian, French, Italian, Spanish, Hungarian or Turkish. The default is German, i.e. the previous behaviour. Only with the data source OpenWeather.

List of IDs.

For a current description, see Openweathermap Weather condition codes.











See also common parameters of all function blocks.