Closed ffes closed 5 years ago
Choosing the right device is indeed not easy. I use a "custom sensor" but is has some (2 in fact) issues. My implementation can be found on: https://github.com/seventer/raintocome
The Rain device can't be used for this, because it is indeed showing the rain that actually has fallen. RAINCOUNTER is showing the total amount of rain that has fallen (so since the device has started measuring the rain fall).
I am using a humidity sensor which can show the values between 0 and 255. That way you can also use the dry and wet values.
But using a custom sensor maybe makes more sense. I have chosen the humidity sensor before the custom sensor was made available in Domoticz, and at that moment it was a logical choice because you can also use the log to see the development of the rain prediction.
Any news on this one. Your plugin is working perfectly fine on my Synology NAS, thumbs up for that! I would also like to have rain prediction so I don't have to maintain a seperate script for that.
See pull request #8. Used the plugin from @seventer as input for the rain forecast function :)
solved
Based on the forum post: https://www.domoticz.com/forum/viewtopic.php?f=65&t=13938
Which is the Python rewrite of buienradar_rain_example.pl which is on
domoticz/scripts
These scripts works with a percentage device and shows the average expected rain for the total period (coming 2 hours).
There is also a LUA script: https://www.domoticz.com/wiki/Is_it_gonna_rain
Basically they all retrieve their data from: http://gadgets.buienradar.nl/data/raintext/?lat=52.1&lon=4.3
That data is explained at http://www.buienradar.nl/overbuienradar/gratis-weerdata#Neerslag%20lat%20lon
Question is: what to display? Is it raining or going to rain with XXX minutes seems most useful.
This would need a "Switch" or "Selector Switch" (what is the difference?) to be set to true or false.
It is also possible to create a "Rain" device. But that stores the rain that actually has fallen. It wants a rate and counter: https://www.domoticz.com/wiki/Domoticz_API/JSON_URL's#Rain So that is not the most logical device to use. And it is a bit unclear to me what the RAINCOUNTER value means.