We’d made the decision to use CR2032 coin cells for a number of reasons, but that still left us with the challenge of providing enough power during a WiFi transmission. According to the ESP8266 datasheet we’d be looking at 56mA during receive, and 120mA during a transmission.
I wasn’t really concerned with the sleep current because in our application we’d be enabling the ESP8266, connecting the AP, sending the data, then immediately shutting down the ESP. The concern was how long it would take to perform the full upload connection and upload sequence.
Looking at typical CR2032 datasheet the recommended continuous current drain (to prolong battery life) was 0.2mA, and could handle short duration pulses (a few seconds) at around 5mA with an acceptable decrease in battery life. In our application we were planning to use 4 CR2032 cells in parallel giving us effectively 4 times the above power capacity values.
In order to overcome the power limitations of the coin cells and provide enough power during a WiFi transmission we planned to buffer power into a supercapacitor that we would discharge during the transmission. Searching around online led me to a great design note from CAP-XX.
In this solution, they trickle charge the capacitor through a 1k (we bumped it up to 4k) resistor (R5) and use a comparator (TLV3012) to limit the charge voltage to 2.7V (maximum voltage of most supercapacitors). With R5 at 4k, and 4 batteries in parallel, we limit the current draw on each battery to 0.19mA.
The resistors R1, R2, R3, and R4 are used to set the start and stop voltages for the charging circuit. Based on the above values charging starts when the capacitor voltage drops below 2.693V and stops when the voltage hits 2.700V (Note: these results differ slightly from the values given in the design note - my calculations are provided below for verification).
When the capacitor is discharged below the threshold, IN+ will be less than IN-, the output of the comparator will be off and R4 can be ignored. Then, a simple voltage divider calculation can be done to determine the “ON” threshold voltage.
When the capacitor is charged above the threshold, IN+ will be greater than IN-, and the output of the comparator will be high (3V). We can do a nodal analysis of the node between R2 and R3 to determine the “OFF” threshold voltage.
The next step was to determine the size of capacitor that we would require to complete a full transmission. We considered an upload sequence that lasted for 5 seconds with an average current draw of 100mA at 3.3V. Performing an energy balance with a capacitor and solving for C we can find the required capacitance.
The Vmin value of the supercapacitor was based on the estimated drop out voltage of the boost regulator that would be attached to the load. We haven’t shown it in the calculations here, but we also have to account for the efficiency of the boost within the full range the capacitor discharge voltages. We chose a value of 0.6F as a starting point for our first prototype.
Using a 0.6F supercapacitor the time to recharge the capacitor to within 99% capacity (5 time constants, 5RC) through the 4k resistor is about 3 hours and 20 minutes. The total maximum current draw on the 4xCR2032s is 0.75mA. Our plan is to perform a single WiFi upload once per day, so a charge time of 3 hours was acceptable.
Finally, now that we had a capacitance value to start with we could begin sourcing a supercapacitor with our desired dimensions. With a overall product thickness of 6mm, finding an appropriate component was a challenge.
We finally came across the 0.3F 304DCN2R7SCBB from Illinois Capacitor that had a maximum diameter of just 4.5mm, and a maximum length of 12.5mm. Combining two in parallel would give the 0.6F we wanted for our test.
All that was left was to spin up a PCB and see how how it performed when actually implemented.