Table Of Content¶
Plugin weather¶
Purpose¶
The weather plugin uses the online service Yahoo! Weather to grab weather informations.
Dependencies¶
There is no dependency.
Plugin configuration¶
There is no global configuration options for this plugin.
Create the domogik devices¶
Domogik device type : weather.weather¶
1 parameter is needed for a domogik device creation:
Key | Type | Description |
---|---|---|
device | string | The location code for your city. Example for Paris : 615702 |
To find the location code for your city, just go on https://weather.yahoo.com/ . Then, search for your town. You will be redirected to a new page with an url like this : https://weather.yahoo.com/france/%C3%AEle-de-france/paris-615702/ (for Paris). The last part of the url, after the “-” (minus) is the location code. In our example, the location code for Paris is 615702.
Start the plugin¶
You can now start the plugin (start button) and use the created domogik devices.
Set up your widgets on the user interface¶
You can now place the widgets of your devices features on the user interface.
Development informations¶
Sensors history¶
Most of the sensors for this plugin have no history enabled by default. For example forecast data have no history as there is no need to keep forecast history!
Only the following sensors are configured to store the history:
- current_barometer_value
- current_humidity
- current_temperature
- current_wind_direction
- current_wind_gust
- current_wind_speed
Timeout on sensors¶
All sensors have a timeout set to 65 minutes : as the interval between each check on weather.com is set to 30min, we let the plugin to encounter 1 failure.
Forecast data¶
A specific xPL schema has been defined for the forecast:
xpl-stat
xpl-stat { ... } weather.forecast { provider=yahoo weather day=<number of the day : 0....> day-name=... temperature-high=... temperature-low=... condition-text=... condition-code=... }
Condition codes¶
Condition codes and texts are listed here: https://developer.yahoo.com/weather/documentation.html
You can find some code to translate the condition codes to css class for a weather css icon library here : https://gist.github.com/aloncarmel/8575527
Here are some translated values...
English¶
- {
- 0 : “tornado”, 1 : “tropical storm”, 2 : “hurricane”, 3 : “severe thunderstorms”, 4 : “thunderstorms”, 5 : “mixed rain and snow”, 6 : “mixed rain and sleet”, 7 : “mixed snow and sleet”, 8 : “freezing drizzle”, 9 : “drizzle”, 10 : “freezing rain”, 11 : “showers”, 12 : “showers”, 13 : “snow flurries”, 14 : “light snow showers”, 15 : “blowing snow”, 16 : “snow”, 17 : “hail”, 18 : “sleet”, 19 : “dust”, 20 : “foggy”, 21 : “haze”, 22 : “smoky”, 23 : “blustery”, 24 : “windy”, 25 : “cold”, 26 : “cloudy”, 27 : “mostly cloudy (night)”, 28 : “mostly cloudy (day)”, 29 : “partly cloudy (night)”, 30 : “partly cloudy (day)”, 31 : “clear (night)”, 32 : “sunny”, 33 : “fair (night)”, 34 : “fair (day)”, 35 : “mixed rain and hail”, 36 : “hot”, 37 : “isolated thunderstorms”, 38 : “scattered thunderstorms”, 39 : “scattered thunderstorms”, 40 : “scattered showers”, 41 : “heavy snow”, 42 : “scattered snow showers”, 43 : “heavy snow”, 44 : “partly cloudy”, 45 : “thundershowers”, 46 : “snow showers”, 47 : “isolated thundershowers”, 3200 : “not available”
}
French¶
- {
- 0 : “tornade”, 1 : “tempête tropicale”, 2 : “ouragan”, 3 : “grosse tempête”, 4 : “orages”, 5 : “pluie et neige”, 6 : “pluie et neige fondue”, 7 : “neige et neige fondue”, 8 : “bruine verglaçante”, 9 : “bruine”, 10 : “pluie verglaçante”, 11 : “grosses averses”, 12 : “grosses averses”, 13 : “averses de neige”, 14 : “légères averses de neige”, 15 : “bourrasques de neige”, 16 : “neige”, 17 : “grêle”, 18 : “neige fondue”, 19 : “poussière”, 20 : “brumeux”, 21 : “brouillard”, 22 : “enfumé”, 23 : “tempête”, 24 : “venteux”, 25 : “froid”, 26 : “nuageux”, 27 : “assez nuageux (nuit)”, 28 : “assez nuageux (jour)”, 29 : “partiellement nuageux (nuit)”, 30 : “partiellement nuageux (jour)”, 31 : “clair (nuit)”, 32 : “ensoleillé”, 33 : “beau (nuit)”, 34 : “beau (jour)”, 35 : “pluie et grêle”, 36 : “chaud”, 37 : “orages isolés”, 38 : “orages éparses”, 39 : “orages éparses”, 40 : “averses éparses”, 41 : “grosse neige”, 42 : “averses de neige éparses”, 43 : “grosse neige”, 44 : “partiellement nuageux”, 45 : “averses orageuses”, 46 : “averses de neiges”, 47 : “averses orageuses isolées”, 3200 : “inconnu”
}
Changelog¶
1.7¶
- This release needs at least Domogik 0.5.2 !
- Add compliance with the last butler improvment for performances
- Improve allowed sentences (fr_FR)
1.6¶
- Use a new datatype for visiblity : DT_kMeter (km).
- Use a new datatype for pression : DT_mbarPressure (km).
- Add a new butler interaction : fr_FR : outside temperature.
- Improve existing butler interactions : fr_FR
1.5¶
- Fix values since Yahoo Weather API changed in start of 2016
1.4¶
- Fix timeout attributes. As value could not change for a few hours, the timeout is now set to 24h on the sensors.
1.3¶
- Compatibility with Rivescript 1.8.1 and Domogik 0.5.0
- Improve the triggers for butler
1.2¶
- Butler : add dedicated butler triggers for weather
- New icon
1.1¶
- Fix : https://github.com/fritz-smh/domogik-plugin-weather/issues/2
- Fix : https://github.com/fritz-smh/domogik-plugin-weather/issues/1
- Fix : current temperature history is now storred
1.0¶
- Plugin creation