I am using a board with ATmega328P+ESP8266 chips on it for some basic moisture sensor measurement. The ATmega part checks two moisture sensors (connected to 5V and 3.3V pins on the board), sends the data over the serial bus to the ESP and goes to sleep for 8 seconds. The ESP reads the data, sends a POST request to my RPi and goes to deep sleep for 20 seconds.
I have bought a plastic 4-pack housing AA batteries to power it, however it only lasted about 12 hours approximately.
My question is - is this battery life expected from a project like this or have I done something wrong? Sorry if it is a dumb question, it is my first project.
I have not since I forgot to buy such equipment when ordering the stuff. Thats why I want to ask if there is anything conceptually wrong with the way I have done it. I will get something to measure it the next time I order something.
thanks for the tip, though I am not sure on how to address this - apparently you cannot turn off power pins, but digital pins could be used to power some small stuff, although I cannot find how much they draw
you could drive through the Digital pins if the current draw is OK (so read the spec of what you connect) or need some external circuit (transistor for example) so that you could turn on or off the external device's power