Turn switch on/off based on weather forecast

I’ve been transferring my automations from many other services to Hubitat. I have one giving me trouble.

I have heated mats I use to melt snow. I want to turn on when snow is in the forecast. I have apixu setup, but no idea on how to creat a rule in rule machine based on a weather forecast, any ideas?

Have a look at Wato apps. I am not sure about snow attribute but I use rain for my sprinkler.

1 Like

You can also do this natively. Try this:

"Turn switch on/off based on weather forecast"
I would much prefer being able to turn the weather on/off based on a switch. I just got done shoveling snow and another storm is due today. :wink:

2 Likes

THAT would be a truly useful automation!

1 Like

Thank you. I am now trying the attributes with DarkSky device. I’m using the Rule Engine rather than WATO, as it can parse attributes. No attribute for Snow, but I can parse the forecast text for the word Snow.

I’ll report back how it works.

BTW - the mats keep me from having to shovel much at my ski house.

2 Likes

I just got snow melting mats and am looking to do the same thing. Did you find a solution?

I did. I used Dark Sky Forecast Text containing snow as the trigger. But I think that is going to stop working soon, so will need to find a new source.

I'm using the weather.gov integration to determine whether it's cloudy outside or not and adjust motion lighting accordingly. I hope weather.gov will be here for a while...

I ended up using node-red and openweathermap.org and put together this automation, hasn't snowed yet so hopefully, it will trigger when it does lol

Seems like it's working :slight_smile:

This is awesome! You inspired me to explore node-red and turn my new SummerStep on/off based on the forecast. It seems to be working. Thank you for posting!

@humac how do you get if it is going to snow from Open Weather?

I only see these returned from the API as well as the NodeRed module

  • description - a brief verbal description of the current weather for human reading.
  • weather - a very short description of the current weather.
  • icon - the weather icon code for the current conditions.
  • id - the id given to the current weather by OpenWeatherMap
  • tempc - the current ground temperature at that location in Celsius.
  • tempk - the current ground temperature at that location in Kelvin.
  • humidity - the current relative humidity at the location in percent.
  • windspeed - the current wind speed at the location in metres per second.
  • winddirection - the current wind direction at the location in meteorological degrees.
  • location - the name of the location from which the data was sourced.
  • rain - the precipitation amount in mm/h (only present if it is raining).

I use weather dot gov and test if forecast contains snow. My guess is that description contains snow.p, should work.

Download the Hubitat app