-
Notifications
You must be signed in to change notification settings - Fork 4
Open‐Meteo (English)
Open-Meteo is an open-source weather API, that can be used for free in non-commercial domain. It provides forecast and historical data from various weather services including NOAA, DWD, Meteofrance, MSC-CSC etc. No API key is required to use the service.
weewx-DWD supports retrieving actual weather data from Open-Meteo by their API. Open-Meteo focusses on forecasts and historical data, but current data are also available.
The configuration is simple. Specify latitude and longitude. The configuration section in weewx.conf could look like this:
[WeatherServices]
[[current]]
[[[FichtelbergOM]]]
provider = Open-Meteo
model = LIST_OF_WEATHER_MODELS
latitude = 50.4283
longitude = 12.9536
altitude = 1213
iconset = 4
prefix = 'xyz'
This would retrieve current weather data for mount Fichtelberg in Saxony. You can specify any other location around the world.
The prefix is set to xyz
in this example. This means, if you want to display the temperature you would write $current.xyzOutTemp
in the skin template. $current.xyzIcon.raw
provides an icon file name, and $current.xyzIcontitle.raw
a text message describing the current weather.
Observation types (replace prefix
by the prefix you set in configuration):
prefixDateTime
prefixOutTemp
prefixWindSpeed
prefixWindDir
prefixWeathercode
prefixIcon
prefixIcontitle
prefixLatitude
prefixLongitude
prefixAltitude
To download forecast data und create forecasts a separate script is used which will be invoked from the command line.
For WeeWX packet installation:
dwd-mosmix --weewx --open-meteo=LIST_OF_WEATHER_MODELS --lang=LANGUAGE OUTPUTOPTIONS LATITUDE,LONGITUDE
For WeeWX pip installation:
dwd-mosmix --config=/path/to/your/weewx.conf --open-meteo=LIST_OF_WEATHER_MODELS --lang=LANGUAGE OUTPUTOPTIONS LATITUDE,LONGITUDE
OUTPUTOPTIONS
can be any combination of the following options:
-
--html --daily --hourly
: create HTML include files containing the weather forecast as a table -
--database
: create a database file containing the forecast data for displaying diagrams -
--belchertown
: create a Belchertown formatforecast.json
file
Open-Meteo provides forecasts from several different weather services from around the world. Some of those weather services provide more than one weather model. To select the weather service and weather model to use set the option --open-meteo
as follows:
--open-meteo= | Country | Weather service | Model |
---|---|---|---|
dwd-icon | DE | DWD | ICON |
gfs | US | NOAA | GFS |
meteofrance | FR | MeteoFrance | Arpege+Arome |
ecmwf | EU | ECMWF | open IFS |
jma | JP | JMA | GSM+MSM |
metno | NO | MET Norway | Nordic |
gem | CA | MSC-CMC | GEM+HRDPS |
ecmwf_ifs04 | EU | ECMWF | IFS |
metno_nordic | NO | MET Norway | Nordic |
icon_seamless | DE | DWD | ICON Seamless |
icon_global | DE | DWD | ICON Global |
icon_eu | DE | DWD | ICON EU |
icon_d2 | DE | DWD | ICON D2 |
gfs_seamless | US | NOAA | GFS Seamless |
gfs_global | US | NOAA | GFS Global |
gfs_hrrr | US | NOAA | GFS HRRR |
gem_seamless | CA | MSC-CMC | GEM |
gem_global | CA | MSC-CMC | GEM |
gem_regional | CA | MSC-CMC | GEM |
gem_hrdps_continental | CA | MSC-CMC | GEM-HRDPS |
ukmo_seamless | GB | UK Met Office | UKMO Seamless |
Use dwd-mosmix --help
for a complete list of options.
To download the forecast automatically put the call to dwd-mosmix
into /etc/crontab
.