Many electronic hobbyists and students use Arduino as their first microcontroller board because it’s easy to learn and make their projects. All that’s needed is a laptop or a PC to program and power the Arduino board.
But, can Arduino run without a computer? Yes, it can. To power Arduino boards without a computer you can use an external power supply like a DC adaptor, a 5V Pin, a Vin Pin, or a battery shield.
Each option has its perks, drawbacks, a proper way of installation and use to avoid damaging your board or end up choosing the wrong power supply for your specific project. All this is laid out in this article.
Why Do You Need a Computer for Arduino?
Arduino consists of two parts – hardware and software. The microcontroller board is considered as the hardware, while the Arduino IDE is regarded as the software.
So, technically you need to connect your Arduino to a computer via a USB cable so that you can upload the program in it.
The Arduino IDE allows you to write a program using a combination of C and C++ commands. After writing the code, you can upload it on the board so that the I/O pins and the processor function accordingly. In principle, you need a laptop or a PC for writing and uploading code.
After the code is uploaded, the Arduino is still powered on through the 5V supply USB slot connected to the computer. The program will be executed on the Arduino board as long as it’s connected to the computer. Once you plug out the USB cable, your Arduino will shut down, but the code you uploaded will remain intact in its memory.
So, as you can see, to provide your Arduino with a continuous power supply seems like you must have it plugged into the computer, right?
So, Why Would I want to Run Arduino Without a Computer?
The need for running Arduino without a computer arises when you’re using the microcontroller board in a project with a lot of wires and other components attached to it.
Or…
When you need mobility to try out your new project, or you wish to have more flexibility to complete your project.
In such cases, it wouldn’t be convenient to attach and detach the Arduino board to your computer repeatedly. You’d want to supply the Arduino board with an external power source.
Moreover, continuously supplying the Arduino board with power from the computer means that you need to keep your PC turned on for an extended period, only to use a 5V USB port as a power supply. This would unnecessarily heat it and ultimately waste a lot of energy.
For these reasons, many students and hobbyists prefer running Arduino without a computer.
Then, How Do I Run My Arduino Without a Computer?
An intelligent guess would be to use an external power supply, and there are many ways to provide power from an external source.
Let’s take a look at these 4 methods to power an Arduino without a computer.
1. Plugging in a DC Adaptor
You might have noticed a black-colored DC power jack at the corner of your Arduino UNO board. If you look closely, it has a pin inside it as well, which is positive, and the outer part is grounded.
This jack is used to power the Arduino using a DC adaptor, which takes AC power (from the switchboard) and converts it into DC power, suitable for your Arduino board.
Before buying a DC adaptor to power your Arduino board, make sure you check its output voltage. It must be between 7 to 12 Volts (DC output).
Moreover, the adaptor should have a female output with a 2.1 mm inner diameter and an outer diameter of 5.5 mm. This adaptor is very common, and you can easily find it in any electronics store. It’s used to charge many appliances, such as emergency lights and torches.
But wait, Arduino operates on 5 Volts, so why are we using an adaptor that supplies at least 7 volts?
The answer to this question is the regulation circuitry present on your Arduino board. This circuitry converts the power supplied to it into 5 Volts, and it requires at least 7 Volts to regulate it down to 5 Volts.
The silver-colored mini cylinders you see right beside the DC jack on your Arduino UNO board are the voltage regulators.
If you need a portable solution to use with the DC power jack then, you can use a 9V battery connected to a 2.1mm DC plug adaptor. This plug will fit into the power jack present on the Arduino board and power it on.
Unfortunately, with the advantage of portability, there’s a downside to this solution: The batteries will eventually run out at some point, and that’s when you’d have to either replace the batteries or use rechargeable ones.
2. Connecting to the 5V Pin
You can use the 5V pin on your board to run Arduino without a computer, but it’s a bit risky. You need to be very careful with this option because if you supply a voltage higher than 5 Volts, then you might destroy the board.
It’s best to use a regulated 5 Volts supply to power the Arduino using 5V and GND pins.
To provide an extra layer of security, you can consider using a 5.1V Zener diode to protect your Arduino from burning out. This method should be your last resort because it has a high level of risk, so I don’t recommend using this method as your first resort.
3. Using the Vin Pin
Another method to power up your Arduino without the need of a computer is to use the Vin pin present on it.
This pin is also regulated, just like the power jack, so that you can provide a DC input ranging from 7 Volts to 12 Volts.
The best is to use a 9V battery to power up your Arduino via the Vin and GND pins. For this, you will need the following:
- A 9V battery.
- One connector (with a positive and negative wire coming out of it).
- Two male-to-male jumper wires.
- Electrical tape.
- Your Arduino board.
How to connect the Vin pin?
- Connect each of the jumper wires to each of the wires coming out of the 9V battery connector, using a tape.
- Connect the battery to its connector and plug in the positive wire in the Vin pin and the negative wire into the GND pin on your Arduino board.
A 9V battery is enough to perform the essential functions in an Arduino board, but if you need to use a 12 Volt battery because of your project requirements, then you must make sure that its current value does not exceed 500 mA.
4. Using a Battery Shield
Another great way to run your Arduino without a computer is to use a battery shield. It comes with a micro USB port for charging the batteries and a battery holder on top of it. This shield is a convenient option since you can stack it on top of your Arduino UNO board.
If you don’t wish to buy an Arduino shield, then guess what? You can build yours using a mobile battery and some basic Arduino modules.
For a detailed guide to building your own Arduino battery shield, click here.
Final Thoughts
So, now that you know how to run Arduino without a computer, you can easily make portable devices and robots using your board.
You won’t have to plug in the Arduino board to your computer and keep it powered on for hours. With this approach, not only you’re opening the doors of portability, but also playing your part in saving the planet since you’ll save a lot of energy wasted by leaving your computer on.
I wish you all the best in your new adventures of running your Arduino projects without a computer and saving energy at the same time!
Have you used other sources than those mentioned in the article to power your Arduino board? Let me know in the comments. I am looking forward to learning from you!