Skip to content

Weather

Settings

Key Value
CONFIG weather
ENV N/A
URL N/A
VALUE []WeatherLocation
DEFAULT []
Using with config.yaml file
weather:
locations:
- name: london
lat: 51.5285262
lon: -0.2663999
api: API_KEY
unit: metric
round_temperature: false
lang: en
forecast: false
show:
temperature_range: false
humidity: false
wind: false
wind_direction: false
visibility: false
default: false

You can configure multiple locations in the config.yaml file, and choose which one to display using the URL query weather=NAME.

Value Description
name The location’s display name (used in the URL query).
lat Latitude of the location.
lon Longitude of the location.
api OpenWeatherMap API key.
unit Units of measurement (standard, metric, or imperial).
round_temperature Round temperature to the nearest whole number.
lang Language code for weather descriptions (see the full list here).
forecast Display the forecast for the next three days
show.temperature_range Display temperature range for the next 24 hours.
show.humidity Display humidity for location.
show.wind Display wind for location.
show.wind_direction Also display wind direction as degrees for location.
show.visibility Display visibility for location.
default Set this location as the default (when no location is specified)

A select few weather options can be overridden via URL query parameters:

  • weather_show_forecast
  • weather_show_temperature_range
  • weather_show_humidity
  • weather_show_wind
  • weather_show_wind_direction
  • weather_show_visibility
  • weather_round_temperature

https://{KIOSK_URL}?weather_show_forecast=true&weather_show_humidity=true

You can rotate between configured weather locations by setting weather to rotate in the URL e.g. https://{KIOSK_URL}?weather=rotate.

Use rotation_interval to control how often locations rotate.

Here’s an example of how to add London, London using OpenWeatherMap’s name and New York to the config.yaml file. These locations would be selectable via the URL, like this: http://{URL}?weather=london or http://{URL}?weather=new-york.

weather:
rotation_interval: 60 # in seconds (10 is the minimum).
locations:
- name: london
lat: 51.5285262
lon: -0.2663999
api: API_KEY
unit: metric
lang: en
default: true
- name: london-api
lat: 51.5285262
lon: -0.2663999
api: API_KEY
unit: metric
lang: en
- name: new-york
lat: 40.6973709
lon: -74.1444838
api: API_KEY
unit: imperial
round_temperature: true
lang: en