Those are some awesome links on AMR. Thanks for sharing @gusgonnet Good stuff! I'm learning more and more in this space every day. For my particular use I need closer to real time data. Ideally every 5 maybe 30 minutes and the locations are remote, middle of the woods, the middle of a farm field, etc. and finally the water meter is just one of several sensors/actuators I need in close proximity so thus trying to build my own version with Particle as the backhaul. And besides... it's a fun challenge and a good way to learn new things.
I actually programmed it originally using interrupts. I'm currently using a Current Ranger as my low cost sleepy current measurement device. I didn't take some average over time or measure the precise duration of the interrupt but I just know it spiked to around 9mA just momentarily as part of the interrupt. The 1.5" flow meter is something like 20 pulses per gallon so to fill a 1,000 gallon tank would be 20,000 interrupts in this use case, maybe the duration is so tiny it is inconsequential/would work it just doesn't feel as "clean".
I plan to eventually apply this learning to a LoRa end node device as well. For those LoRa end nodes, I use an AB1805 RTC as well as a LoRa Radio communication to also wake the device up upon interrupts. So it just gets clunky to figure out why the device woke up and based on that what action to take. I even attempted to use "Timer 4" on a SAMD21 MCU per this blog post
alternatively route the pulses through the SAMD21's External Interrupt Controller (EIC) and on to a TC timer using the Event System. The TC timer is configured to count the incoming pulses. The Event System is a 12-channel highway for peripheral-to-peripheral communications without CPU intervention. The latter option has the advantage that it isn't necessary to call the ISR each time a pulse is received; the whole process occurs without any CPU intervention, apart from reading the timer's COUNT register.
Likewise it worked but I still couldn't figure out how to make it work when sleeping. Ultimately, my goal is to keep things as simple and straightforward as possible to get the job done. Adding the extra S35770 I2C counter chip just seems like the simplest/most straight forward solution. It's just might not be as elegant as interrupts.