Ultimate Arduino Uno Hardware Manual: The Best Resources

Resources for the Ultimate Arduino Uno Hardware Manual can be found on this page, including web links, Arduino sketches from the book, and downloads. Report and find errata for the book at the bottom of this page. Either scroll down the page to find what you are looking for, or expand the table of contents below and click a link to jump to the desired section. The main sections on this page are:

  • Downloads: Links to the downloadable files from the book
  • Web Links: All of the websites referenced in the book in an easy to click format
  • Arduino Sketches: Code for all the sketches in the book in an easy to copy format
  • Extra Images and Screen Captures: Image resources that enhance explanations in the book
  • Errata: Check errata for the book or report any errors that you found in the book
Table of Contents

Ultimate Arduino Uno Hardware Manual Downloads

Find the downloads for the Ultimate Arduino Uno Hardware Manual below. They include a PDF drill template file for the Arduino Uno board, and KiCad template files.

PDF Drill Template File from the Ultimate Arduino Uno Hardware Manual

The drill template file: arduino-uno-hardware-drill-template.pdf
To save, right-click the link and choose Save Link As (or similar menu item, depending on browser) from the menu that pops up.

Important: Be sure to print the drill template file using a 1:1 scale (or 100%), so that the template is not resized. After printing the template to a page, measure the 1cm or 1 inch markings to make sure that the page printed to scale.

KiCad Template File from the Ultimate Arduino Uno Hardware Manual

KiCad template file for Arduino Uno and Arduino Uno shield: arduino-uno-template_1_3.zip

The KiCad template files were created using KiCad version 5.1.5 and need to be unzipped from the downloaded zip file before opening with KiCad. The template contains schematic and board files with the Arduino Uno header sockets and drill holes placed in the correct positions on the board, ready for starting a new shield or Arduino board project.

Below are web links from the Ultimate Arduino Uno Hardware Manual for easy access to referenced websites. Find the main Arduino website at www.arduino.cc

Scroll down to find the chapter and section that contains the link that you are looking for, or use the table of contents near the top of this page to jump to the desired chapter on this page.

Chapter 1 of the Ultimate Arduino Uno Hardware Manual

1.1.3 Uses of the Arduino Uno

Wiring project wiring.org.co

Arduino Project Hub create.arduino.cc/projecthub

1.1.4.11 ICSP Header

Those interested in learning the C language to program Arduino boards may be interested in the book C Programming with Arduino ISBN 978-1-907920-46-2

1.1.5 Programming

The Arduino IDE is free to download from www.arduino.cc/en/software

1.1.6.2 Prototype Shields

TSX00083 (store.arduino.cc/proto-shield-rev3-uno-size)

1.1.6.5 Custom PCB

KiCad (kicad.org) is an open-source EDA (Electronic Design Automation) software package that can be used to draw circuit diagrams and lay out PCBs.

1.1.7 Open-Source and Licensing

See creativecommons.org/licenses/ for more information on the various Creative Commons licenses.

For more details, see the page www.arduino.cc/en/Trademark on the Arduino website.

1.1.8 Third Party Compatible Boards

For more information on the various spin-off boards including official boards, clones, derivatives, compatibles and even counterfeits, see the article blog.arduino.cc/2013/07/10/send-in-the-clones/ on the Arduino blog.

1.1.9 Build Quality, Warranty and Safety

A full list of official Arduino boards can be found at www.arduino.cc/en/Main/Products on the Arduino website.

For more information on Arduino board compliance and for the warranty statement, see www.arduino.cc/en/Main/warranty

1.2.1 USB Bridge Firmware

The ATmega16U2 microcontroller and its firmware replaces the FT232RL USB to UART bridge chip from FTDI (ftdichip.com) found on older Arduino boards (the Arduino Duemilanove www.arduino.cc/en/Main/arduinoBoardDuemilanove for example).

1.4 Arduino Uno History and Revisions

Readers who would like more information, see startingelectronics.org/articles/arduino/uno-r3-r2-differences/ for a full list of the differences between R1, R2 and R3 Arduino Uno boards.

1.6 Arduino Uno References and Help

Find the supporting website for this book at wspublishing.net and click the book name to go to its area on the website. Also find resources for this book on the Elektor website at www.elektor.com where the book can be searched for.

1.6.1 Installing Software

Help documentation on installing the Arduino IDE software is available for Windows, MAC OS X and Linux. Follow the links below for your operating system.

1.6.1.1 Windows

www.arduino.cc/en/Guide/Windows

1.6.1.2 MAC OS X

www.arduino.cc/en/Guide/MacOSX

1.6.1.3 Linux

www.arduino.cc/en/Guide/Linux

1.6.2 Getting Started, Examples and Reference

Getting started guides, examples and a software reference are all available on the Arduino website. Getting started guides and examples are a great way for new Arduino users to learn about building projects with Arduino and learning to write sketches.

1.6.2.1 Getting Started Guides

Links to getting started guides for any Arduino board can be found at:
www.arduino.cc/en/Guide

Arduino Uno specific getting started guide:
www.arduino.cc/en/Guide/ArduinoUno

1.6.2.2 Arduino Examples and Tutorials

An index to tutorials and examples at www.arduino.cc/en/Tutorial/HomePage on the Arduino website provides links to various categories.

1.6.2.3 Building Breadboard Circuits

A tutorial series at startingelectronics.org/beginners/start-electronics-now/ shows how to build breadboard circuits with some Arduino examples.

1.6.2.4 Arduino Software Reference

Arduino language and library reference: www.arduino.cc/reference/en/

1.6.3 Getting Help

Find the Arduino Help Center at support.arduino.cc/hc/en-us which contains a searchable help index, as well as several categories of FAQs (Frequently Asked Questions).

The Arduino Playground at playground.arduino.cc/Main/ElectroInfoResources is a user contributed collection of documentation and other useful information.

The Arduino Forum at forum.arduino.cc is a place where anyone can post a question that will be answered by community members. The forum can also be searched for other user’s questions which may already have answers. It is also a place where more experienced Arduino users can help others by answering questions.

Several open-source projects are related to Arduino, are used in education like Arduino, and are useful to Arduino users. An overview of Arduino would not be complete without mentioning the projects in the sections that follow.

1.6.4.1 Fritzing

Fritzing, found at fritzing.org on the web, provide a software package that can be used to draw Arduino breadboard circuits and then turn them into custom made printed circuit boards or PCBs.

1.6.4.2 Wiring

Find the Wiring project at wiring.org.co on the web.

1.6.4.3 Processing

Processing, found at processing.org on the web, is a programming language based on Java, and a software package for developing applications on a computer.

For more information, see www.arduino.cc/en/Tutorial/BuiltInExamples/PhysicalPixel on the Arduino website.

1.6.5 Arduino Uno Boards on the Web

Links to the web pages on the Arduino website for the Arduino Uno and Arduino Uno SMD boards follow.

1.6.5.1 Arduino Uno Web Page

Find the Arduino Uno web page at store.arduino.cc/arduino-uno-rev3 which includes basic technical information and links to the circuit diagram and board build files in electronic format.

1.6.5.2 Arduino Uno SMD Web Page

Go to store.arduino.cc/arduino-uno-smd-rev3 for the newest information on the Arduino Uno SMD, or to www.arduino.cc/en/Main/ArduinoBoardUnoSMD for the Arduino Uno SMD board page on the Arduino website. An electronic copy of the circuit diagram for the Arduino Uno SMD can be found here as well as the build files.

Chapter 2 of the Ultimate Arduino Uno Hardware Manual

2.2 Atmel, Microchip and AVR

Microchip (www.microchip.com)

2.3.3.1 EEPROM Programming

Refer to the library reference www.arduino.cc/en/Reference/EEPROM for more information on using the EEPROM in sketches.

2.3.4.1 SD Cards (SPI Interface)

See www.arduino.cc/en/Reference/SD for more information on the Arduino SD card library.

2.3.4.3 SPI Devices

See the library reference www.arduino.cc/en/Reference/SPI for more information on the SPI library.

2.3.4.4 TWI and I²C Devices

See the library reference www.arduino.cc/en/Reference/Wire for more information on the Wire library.

2.7.5.1 Analog In Example Sketch

The corresponding tutorial page for the AnalogReadSerial example sketch is found on the Arduino website at www.arduino.cc/en/Tutorial/BuiltInExamples/AnalogReadSerial, and shows how to connect a potentiometer to A0 to vary the voltage on this pin.

2.7.6 AREF Pin

For more information on the analogReference() function, see www.arduino.cc/reference/en/language/functions/analog-io/analogreference/

2.8.3 ATmega16u2 ICSP Header

More information on DFU programming can be found at www.arduino.cc/en/Hacking/DFUProgramming8U2 on the Arduino website and in section 5.1 of chapter 5 of this book.

2.8.4 ICSP Programming Resources

The following links provide more information on the Atmel-ICE,C programming of Arduino boards using Microchip/Atmel Studio, and Microchip Studio. Also see Chapter 5.

Atmel-ICE – www.microchip.com/developmenttools/ProductDetails/atatmel-ice

C Programming – wspublishing.net/avr-c/

Microchip Studio – www.microchip.com/en-us/development-tools-tools-and-software/microchip-studio-for-avr-and-sam-devices

2.8.5 Using an Arduino as an In-System Programmer

Find more information on the Arduino website at www.arduino.cc/en/Tutorial/BuiltInExamples/ArduinoISP

Chapter 3 of the Ultimate Arduino Uno Hardware Manual

3.2.2 ATmega328P Alternate Pin Functions

More information on each pin function can be found in the ATmega328 datasheet from the page www.microchip.com/wwwproducts/en/ATmega328P on the Microchip website.

3.3.1.1 Pins as Outputs
Switching Heavier Loads with Transistors and Relays

For more details on interfacing Arduino boards and microcontrollers, refer to the appropriate texts or other sources such as the Interfacing With Hardware page playground.arduino.cc/Main/InterfacingWithHardware in the playground area on the Arduino website.

3.3.1.2 Pins as Inputs
Pull-down Resistor

Find the tutorial page at www.arduino.cc/en/Tutorial/BuiltInExamples/DigitalReadSerial on the Arduino website.

3.3.2 PWM Pins

( Taken from www.arduino.cc/reference/en/language/functions/analog-io/analogwrite/ )

3.3.4.2 Accessing TWI Devices in Software

This means including the Wire.h header file in a sketch and using the Wire library object and functions found in the reference www.arduino.cc/en/Reference/Wire on the Arduino website.

3.3.5.2 Accessing SPI Devices in Software

Use the SPI object and functions from www.arduino.cc/en/Reference/SPI – the SPI reference page on the Arduino website.

3.3.5.3 Accessing SD Cards in Software

Go to www.arduino.cc/en/Reference/SD to find the SD card reference on the Arduino website.

3.3.6.1 Hardware Serial Port

Go to www.arduino.cc/reference/en/language/functions/communication/serial/ for the serial port library reference.

3.3.6.2 Software Serial Port

Go to www.arduino.cc/en/Reference/SoftwareSerial on the Arduino website for more information on the SoftwareSerial library.

3.7 Finding the Datasheets

3.7.1 ATmega328P Datasheet

Find the ATmega328P datasheet at www.microchip.com/wwwproducts/en/ATmega328p on the Microchip website.

3.7.2 ATmega16U2 Datasheet

Go to www.microchip.com/wwwproducts/en/ATmega16u2 to find the datasheet for the ATmega16u2 microcontroller used as the USB to serial bridge chip on Arduino Uno boards.

Chapter 4 of the Ultimate Arduino Uno Hardware Manual

No links.

Chapter 5 of the Ultimate Arduino Uno Hardware Manual

5.1 Updating the USB to Serial Bridge Firmware using DFU

For Windows computers, download the FLIP (Flexible In-system Programmer) software from Microchip at www.microchip.com/developmenttools/ProductDetails/FLIP

For additional information on Arduino DFU programming and for DFU programming using Linux and Mac, see www.arduino.cc/en/Hacking/DFUProgramming8U2 on the Arduino website.

5.2 Microchip Studio

USB ProgrammerPart NumberWeb Page
Atmel-ICEatatmel-icewww.microchip.com/developmenttools/ProductDetails/atatmel-ice
AVRISP mkII
(no longer available)
atavrisp2www.microchip.com/developmenttools/ProductDetails/atavrisp2
AVR Dragon
(no longer available)
ATAVRDRAGONwww.microchip.com/Developmenttools/ProductDetails/ATAVRDRAGON

To install Microchip Studio, go to www.microchip.com/en-us/development-tools-tools-and-software/microchip-studio-for-avr-and-sam-devices on the Microchip website.

5.3.1 Backing up the ATmega16U2 Firmware with Microchip Studio

As few users will need to program the ATmega16U2, rather than use up space in this book with an image of the connection, refer to wspublishing.net, the supporting website for an image of the connection.

5.3.2 DFU Bootloader Firmware

Go to github.com/arduino/ArduinoCore-avr/tree/master/firmwares/atmegaxxu2/arduino-usbdfu which is a copy of the same source code at GitHub.

5.3.3 USB to Serial Bridge Firmware

The same source code and HEX files can be found on GitHub at github.com/arduino/ArduinoCore-avr/tree/master/firmwares/atmegaxxu2/arduino-usbserial which contains the latest version of this code and HEX files.

5.4.2 Optiboot Bootloader Firmware

The same files can be found at github.com/arduino/ArduinoCore-avr/tree/master/bootloaders/optiboot on GitHub.

The Optiboot project on GitHub is at github.com/Optiboot/optiboot

Optiboot wiki can be found at github.com/Optiboot/optiboot/wiki

See github.com/Optiboot/optiboot/wiki/HowOptibootWorks for more details.

5.6 Alternative Firmware Programming Methods

Alternative methods for programming the bootloader to an Arduino Uno can be found at playground.arduino.cc/Main/ArduinoCoreHardware#Bootloader at the Arduino playground under the Bootloader section.

Using an Arduino as an ISP (In-system programmer) is also described on the Arduino website at www.arduino.cc/en/Tutorial/BuiltInExamples/ArduinoISP

Refer to www.arduino.cc/en/Hacking/DFUProgramming8U2 for additional information on DFU programming the ATmega16u2.

Chapter 6 of the Ultimate Arduino Uno Hardware Manual

6.4 Getting an Electronic Copy of the Circuit Diagram

Find the circuit diagram in PDF format, and the circuit diagram and PCB design file in Eagle format at store.arduino.cc/arduino-uno-rev3 for the Arduino Uno. Look under the DOCUMENTATION tab for these files.

To view the files in Eagle format, the Eagle EDA software package will need to be downloaded from www.autodesk.com/products/eagle/free-download and installed.

Chapter 7 of the Ultimate Arduino Uno Hardware Manual

7.4 Waveform Patterns and Measurement

PicoScope 2000 series digital PC oscilloscope, model number 2205A used for oscilloscope measurements.

Chapter 8 of the Ultimate Arduino Uno Hardware Manual

8.7 Using Strip-board as a Shield

See startingelectronics.org/projects/arduino-projects/arduino-tiny-stripboard-shield/ for an example of fitting a piece of strip-board to an Arduino Uno using only three of the header sockets on the Arduino. An example project that uses the strip-board shield can be found at startingelectronics.org/projects/arduino-projects/arduino-tiny-temperature-shield/

8.8 Drill Template and KiCad Template

The drill template file as well as the KiCad template file can be found on the downloads section of this page.

The KiCad software package can be found at kicad.org where it can be downloaded free of charge and unrestricted.

Arduino Sketches from the Ultimate Arduino Uno Hardware Manual

Arduino Sketches from the Ultimate Arduino Uno Hardware Manual can be found below. Select the desired sketch and copy the code, then paste it to the Arduino IDE. Sketches are displayed below under the section number that they occur in in the book, with the page number that they can be found on.

1.5.2.2 – Page 45

Modified Blink sketch.

void setup() {
  pinMode(LED_BUILTIN, OUTPUT);     // configure L LED pin as output
}

void loop() {
  digitalWrite(LED_BUILTIN, HIGH);  // switch L LED ON
  delay(200);                       // leave L LED ON for period
  digitalWrite(LED_BUILTIN, LOW);   // switch L LED OFF
  delay(200);                       // leave L LED OFF for period
}

2.7.4.1 – Page 71

Arduino Uno pin 12 configured as an output and driven high and low.

void setup() {
  pinMode(12, OUTPUT);    // configure digital pin 12 as an output pin
}

void loop() {
  digitalWrite(12, HIGH); // set pin 12 voltage to 5V on an Arduino Uno
  delay(500);
  digitalWrite(12, LOW);  // set pin 12 voltage to 0V or GND
  delay(500);
}

2.7.4.1 – Page 72

Defining a pin with a user friendly name.

#define MY_LED  12

void setup() {
  pinMode(MY_LED, OUTPUT);    // configure digital pin as an output pin
}

void loop() {
  digitalWrite(MY_LED, HIGH); // set pin voltage to 5V on an Arduino Uno
  delay(500);
  digitalWrite(MY_LED, LOW);  // set pin voltage to 0V or GND
  delay(500);
}

2.7.4.4 – Page 75

Arduino Uno PWM on pin 3 with 50% duty cycle.

void setup() {
  pinMode(3, OUTPUT);

  analogWrite(3, 127);
}

void loop() {
}

2.7.5.3 – Page 79

Calculating analog input voltage on Arduino Uno A0 pin.

void setup() {
  Serial.begin(9600);
}

void loop() {
  int sensorValue = analogRead(A0);                     // read ADC value
  float voltage = (5.0 / 1024.0) * (float)sensorValue;  // calculate voltage
  Serial.print(voltage);                                // display voltage
  Serial.println(" V");
  delay(1);
}

2.7.5.5 – Page 80

Arduino Uno analog pin A0 used as a digital output pin.

void setup() {
  pinMode(A0, OUTPUT);
}

void loop() {
  digitalWrite(A0, HIGH);
  delay(500);
  digitalWrite(A0, LOW);
  delay(500);
}

3.3.1.2 – Page 106

Pull-down Resistor

Read Arduino Uno pin 2 state with pull-down resistor.

void setup() {
  pinMode(LED_BUILTIN, OUTPUT);
  pinMode(2, INPUT);
}

void loop() {
  if (digitalRead(2)) {
    // pin state is high or 1, switch is closed (pull-down resistor)
    digitalWrite(LED_BUILTIN, HIGH);  // switch L LED on
  }
  else {
    // pin state is low or 0, switch is open (pull-down resistor)
    digitalWrite(LED_BUILTIN, LOW);   // switch L LED off
  }
}

3.3.1.2 – Page 108

Pull-up Resistor

Read Arduino Uno pin 2 state with pull-up resistor.

void setup() {
  pinMode(LED_BUILTIN, OUTPUT);
  pinMode(2, INPUT);
}

void loop() {
  if (digitalRead(2)) {
    // pin state is high or 1, switch is open (pull-up resistor)
    digitalWrite(LED_BUILTIN, LOW);    // switch L LED off
  }
  else {
    // pin state is low or 0, switch is closed (pull-up resistor)
    digitalWrite(LED_BUILTIN, HIGH);   // switch L LED on
  }
}

3.3.1.2 – Page 109

Internal Pull-up Resistors

Read Arduino Uno pin 2 state with internal pull-up resistor enabled.

void setup() {
  pinMode(LED_BUILTIN, OUTPUT);
  pinMode(2, INPUT_PULLUP);
}

void loop() {
  if (digitalRead(2)) {
    // pin state is high or 1, switch is open (pull-up resistor)
    digitalWrite(LED_BUILTIN, LOW);    // switch L LED off
  }
  else {
    // pin state is low or 0, switch is closed (pull-up resistor)
    digitalWrite(LED_BUILTIN, HIGH);   // switch L LED on
  }
}

3.3.4.2 – Page 113

Read the first byte from an AT24C16C EEPROM connected to the Arduino Uno TWI bus pins.

// Reads a single byte from a AT24C16C EEPROM on the TWI or I2C bus
#include <Wire.h>

void setup() {
  Wire.begin();         // join TWI bus as a master
  Serial.begin(9600);   // for displaying results in Serial Monitor window
  
  // *** Perform Random Read ***
  // address byte 0 of EEPROM
  Wire.beginTransmission((0xA0 >> 1));
  Wire.write(0x00);
  Wire.endTransmission();
  // read 1 byte from EEPROM at address 0
  Wire.requestFrom((0xA0 >> 1), 1);
  // *** End Perform Random Read ***

  while (Wire.available()) {          // check for response from EEPROM
    byte data8 = Wire.read();         // read byte from the EEPROM
    Serial.print("Byte read is: ");
    Serial.println(data8, HEX);       // display the byte
  }
}

void loop() {
}

7.4.2 – Page 172

Use all of the PWM pins on the Arduino Uno to produce PWM waveforms with different duty cycles.

void setup() {
  analogWrite(3, 51);     // PWM 20% 490Hz
  analogWrite(5, 89);     // PWM 35% 976Hz
  analogWrite(6, 127);    // PWM 50% 976Hz
  analogWrite(9, 166);    // PWM 65% 490Hz
  analogWrite(10, 204);   // PWM 80% 490Hz
  analogWrite(11, 230);   // PWM 90% 490Hz
}

void loop() {
}

7.4.3 – Page 172

Arduino Uno serial port or UART test square wave.

void setup() {
  Serial.begin(9600);
}

void loop() {
  Serial.print('U');
}

7.4.5 – Page 175

Send a character on the Arduino Uno SPI bus.

#include <SPI.h>

void setup() {
  SPI.begin();
  SPI.beginTransaction(SPISettings(10000, MSBFIRST, SPI_MODE1));
}

void loop() {
  SPI.transfer('U');
  delay(1);
}

Extra Images and Screen Captures

Extra images and screen captures for the Ultimate Arduino Uno Hardware Manual can be found here. Click a link below to jump to the desired section on the page.

5.1 – Page 134 : FLIP Software

FLIP software for updating the USB to serial bridge firmware using the DFU method from section 5.1 Updating the USB to Serial Firmware using DFU.

Select the ATmega16U2 Device

Select the device to program in the FLIP software.

Open the USB Port

Open the USB port of the target device in the FLIP software. Click the Open button in the dialog box to continue.

Select the Correct Hex File

Load the HEX file for the ATmega16U2 in the FLIP application software.

Program the ATmega16U2

Click the Run button to erase, program and verify the Flash memory of the ATmega16U2.

Programming Completed

The FLIP software application as it appears after successfully programming the target device.

5.3.1 – Page 137 to Page 138 : ATmega16U2 ICSP Connection

The procedure for connecting the ISP plug of a USB programmer into the ICSP header for the ATmega16U2 on an Arduino Uno follows. This is described in section 5.3.1 Backing up the ATmega16U2 Firmware with Microchip Studio of the Ultimate Arduino Uno Hardware Manual.

Key on ISP Connector Blocks Connection

As can be seen in the image below, the key on the ISP connector of the programmer prevents it from being plugged into the ICSP header for the ATmega16U2 on an Arduino Uno.

Wires Used for Connection

Six wires that have a single pin male connector on one end and single pin female connector on the other end can be used to connect the ISP plug to the Arduino Uno ATmega16U2 ICSP header. The wires can be seen in the image below.

Plug the Wires into the ISP Plug

Plug the wires, three at a time, into the ISP Plug as the image below shows.

Plug the Wires into the ICSP Header

Now plug the extension wires from the ISP plug to the ICSP header.

The next image shows the extension wires connecting from the ISP plug of the USB programmer to the ICSP header for the ATmega16U2 on an Arduino Uno.

A close-up of the connection can be seen in the following image.

Ultimate Arduino Uno Hardware Manual Errata

Report errata for the Ultimate Arduino Uno Hardware Manual on our Contact Us page. Be sure to clearly state the book name and edition when reporting errata. In addition, give the page number and section number and name. Clearly state and explain the errata that you are reporting.

Errata submitted are included below.

None yet!