Providing Power to an Arduino

Advanced Tutorial Views: 4138
All Tutorials

Options available to provide power to an Arduino is discussed here.

Power an Arduino

This is a discussion on the various options available to provide power to an Arduino project.

 

The topic of powering an Arduino can be divided into two separate aspects, namely the external power supply and the internal power regulation relating to the Arduino itself.

Arduino Power Connection Options

  • USB – The easiest method to supply power to the Arduino is to plug it into a USB port of your computer (or phone charger). To program the Arduino, you will inherently be using this method because the USB port is used to upload new code to the Arduino. The major drawback is that the USB port of a computer does not provide a lot of current/ampere to drive anything but very simple sensors that use low power. Also, it is not very mobile to require a USB port to always power the device but if you need to communicate with the computer (or you as programmer) then USB power is definitely the simplest method.
    In the USB 1.0 and 2.0 specs, a standard downstream port is capable of delivering up to 500mA (0.5A); with USB 3.0, it moves up to 900mA (0.9A). The charging downstream and dedicated charging ports provide up to 1,500mA (1.5A).
  • Power Adapter – The Arduino has an onboard power adapter that is very useful because it is compatible with a wide range of power supplies such as those used by laptop computers. It can handle up to 13V (5-12V recommended) as long as the male and female adapters of the Arduino and the power supply fit. The downside of using the onboard power adapter is that you are not able to provide power to the any components such as motors even though the external power supply is capable of providing the needed power. The reason is that regardless of how much power you provide to the Arduino, the output current will always be the same. If something requires more current than what the Arduino ports can supply then they need to obtain their power from the power source directly and not the Arduino. Hence, one would rather use the Vin pins to be able to use the same power supply to provide power to multiple things additional to the Arduino itself.
  • AAA and 9V Batteries – Since the Arduino’s onboard power adapter accepts any DC power supply, a 9V battery can be used along with an adapter that fits on the battery at the one side while connecting into the Arduino’s onboard adapter at the other side. It should be noted that 9V batteries are inefficient and expensive, especially if not rechargeable.
  • Lithium and Lead-Acid Batteries – Rechargeable batteries such as Lead-Acid batteries (used in your car!) are very useful options. With these batteries you will most likely connect directly to the Vin pin of the Arduino, which has a regulator to provide power to the rest of the board. Batteries provide a lot more current than what your computer’s USB port can provide and is able to power things such as motors, which makes it extremely useful.

External Power Supply Options

  • Batteries – If you need mobility then batteries would be the primary source of power. You would need a source or method to recharge the batteries, such as adding a solar panel to charge the battery. If the solar panel cannot recharge the battery faster than the Arduino is using energy then eventually it will drain out. In this case the Arduino will never be able to fully switch on again (until powered) because once there is enough Voltage in the battery the Arduino will attempt to turn on and instantly draw out the power to be below the threshold (5V) for the Arduino to turn on again. To solve this problem, you have 5 options:
    1. Manually recharge batteries – If the batteries & solar panel system lasts for months then manual recharges may be an option but it is definitely not the preferred option.
    2. Add more Solar (PV) Panels – By providing more power than what the Arduino project is draining then the batteries will recharge over time. The negative side of this is that the PV panels will only charge the batteries half of the time (during day time) and if the sun is blocked then the no charging will occur at all.
    3. Code optimization – Sometimes it is possible to add enough delay time between actions to decrease the overall power usage of the Arduino project. For example, instead of spinning a motor at full speed, a reduced speed would consume less power. Also, in an IoT Wifi Arduino project it may not be necessary to send information every second over the internet, rather add delays that are just long enough to not impact functionality before communicating over the internet. Alternatively, save up a buffer of data that needs to be sent, then send it all at once instead of making multiple calls.
    4. Auxiliary switching – Use a voltage sensor to detect the voltage available, then if the voltage is below a certain level, switch off a relay to the least important (or most power-heavy) modules.
  •  Solar Panel Only – It is possible to power an Arduino with only a solar panel and no batteries. Though, it goes without saying that it the Arduino will restart quite often and may not even power up at all if not at the correct angle from the sun. By using an array of solar panels the different angles of the sun can be covered but heavy clouds will still block out the sun.
  • Wall/Mains Power – The Arduino cannot directly connect to the house main power since it requires a DC supply of 5-12V while the mains power will provide an AC supply of 220v (or different if you are another country). An AC-to-DC convertor is required to be able to use the mains power directly. Since working with such high voltages is dangerous, a safer option would be to purchase a power supply that already has the specifications you require.
  • Dynamo Powered – It is possible to use the most basic form of power generation in the form of a dynamo, which uses converts kinetic force into electromagnetic force. The most common usage today is in wind turbines but any physical force can be converted into electricity to power the Arduino.
  • Thermoelectrical Powered – By using Peltier plates it is possible to use the difference in heat in an environment to produce electricity. The higher the difference in temperature the greater the electricity generated. A good example is to use the exhaust pipe of a car where warm air meets cold air.
  • Alternative Energy- There is a wide variety of special-cases where energy can be obtained from the environment or material. Even the concept of squeezing an onion has been practically used to generate electricity (https://www.fastcompany.com/1311755/how-make-electricity-waste-onion-juice). There is no easy/cheap alternative energy source currently available for practical cheap electricity generation other than capitalising on the actual surrounding environment and limitations thereof.

 

Products that this may apply to

Special Offer
ARDUINO MEGA 2560 R3 ARDUINO MEGA 2560 R3
R 520.8
Special Offer
Arduino Nano V3 (CH340) Arduino Nano V3 (CH340)
R 125