Solar powered weather station feedback

Hi,
I have a basic solar powered weather station that I made around 2 years ago, it consists of an ESP12 board with BMP280 and SHT31 sensors for temperature, air pressure and humidity. There is also a tipping bucket rain sensor, I have 2 small 6V 2W small panels that charge a 18650 battery.

The code sends an MQTT report over WiFi every 15minutes and then goes to WiFi sleep mode, the reason for not going to deep sleep is that for the tipping bucket gauge I have a pin interrupt which counts up each tip then sends the values and resets once the number of tips is sent.

The setup worked well during the summers keeping a itself charged up and running smoothly. Last winter I did need to flip the battery a couple of times when we had consistent overcast days however this winter (Australia) the battery isn't doing so well. There will be 2 reasons (a) solar cells have probably degraded so not producing as much power as previous years, (b) the tree line has increased slightly so with the low sun I am getting less sunlight on "normal" days. I have used new batteries so I don't think these are to blame.

I know I could change the panels but I would prefer not to and find a software or easier longer term fix.

My initial thought is that is there a board that I could use to count the tipping bucket tips rather than the ESP12 board that way the ESP could read from the chip each 15mins and then use deep sleep which could save that extra bit of power.

Does such a thing exist or anyone have any other thoughts?

Another option maybe using deep sleep and waking on bucket tip somehow but I'd have to distinguish between a bucket tip and a normal wake which I don't think I can do with the ESP12.

Any thoughts or ideas appreciated, let me know if more details would help too.

Most microprocessors feature a "wake from deep sleep" on pin change, which is ideal for actions like counting bucket tips, keypad button press, etc. An Arduino compatible ATtiny or Arduino Pro Mini can do that.

I know nothing about ESP12, but would be surprised if it did not have such a feature.

Edit: Indeed it does. Connect your rain gauge bucket to GPIO16, and count away from deep sleep.

My thought is though that GPIO would also be connected to reset to allow the board to wake from deep sleep therefore I wouldn't be able to distinguish between wake for interrupt and wake from deep sleep.
Also as I believe waking from deep sleep restarts the code this would be the same as a restart event too.

Is that an unsupported belief, or did you actually take time to read the processor manual?

As for bucket tipping, the state of GPIO16 would be changed from the last tip, and is thus a detectable event.

Most modern micros have a register that reports the cause of a wakeup or restart event.

Good luck with your project!

Thanks.

From the research I had and now have done I don't think the ESP12 board will work for what I want to do and with the way the tipping bucket works. However an esp32 board does allow deep sleep interrupt on multiple pins so I can use one of these for the tipping bucket completely independently of the normal 15min wake up intervals.

Thanks again for your help and advice.

You could just use a cmos counter chip and read it’s outputs from time to time

( eg4518)

That is the other option I was after thank you. A 4518 would work. Some articles mention moving to 74HC series now so will look into the binary counter option in that series.

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