-
Notifications
You must be signed in to change notification settings - Fork 1
Module thc_MeteoSwiss
The thc_MeteoSwiss module implements THC devices that get data from SwissMetNet. For details about the data set, see https://opendata.swiss/en/dataset/automatische-wetterstationen-aktuelle-messwerte or https://data.geo.admin.ch/ch.meteoschweiz.messwerte-aktuell.
To get weather data you need first to know the abbreviation of the location you are interested in. For this, open data legend file https://data.geo.admin.ch/ch.meteoschweiz.messwerte-aktuell/info/VQHA80_en.txt
The weather data is then extracted from the following file that is updated in a regular interval : https://data.geo.admin.ch/ch.meteoschweiz.messwerte-aktuell/VQHA80.csv
The following current weather parameters are available :
- temperature - Air temperature 2 m above ground; current value (°C)
- humidity - Relative air humidity 2 m above ground; current value (%)
- pressure - Pressure reduced to sea level according to standard atmosphere (QNH); current value (hPa)
- speed - Wind speed; ten minutes mean (km/h)
- direction - Wind direction; ten minutes mean (°)
- precipitation - Precipitation; ten minutes total (mm)
The definition of an MeteoSwiss devices requires the declaration of the 'get' command, using the following syntax:
{thc_MeteoSwiss {<LocationAbbreviation> <WeatherParameter>}}
thc::DefineDevice Bern,temp \
-name Bern -group Environment -format "%sC" -range {-30 50} -update 10m \
-get {thc_MeteoSwiss {"BER" "temperature"}}
THC, Tight Home Control - See THC index register - THC repository on github.com/Drolla/thc