OpenWeather is one of the leading digital weather information providers, with more than 2,000,000 active users, and data from over 200,000 cities - making it a great option to enrich your IoT Application with weather data.
We've seamlessly integrated with OpenWeather's API so you don't have to, enabling you to use Ubidots to log weather data in just a few clicks:
- An active Ubidots account (IoT Entrepreneur Plan and above)
Table of Contents
- Creating an OpenWeatherMap's Plugin
- Editing an OpenWeatherMap's Plugin
1. Creating an OpenWeatherMap's Plugin
In your Ubidots account, click on the "Plugins" option under the "Devices" navbar menu, then click on the "+" icon in the upper right corner and select OpenWeatherMap:
Configure your Plugin according to these input settings:
- Location: Click on the map to specify your location
- Units format: Choose between "Metric" or "Imperial" units. See "Output" below to see which units are used in each variable.
- Your Ubidots token: Every plugin requires an Ubidots token to make all the requests that provision and update your device.
- Time interval: How often you'd like to retrieve current weather conditions for the specified location (in minutes). Please note that weather data is updated every 20 to 30 minutes, so choosing a lower update rate will result in repeated values.
This plugin creates a new device with the following attributes:
- Device name: Location name as returned in the field "name" in OpenWeatherMap's API response.
- Device label: Unique ID associated with the specified location. Field "id" in OpenWeatherMap's API response.
The created device will contain these variables, which will be updated at the specified time interval:
- Temperature: Current temperature in degrees Celsius (Metric) or Fahrenheit (Imperial).
- Feels like: Current "feels like" temperature (takes into account wind speed and humidity to assess how the human body actually feels temperature), in degrees Celsius (Metric) or Fahrenheit (Imperial).
- Temp Min: Min temperature during the day in degrees Celsius (Metric) or Fahrenheit (Imperial).
- Temp Max: Max temperature during the day in degrees Celsius (Metric) or Fahrenheit (Imperial).
- Humidity: Current relative humidity in percentage unit for both Metric and Imperial systems.
- Pressure: Current atmospheric pressure in millibars (mbar) for both Metric and Imperial systems.
- Wind speed: Current wind speed in m/s (Metric) or mph (Imperial).
- Wind direction: Current wind direction in degrees for both Metric and Imperial systems.
Note: Currently, an Ubidots-owned OpenWeather API key is used, which is maintained and scaled by us. Future versions may support using your own API key.
After configuring the Plugin, a new item will appear on the list. Please allow a few seconds for the plugin to finish its provisioning process, and then refresh your browser:
When the status of the Plugin is "Running" then you should see a new device in your Devices list:
2. Editing an OpenWeatherMap's Plugin
To edit the Plugin, simply click on the Edit button in the Plugins list view:
The same "Input" fields that appeared during the creation process will appear. Please note that, every time the Plugin is updated, a provisioning script will run, overriding the current attributes of the target device:
- Device name
- Device label
- Device icon
- Device description
- Device color
- Variable names
- Variable units
- Variable colors
If you have any ideas on how we could improve this plugin, we'd be happy to hear them. Please leave us a note at email@example.com
Others also found helpful...