Resetting Rain Counter Daily


So I'm working on a project that sniffs and decodes RF data off of my accurate 5 in 1 weather station which I'm then assigning to variables to use in my code. The problem I'm having is the data coming off the weather station for the rain tip bucket is a endless running value. If I reset the weather station by pulling the batteries out the rain tip bucket counter will go to 0. I would like to take the endless running value and reset it back to zero in my code each day without resetting the weather station.

Could someone point me in the right direction on achieving this result?



Depends ... largely in what you do with the data and how you are saving the counts.
You could just add a time stamp to you data field , that enables you to link rainfall to a particular time/date.

Or just look for the count from the rain gauge to increment, and add the fact it has changed by incrementing a local variable , then reset that at midnight .

It sounds like the counter is in the weather station. At reset time, save the current value then subtract that value at each subsequent reading to give you the accumulated value since reset (update counter not reset weather station). You can do this at whatever time is convenient for you, though typically midnight is common.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.