Battery fed Deepsleep Weatherstation revisited

After my previous publication of a battery fed weatherstation, I exchanged ideas with one of the commenters about ways the improve the energy efficiency of the circuit.

One doesn’t need to be a rocketscientist for that:
Ditch the batteryshield as it is very inefficient
Ditch the DHT22 as that constantly uses 2.5mA
Ditch the Wemos as even while it is in deep sleep the CH340 chip on the board isn’t. (it drains 200uA)
Ditch the voltage divider used to monitor the battery voltage (it drains 10uA).
Also ditch the BMP280 as it cannot measure humidity.

So what we will be doing is use a bare ESP8266-12F  and a BME280 as that can measure humidity as well as temperature and airpressure.
Feed with alkaline cells, omitting the need for an LDO. That way the voltage can be measured directly from Vcc/Vbatt without the need of a voltage divider

So, a new circuit starts to evolve:

Obviously that needs a bit more soldering than just using a Wemos and battery shield, but in essence one only needs to add the resistors to put the necessary pins HIGH (pins 0, 2 and CH_PO) or LOW (pin 15). There are however  various baseplates  for the ESP8266-12F that have these resistors already present. The  capacitor is  there to give some extra boost when the ESP is busy connecting to a network.

In order to minimize the poweruse of the BME280, one has to use some special settings. Normally the BME280 constantly is taking readings of its sensors. Not only does that take more power, but I noticed it can also drive up the temperature of the chip, influencing the temperature reading.
The mode to use it in is  the so called Forced Mode: it will only take a reading when told to do so.
Now mind you, even if you don’t tell it to take a reading, the library will still give you a result as that gets its values from a register, but it will always be the same value, you will need to tell the chip it has to store a new value in that register.

The datasheet suggests 4 different possibilities of ‘Forced mode’:

  • Weather station scenario
  • Humidity scenario
  • Indoor Navigation
  • Gaming

We obviously will be taking the first one.
The software can be downloaded here

While in sleep this should draw 80uA
Now suppose we have a 2000mAh battery then the circuit could run 25000 hour=1042 days=2.85 years =2 years, 10 months and a week
Now obviously that is a bit of a simplification as the full power of the battery might not be available within the 4.2<->3.0 Volt slot and ofcourse the circuit is using more current when not asleep, so lets recalculate:
Though larger peaks exist, the average current drawn during connection is some 85mA. So suppose that we have a 3 second connection and 15 (900sec) min of sleep
The current consumption is then as follows 3x85mA+900x80uA=255+72=327mAs, so over an hour it consumes 1308mAs and during a day 31392mAs. So every day that is 8.72mAh. A 2000mAh battery then gives 229 days=7.6 months.

 

 

Advertisements

12 thoughts on “Battery fed Deepsleep Weatherstation revisited”

  1. I know I am being 100% anal here, but I also know it is allowed here and it is deliberate anyway…….. To go even more minimalistic without going to the ESP-01, requiring that pesky reset wire to GPIO16, you can use I2C on GPIO0 and GPIO2, with their pull up resistors already in place on the BME board. The chip select can be hard-wired to Vcc (it is no possible output AFAIK). 😛

    1. yes that is definitely true. It probably will not only save components but also some current, however small it may be. I actually have the pull down on GPIO15 in mind for keeping the gate of a FET normally LOW (the FET will switch power to a soil humidity probe).
      Anal retentive minimality is even appreciated here

  2. Hi

    This project is just what I need to have battery powered sensors around the House.

    I am having trouble compiling this. Keeps coming up with:-

    no matching function for call to ‘PubSubClient::PubSubClient(WiFiClient&, const char [13]) (Line 26)

    Im not good with ardinuo ide so need some help please.

    Gareth

    1. Yes/No. For external measurement, yes. For internal measurement (read: measuring Vcc), it’s all internal.

    2. It is as Jeroen says. In my previous article I measured the battery voltage through A0 and then it needs the voltage divider. In this article I measure Vccinternally… and then you don’t need a voltage divider. There wouldn’t even be a possibility to use one if you wanted coz it is measuring an internal voltage, not a voltage on A0

    1. That is correct. Have considered those. Not sure how they will behave in cold weather though.
      Currently trying 2 regular 1.5Volt AA’s and that still goes well.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.