TL;DR … I think my battery is borked ?
Back to this sub-project now that I (finally) have DFRobot Solar Power Manager 5V, Solar panel and Li-PO battery (not to scale) and assembled it with a Adafruit MAX17043 and two DFRobot Digital Wattmeters (INA219) … like so:
The voltage meter is showing almost exactly the same voltage as the MAX17043
The solar panel doesn’t seem to be generating any noticable current , so I have also connected a USB phone charger via a INA219 - and the amount reported on that is also suspiciously low .
Connecting the INA219-45 with USB power to my Raspberry Pi and using the DFRobot code mentioned above in November, I get:
(env) pi@raspberrypi:~/python $ python greenhouse3.py
INA219-45: Shunt Voltage=38.0mV, Bus Voltage=4.945V, Current=41.0mA, Power=200.0mW
INA219-45: Shunt Voltage=36.0mV, Bus Voltage=4.953V, Current=35.0mA, Power=160.0mW
INA219-45: Shunt Voltage=41.0mV, Bus Voltage=4.949V, Current=37.0mA, Power=200.0mW
INA219-45: Shunt Voltage=36.0mV, Bus Voltage=4.949V, Current=37.0mA, Power=200.0mW
INA219-45: Shunt Voltage=38.0mV, Bus Voltage=4.949V, Current=40.0mA, Power=200.0mW
INA219-45: Shunt Voltage=38.0mV, Bus Voltage=4.957V, Current=37.0mA, Power=160.0mW
INA219-45: Shunt Voltage=37.0mV, Bus Voltage=4.953V, Current=38.0mA, Power=200.0mW
INA219-45: Shunt Voltage=37.0mV, Bus Voltage=4.949V, Current=34.0mA, Power=160.0mW
INA219-45: Shunt Voltage=37.0mV, Bus Voltage=4.909V, Current=39.0mA, Power=200.0mW
INA219-45: Shunt Voltage=36.0mV, Bus Voltage=4.949V, Current=37.0mA, Power=200.0mW
INA219-45: Shunt Voltage=36.0mV, Bus Voltage=4.953V, Current=37.0mA, Power=200.0mW
The Bus Voltage seems right, but only 35-40 mA of current ?
Back to all 3 power monitors connected to a ESP32 via i2c, and all devices are installed in ESPHome and appear to be returning data to Home Assistant - except that data except voltage is recorded as 0.0.
Maybe it’s because Home Assistant is showing the reading in Amps but the values are too small to register ? Going to the ESPHome log from the ESP32
[19:19:43][D][pulse_counter:181]: 'rain gauge': Retrieved counter: 0.00 pulses/min
[19:19:43][D][sensor:094]: 'rain gauge': Sending state 0.00000 pulses/min with 2 decimals of accuracy
[19:19:44][D][dht:048]: Got Temperature=27.9°C Humidity=64.0%
[19:19:44][D][sensor:094]: 'DHT22 Temperature': Sending state 27.90000 °C with 1 decimals of accuracy
[19:19:44][D][sensor:094]: 'DHT22 Humidity': Sending state 64.00000 % with 0 decimals of accuracy
[19:20:12][D][sensor:094]: 'greenhouse Wifi signal': Sending state -54.00000 dBm with 0 decimals of accuracy
[19:20:19][D][sensor:094]: 'Solar Bus Voltage': Sending state 4.85600 V with 2 decimals of accuracy
[19:20:19][D][sensor:094]: 'Solar Shunt Voltage': Sending state 0.00012 V with 2 decimals of accuracy
[19:20:19][D][sensor:094]: 'Solar Current': Sending state 0.00118 A with 3 decimals of accuracy
[19:20:19][D][sensor:094]: 'Solar Power': Sending state 0.00588 W with 2 decimals of accuracy
[19:20:21][D][text_sensor:064]: 'greenhouse Uptime Human Readable': Sending state '3m 34s'
[19:20:21][D][sensor:094]: 'greenhouse Uptime': Sending state 214.25101 s with 0 decimals of accuracy
[19:20:21][D][bh1750.sensor:159]: 'BH1750 Illuminance': Got illuminance=603.3lx
[19:20:21][D][sensor:094]: 'BH1750 Illuminance': Sending state 603.29718 lx with 1 decimals of accuracy
[19:20:28][D][sensor:094]: 'MAX17043 Battery Voltage': Sending state 3.60500 V with 3 decimals of accuracy
[19:20:28][D][sensor:094]: 'Max17043 Battery level': Sending state 2.68355 % with 3 decimals of accuracy
[19:20:32][D][sensor:094]: 'INA219-45 Bus Voltage': Sending state 4.77600 V with 2 decimals of accuracy
[19:20:32][D][sensor:094]: 'INA219-45 Shunt Voltage': Sending state 0.00147 V with 2 decimals of accuracy
[19:20:32][D][sensor:094]: 'INA219-45 Current': Sending state 0.01470 A with 3 decimals of accuracy
[19:20:32][D][sensor:094]: 'INA219-45 Power': Sending state 0.07056 W with 2 decimals of accuracy
[19:20:34][D][ads1115.sensor:017]: 'ADS1115 Channel A0-GND': Got Voltage=3.156000V
[19:20:34][D][sensor:094]: 'ADS1115 Channel A0-GND': Sending state 3.15600 V with 3 decimals of accuracy
[19:20:38][D][ads1115.sensor:017]: 'ADS1115 Channel A3-GND': Got Voltage=0.015000V
[19:20:38][D][sensor:094]: 'ADS1115 Channel A3-GND': Sending state 0.01500 V with 3 decimals of accuracy
[19:20:43][D][pulse_counter:181]: 'rain gauge': Retrieved counter: 0.00 pulses/min
[19:20:43][D][sensor:094]: 'rain gauge': Sending state 0.00000 pulses/min with 2 decimals of accuracy
[19:20:44][D][dht:048]: Got Temperature=27.9°C Humidity=64.2%
[19:20:44][D][sensor:094]: 'DHT22 Temperature': Sending state 27.90000 °C with 1 decimals of accuracy
[19:20:44][D][sensor:094]: 'DHT22 Humidity': Sending state 64.20000 % with 0 decimals of accuracy
[19:21:19][D][sensor:094]: 'Solar Bus Voltage': Sending state 4.85600 V with 2 decimals of accuracy
[19:21:19][D][sensor:094]: 'Solar Shunt Voltage': Sending state 0.00011 V with 2 decimals of accuracy
[19:21:19][D][sensor:094]: 'Solar Current': Sending state 0.00108 A with 3 decimals of accuracy
[19:21:19][D][sensor:094]: 'Solar Power': Sending state 0.00588 W with 2 decimals of accuracy
[19:21:21][D][bh1750.sensor:159]: 'BH1750 Illuminance': Got illuminance=589.4lx
[19:21:21][D][sensor:094]: 'BH1750 Illuminance': Sending state 589.37494 lx with 1 decimals of accuracy
[19:21:28][D][sensor:094]: 'MAX17043 Battery Voltage': Sending state 3.61750 V with 3 decimals of accuracy
[19:21:28][D][sensor:094]: 'Max17043 Battery level': Sending state 2.68355 % with 3 decimals of accuracy
[19:21:32][D][sensor:094]: 'INA219-45 Bus Voltage': Sending state 4.78000 V with 2 decimals of accuracy
[19:21:32][D][sensor:094]: 'INA219-45 Shunt Voltage': Sending state 0.00146 V with 2 decimals of accuracy
[19:21:32][D][sensor:094]: 'INA219-45 Current': Sending state 0.01460 A with 3 decimals of accuracy
[19:21:32][D][sensor:094]: 'INA219-45 Power': Sending state 0.07056 W with 2 decimals of accuracy
[19:21:34][D][ads1115.sensor:017]: 'ADS1115 Channel A0-GND': Got Voltage=3.150000V
[19:21:34][D][sensor:094]: 'ADS1115 Channel A0-GND': Sending state 3.15000 V with 3 decimals of accuracy
[19:21:38][D][ads1115.sensor:017]: 'ADS1115 Channel A3-GND': Got Voltage=0.015000V
[19:21:38][D][sensor:094]: 'ADS1115 Channel A3-GND': Sending state 0.01500 V with 3 decimals of accuracy
[19:21:43][D][pulse_counter:181]: 'rain gauge': Retrieved counter: 0.00 pulses/min
[19:21:43][D][sensor:094]: 'rain gauge': Sending state 0.00000 pulses/min with 2 decimals of accuracy
[19:21:44][D][dht:048]: Got Temperature=27.8°C Humidity=64.0%
[19:21:44][D][sensor:094]: 'DHT22 Temperature': Sending state 27.80000 °C with 1 decimals of accuracy
[19:21:44][D][sensor:094]: 'DHT22 Humidity': Sending state 64.00000 % with 0 decimals of accuracy
[19:22:12][D][sensor:094]: 'greenhouse Wifi signal': Sending state -54.00000 dBm with 0 decimals of accuracy
[19:22:19][D][sensor:094]: 'Solar Bus Voltage': Sending state 4.85600 V with 2 decimals of accuracy
[19:22:19][D][sensor:094]: 'Solar Shunt Voltage': Sending state 0.00012 V with 2 decimals of accuracy
[19:22:19][D][sensor:094]: 'Solar Current': Sending state 0.00118 A with 3 decimals of accuracy
[19:22:19][D][sensor:094]: 'Solar Power': Sending state 0.00588 W with 2 decimals of accuracy
[19:22:21][D][text_sensor:064]: 'greenhouse Uptime Human Readable': Sending state '5m 34s'
[19:22:21][D][sensor:094]: 'greenhouse Uptime': Sending state 334.24799 s with 0 decimals of accuracy
[19:22:21][D][bh1750.sensor:159]: 'BH1750 Illuminance': Got illuminance=574.9lx
[19:22:21][D][sensor:094]: 'BH1750 Illuminance': Sending state 574.88678 lx with 1 decimals of accuracy
[19:22:28][D][sensor:094]: 'MAX17043 Battery Voltage': Sending state 3.61750 V with 3 decimals of accuracy
[19:22:28][D][sensor:094]: 'Max17043 Battery level': Sending state 2.68355 % with 3 decimals of accuracy
[19:22:32][D][sensor:094]: 'INA219-45 Bus Voltage': Sending state 4.78400 V with 2 decimals of accuracy
[19:22:32][D][sensor:094]: 'INA219-45 Shunt Voltage': Sending state 0.00144 V with 2 decimals of accuracy
[19:22:32][D][sensor:094]: 'INA219-45 Current': Sending state 0.01441 A with 3 decimals of accuracy
[19:22:32][D][sensor:094]: 'INA219-45 Power': Sending state 0.06664 W with 2 decimals of accuracy
Yes, the raw values are reading thousandths of an amp, so the meters seem to be correct.
Did i mention that I can’t check the readings because my Digitech multimeter no longer reads current ? Another expense on my list to replace that
Thinks … a device pulls as much current as it wants (up to the max provided by the power supply) … so is the problem with my battery rather than the power monitors ?
As for the battery … I bought a 6600mAh 3.7V battery pack about 8 years ago for a project to build a mobile robot … but then financial circumstances changed and it got shelved. Battery has been unused for much of that time.
When I started bench testing this greenhouse project (but before I got the power meters) I connected a simple LED display volt meter and battery to the Solar power Manager 5V and on to the ESP32, wondering roughly how long the battery would continue to run the ESP32 (i.e. will I need to buy a bigger battery to allow for 3 days operation during winter). I recorded a max of 4.24V, and it ran down to 2.91V. Charged back up to 4.23V, so thought it was OK … but now it seems to max at 3.7V.
At 9:30am the USB charger has been on overnight and the battery has maxed out at 3.64V (3.7V on the LED display). Charge from USB is only 16mA. Solar panel is facing out my window to the wast, so won’t be in sun till the afternoon, though you can see that it is starting to generate a little charge.
Turned USB charger off, and battery voltage immediately starts dropping. Wait till the afternoon, both to see how far the battery voltage drops, and to see how effective the solar panel is …