0

My Arduino Uno is powered by 9v battery to run 2 ultrasonic sensors (HC-SR04) and a buzzer.

I intend let the circuit run for at least a week.

Is there a solution to reduce power consumption / increase battery life?

I am open to hardware and software solutions.

Thanks!

  • 2
    Two things: 1. Use sleep modes. 2. Don't use the internal regulator of the Arduino it wastes 50% of your battery power. Bypass it with a 5V switching regulator. – Majenko Jun 30 at 10:26
  • Hi there! How do I bypass it with a 5V switching regulator? I'm new to Arduino – Zac Jul 2 at 2:04
  • You connect your battery to the input of the regulator and the output to the 5v+gnd pins of Arduino – Majenko Jul 2 at 8:00
  • And don't use a 9V battery. Use AA or AAA instead. 9V are weak. – Delta_G Jul 31 at 1:21
0

You could do a checking routine. For example, if you are detecting motion you can connect the vcc pin of the HC-04 to a digital pin and turn it on and check for changes once every 10 seconds.

| improve this answer | |
  • Hi! I guess to do this, I have to use sleep mode function right? – Zac Jul 2 at 2:06
  • Yes, basically except you can power the HC-04 directly from the digital pin so that you can completely power the module off and then go into sleep mode. Whenever you want to take a measurement, you would power the digital pin on and then take a reading. – DragonflyRobotics Jul 2 at 15:20
  • You can also make an interrupt where if the sensor makes a reading, it will wake up else it will sleep. I believe the Newping library supports this. Also check out this link: playground.arduino.cc/Learning/ArduinoSleepCode – DragonflyRobotics Jul 2 at 15:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.