Closed ebaauw closed 4 years ago
Thats my thoughts, · To expose the forecast create 3 accesories: Current, 1h, 24h. · For coordinates, keep the location input, but transform it to coordinates for the api call if there is a free tier to achieve that.
an accessory group for rain and snow. Each group as 3 contact sensor tiles for current, 1h, 24h. So you should be able to setup a notification.
Looks like they do include
rain1h
in the One Call API. I dropped that from Homebridge WS after moving from Wunderground to OpenWeatherMap. There might be asnow1h
as well. No evidence ofrain24h
though;
The daily
forecasts include (I assume: total) rain
. Re-introduced Rain Last Hour, Total Rain, and UV Index characteristics. I don't know if there's similar characteristics for snow, currently still ignoring it.
For coordinates, keep the location input, but transform it to coordinates for the api call if there is a free tier to achieve that.
Done. That actually turned out to be easier than I anticipated.
To expose the forecast create 3 accesories: Current, 1h, 24h.
Each group as 3 contact sensor tiles for current, 1h, 24h. So you should be able to setup a notification.
I fear Eve might choke on a single accessory with three contact sensor services, so I might need to go for three accessories. That also leaves the possibility to add Eve history.
HomeKit provides notifications for a number of sensors: Contact, Lock, Motion, Smoke, Leak, and probably more that I don't have. I would think Leak makes most sense semantically? However, I don't think they've yet reversed engineered the history for the Eve WaterGuard (assuming it even has one).
OK, added dailyForecasts
and hourlyForcecasts
config.json parameters to expose forecasts. They're exposed under a separate Forecasts accessory, with a single service per forecast. With 47 hourly and 7 daily forecasts, there's no room for multiple services per forecast, without running the risk of hitting the 99 services per accessory limit. And I don't want to expose additional accessories, to prevent hitting the 149 accessories per bridge limit.
I now expose an additional Leak Sensor service on the main accessory (and moved the full weather report over there, from the Air Pressure sensor). Leak Detected is set on rain or snow. You should be able to get HomeKit notifications for this. The Forecast services are also exposed as Leak Sensors.
Thats great
OpenWeatherMap have introduced a new, richer API, see https://openweathermap.org/api/one-call-api. It might be opportune for Homebridge WS to be using that:
snow1h
as well. No evidence ofrain24h
though;