Arduino Basics

by Santhana_krishnan in Circuits > Arduino

675 Views, 0 Favorites, 0 Comments

Arduino Basics

beda-arduino-uno-r3-dengan-mega-2560-pro-mini-nano.jpg
18-THE-ULTIMATE-ARDUINO-BOARD-GUIDE.jpg

Hi Guys,
In this instructable, let's learn the basics of using an Arduino Board.
Arduino is an open-source electronics platform based on easy-to-use hardware and software. Arduino boards are able to read inputs - light on a sensor, a finger on a button, or a Twitter message - and turn it into an output - activating a motor, turning on an LED, publishing something online. You can tell your board what to do by sending a set of instructions to the microcontroller on the board. To do so you use the Arduino programming language (based on Wiring), and the Arduino Software (IDE), based on Processing.

First, let's see the common types of Arduino boards and their characteristics.

  1. Arduino UNO
  2. Arduino NANO
  3. Arduino MEGA

Supplies

We need a PC preferably with Windows OS and your Arduino Board and a USB cable.(Type of USB will be discussed below)

Arduino UNO

Pn460RlyoUY8tkOH50hAnqJGJzRDbhhTUbuYRtOk.jpg

Arduino UNO!
The most commonly used board by beginners. It's a Prety cool board and it can be used in the majority of the applications.
This costs around 23$ and other replicas of UNO are also available in the market.

Click here to buy ARDUINO UNO the original version.

This Arduino board depends on an ATmega328P based microcontroller.
It consists of 14-digital I/O pins, where 6-pins can be used as PWM(pulse width modulation outputs), 6-analog inputs, a reset button, a power jack, a USB connection, an In-Circuit Serial Programming header (ICSP), etc.

It includes everything required to hold up the microcontroller; simply attach it to a PC with the help of a USB cable and give the supply to get started with an AC-to-DC adapter or battery.

You need a type-B USB cable to program this Arduino UNO.

Click here to know more about ARDUINO UNO

Arduino NANO

3ZqE9S79VkN38JjnzTsposKBw99gTgwl6PBp0Wcb.jpg

Arduino NANO!
As the name suggests it's a smaller version of Arduino UNO with its own features. This board can be used in small-sized projects and lightweight projects.
It costs around 21$.
Click here to buy ARDUINO NANO

This board is based on the microcontrollers like ATmega328P otherwise ATmega628 but the connection of this board is the same as to the Arduino UNO board.

This board mainly includes analog pins-8, digital pins-14 with the set of an I/O pin, power pins-6 & RST (reset) pins-2.
Arduino NANO uses USB mini Type-B.
Click here to know more about ARDUINO NANO

Arduino MEGA

kW9ubo4azflAddfjqAZrR8WIS69KY015nG2NktJx.jpg

Arduino MEGA!
This is a huge board with many pins and higher processing capabilities.
Click here to buy ARDUINO MEGA
It includes 54 digital I/O pins (from that, 14-pins can be used as PWM o/ps), 6-analog inputs, a reset button, a power jack, a USB connection, and a reset button.
The huge number of pins make this Arduino board very helpful for designing projects that need a bunch of digital i/ps or o/ps like lots of buttons.
The CPU is clocked at 16MHz and includes 256KB of ROM, 8KB of RAM, 4KB of EEPROM, and operates at 5V making it easy to use with most hobby-friendly electronics.

Click here to know more about ARDUINO MEGA

The Software

arduinoThumb.jpg

To program an Arduino you need a Software tool

  • The Arduino IDE for Computers
  • Applications for Mobile phones
    (Yes! you can program an Arduino using your Android phone)

For PC's
->WINDOWS VERSION

->WINDOWS APP (for 8.1 and above)

->LINUX 32 BIT VERSION

->LINUX 64 BIT VERSION

->LINUX ARM 32 BIT VERSION

->LINUX ARM 64 BIT VERSION

->MAC VERSION (10.10 or newer)


(If you are interested in Linux Visit our Blog How to install Kali Linux on Windows Machine)

For Android Phones
->ArduinoDroid

->Bluino Loader

Now let us see how to program your Arduino.

Programming Arduino Using a PC

1.png
2.png
3.png
4.png

Using the previous Links shared Download and install the right software for your device.

Follow the steps and Program your Arduino.

  1. Open the Arduino Ide software
  2. Click on File->Examples->Basics->Blink a new window with pre-written code pops up. This code makes the inbuilt LED bulb on the Arduino to blink every 1 second (1000 microseconds)
  3. Connect your Arduino using the correct USB cable as mentioned in the previous steps.
  4. Click on Tools->Board->Arduino UNO (Assuming you are now using the UNO board. If you are using other boards choose accordingly from the list).
  5. Now, click on Tools->Port->COM x (When you plug your Arduino board, then a new COM port will appear like COM5/COM12 depending on your device. Choose that port).
  6. Now Click on the Verify button to compile that code and then the Upload button to upload the code to the connected Arduino.
  7. Now your Arduino Starts working as you programmed.

Check out other example codes and start making projects from Instructables Arduino or the Arduino Community or any other source.

Programing Arduino Using Android Phones

unnamed (jj1).jpg
unnamed (1).jpg
41MBSHsQ29L.jpg

Previously I mentioned 2 Mobile apps that can program Arduino using your Smart Phone.

You need an extra hardware-OTG cable
The same Cable you use to copy files to a Pendrive from your Smartphone.
For those who have not seen an OTG Cable yet. Check the above image.
Check and buy the right OTG cable for your mobile device (Check the PIN and Socket type of your mobile).
To check if your Mobile Phone is OTG Compatible-> Click Here
If your Phone is not OTG Compatible, You can still Program your Arduino using Bluetooth Module (HC-05)


1. Arduino Droid
Write with code complete and libraries, compile, upload Arduino or ESP8266/ESP32 sketches over USB or WiFi and monitor your board right from your Android device with ArduinoDroid. No internet connection, no cloud service account is required.

2.Bluino Loader
Bluino Loader is an Arduino programmer software (Arduino IDE) runs on android, makes it easy to write sketch code, compile sketch to generate hex file and upload it to Bluino or various Arduino board via USB OTG or wireless Bluetooth.

Troubleshooting

Code Not Uploading.

  1. Check if you have selected the correct board and port.
  2. Check if the USB Drivers are up to date.
  3. Some Arduino like boards needs special Libraries to work, Check them here

Code Uploaded Successfully but LED not blinking.

  1. Check if the LED has turned brown. (If yes! then your inbuilt LED is fused and won't work again, but the rest function of the board still works well).

For other Queries, Drop a comment in the Comment section
I will try to reply within a day mostly.

Check out the cool stuff at Arduino Forum and there are not just 3 boards....there is a lot to explore!
www.arduino.cc

Thank You and keep learning and keep sharing your knowledge.