Water sprinklers

Hi, I have a pump and sprinklers in my garden. I now use a flow thats checks the maximum temperature and the total mm of rain. I use open weather app.
The problem is: when it is raining a lot lets say on monday, and on tuesday is is dry, then the sprinkers are activated on tuesday morning.
I would like to somehow use the total amount of rain over the past 2 or 3 days and on this amount descide if it is needed to use the sprinkers. I would prefer to use the sprinkers once every 3 days. I just dont know how i can make a good flow for this. The biggest problem is that i dont know how to make a sum of the mm of rain about the past 3 days. Can anyone help me out a bit? Best regards, wouter

Some ideas / discussions: