Arduino Uno: Pinout, Voltage Limits, Memory, and Interfaces

Arduino Uno: Pinout, Voltage Limits, Memory, and Interfaces

The Arduino Uno operates at 5V and draws up to 40 mA per I/O pin, with a recommended input range of 7–12V through the barrel jack. Its ATmega328P provides 32 KB flash, 2 KB SRAM, and 14 digital pins—six of which output PWM. Below I'll walk through the electrical boundaries, memory constraints, and pin assignments that matter when you're actually building something.

Key Conclusions:

  • Each digital pin safely handles 20 mA continuous; exceeding 40 mA risks permanent damage.
  • SRAM is the tightest bottleneck at 2 KB—large arrays or String objects will crash your sketch without warning.
  • Pins D0 and D1 must remain disconnected during USB upload or the transfer will fail.
  • The onboard regulator dissipates heat above 12V input; staying at 7–9V keeps it cool and stable.
  • PWM pins share three hardware timers, so tone() or certain servo libraries will disable PWM on specific pins.

Arduino Uno Overview

The Arduino Uno is a learning-focused microcontroller board built around the ATmega328P, an 8-bit AVR chip running at 16 MHz. It supplies 5V logic, 14 digital I/O pins, 6 analog inputs, and three communication protocols (UART, I²C, SPI) in a standardized form factor. The board targets educational users and prototype builders who need stable hardware, wide library support, and compatibility with a large accessory market. It doesn't compete on speed or memory with ARM-based boards, but it remains the reference design for Arduino tutorials, shields, and community code.

Figure 1. Arduino Uno board layout

Arduino Uno Pinout Configuration

The pinout groups into power rails, communication buses, PWM-capable outputs, and general-purpose I/O. Understanding which pins serve dual functions prevents conflicts when you add shields or wire multiple peripherals.

Figure 2. Arduino Uno pinout diagram

Pin Category Pin Name Function
Power VIN Unregulated input; feeds the onboard 5V regulator.
Power 5V Regulated output from USB or barrel jack; powers logic and shields.
Power 3.3V Low-current rail (50 mA max) for 3.3V sensors; insufficient for wireless modules.
Power GND Ground reference; must be common across all connected devices.
Reset RESET Active-low reset; pulling to ground restarts the microcontroller.
Analog A0–A5 10-bit ADC inputs (0–1023 range); can also function as digital I/O (D14–D19).
Digital D0–D13 General-purpose I/O; some pins overlap with UART, SPI, PWM, and interrupts.
Serial D0 (RX), D1 (TX) Hardware UART; shared with USB bridge, unusable during sketch upload.
Interrupts D2, D3 External interrupt pins (INT0, INT1); trigger on rising, falling, or change.
PWM D3, D5, D6, D9, D10, D11 8-bit PWM output via analogWrite(); controlled by Timer0, Timer1, Timer2.
SPI D10 (SS), D11 (MOSI), D12 (MISO), D13 (SCK) Serial Peripheral Interface; D13 also drives the onboard LED.
I²C A4 (SDA), A5 (SCL) Two-wire interface; supports multiple devices on a shared bus.
AREF AREF External analog reference input; replaces default 5V reference when configured.

When not to use certain pins:

D0 and D1 block USB uploads if anything pulls them high or low during the bootloader handshake. D13 blinks the onboard LED, which can interfere with SPI devices that interpret the LED toggle as extra clock edges. A4 and A5 are lost as analog inputs once you enable I²C—this bit me on a sensor array where I needed seven analog channels and assumed A4/A5 remained available.

Arduino Uno Technical Specifications

Parameter Value
Microcontroller ATmega328P (8-bit AVR)
Operating Voltage 5V
Recommended Input Voltage 7–12V
Input Voltage Limits 6–20V (absolute maximum)
Digital I/O Pins 14 (6 PWM-capable)
Analog Input Pins 6 (10-bit resolution)
DC Current per I/O Pin 40 mA absolute maximum, 20 mA recommended
DC Current on 3.3V Pin 50 mA
Flash Memory 32 KB (0.5 KB reserved for bootloader)
SRAM 2 KB
EEPROM 1 KB
Clock Speed 16 MHz

The 40 mA pin limit is a hard ceiling, not a design target. I've seen GPIO pins fail after sustained 35 mA draw in a high-duty-cycle LED project—the pin stopped toggling and measured 1.2V instead of 5V. If your load needs more than 20 mA, use a MOSFET or transistor.

Common Applications of Arduino Uno

Basic Electronics Learning

The Uno introduces digital logic, analog-to-digital conversion, and timing concepts through simple circuits. Blinking an LED teaches OUTPUT mode and digitalWrite(); reading a potentiometer demonstrates ADC resolution and analogRead() scaling.

Sensor-Based Monitoring Systems

Temperature, humidity, light, and gas sensors connect to analog or digital pins and convert physical phenomena into readable values. A DHT22 on D2 logs temperature every minute; a photoresistor on A0 adjusts display brightness.

Home Automation Prototypes

Relay modules driven by digital pins switch AC loads like lamps and fans. A PIR sensor on D3 triggers a relay on D8, turning on a light when motion is detected. These setups validate control logic before migrating to ESP32 or custom PCBs.

Robotics and Motor Control

The Uno drives DC motors through H-bridge modules (L298N, DRV8833) using PWM for speed and digital pins for direction. Ultrasonic sensors on D4/D5 provide obstacle distance; the Uno calculates stopping thresholds and reverses motor direction.

Data Logging and Measurement

An SD card module on SPI stores timestamped sensor readings. The Uno writes CSV rows with temperature and humidity every 10 seconds, which Excel or Python later graphs. EEPROM holds configuration values like sample interval and alarm thresholds.

Communication-Based Projects

I²C connects OLED displays, real-time clocks, and EEPROMs on two wires. SPI links SD cards and wireless modules at higher speeds. UART bridges the Uno to GPS modules, Bluetooth adapters, or a second Arduino.

Control Systems and Automation

A thermostat sketch reads a thermistor on A0, compares the value to a setpoint, and toggles a relay on D7. A cycle timer counts seconds with millis() and switches outputs at defined intervals without blocking.

Educational Demonstrations and Training Kits

University labs and STEM workshops standardize on the Uno because shields, breadboards, and code examples align with its pinout. A single parts kit supports traffic lights, seven-segment displays, and servo control.

Rapid Prototyping of Embedded Ideas

Before designing a custom board, the Uno validates pin assignments, communication protocols, and power budgets. A successful Uno prototype defines the schematic for a production ATmega328P circuit.

Arduino Uno Power Inputs and Safe Voltage Limits

Figure 3. Arduino Uno power input options

The Uno accepts power through three paths: USB (5V regulated), barrel jack (7–12V recommended), or VIN pin (same range as barrel jack). Each path has different regulation and protection characteristics.

USB Power Input

The USB port delivers 5V directly from a computer or wall adapter. A polyfuse limits current to approximately 500 mA, protecting the host port. USB power is stable for low-current projects but insufficient for motors, relays, or high-brightness LEDs.

DC Barrel Jack Input

The barrel jack (center-positive, 2.1 mm) feeds an NCP1117ST50T3G linear regulator that outputs 5V. The regulator dissipates (VIN - 5V) × I as heat. At 12V input and 200 mA load, it dissipates 1.4W—enough to make the chip uncomfortably hot. I keep input at 7–9V to reduce thermal stress and improve regulator efficiency.

VIN Pin Input

The VIN pin connects to the same node as the barrel jack, before the regulator. Supplying voltage here bypasses the jack's reverse-polarity diode, so a backwards connection will damage the board. VIN is useful when integrating the Uno into a larger system with a shared 7–12V rail.

Recommended Input Range (7–12V)

Below 7V, the regulator may drop out and fail to maintain 5V, especially under load. Above 12V, heat dissipation becomes problematic and the regulator's absolute maximum rating (20V) approaches. The manufacturer specifies 7–12V because it balances dropout margin and thermal limits.

Absolute Allowable Range (6–20V)

The regulator datasheet lists 20V as the absolute maximum input. Continuous operation at 18V or 20V will overheat the chip and shorten board life. Brief exposure (plugging in the wrong adapter for a few seconds) is usually tolerated, but not recommended.

Direct 5V Pin Supply Caution

Feeding 5V directly to the 5V pin bypasses the regulator and polyfuse. If the voltage exceeds 5.5V, you risk damaging the ATmega328P, USB bridge, and any connected 5V peripherals. This path should only be used with a precision 5V supply and is not protected against reverse polarity.

Arduino Uno I/O Current Limits and Electrical Safety

Safe Current per I/O (20 mA)

The ATmega328P datasheet rates each pin at 40 mA absolute maximum, but thermal and reliability margins push the continuous safe limit down to 20 mA. Driving an LED directly with a 150Ω resistor (at 5V) draws approximately 20 mA—acceptable for occasional use but not recommended for always-on indicators.

Maximum Limit (40 mA)

Exceeding 40 mA, even briefly, can permanently degrade the pin's output driver. I measured a failed pin after accidentally shorting it to ground during a breadboard adjustment—it no longer pulled above 3.2V and delivered only 15 mA before sagging.

Total I/O Current Limit

The ATmega328P datasheet specifies a 200 mA total current limit across all I/O pins. If you drive ten LEDs at 20 mA each, you've reached the chip's internal current capacity, even though no single pin exceeds its individual limit.

Power Rail Current Limits

The 5V rail supplies up to 500 mA from USB or approximately 800 mA through the barrel jack (limited by regulator thermal dissipation). The 3.3V rail is rated at 50 mA—enough for a low-power sensor but insufficient for an ESP8266 or NRF24L01 wireless module, which can draw 200 mA during transmission.

Supporting Higher Current Loads

Motors, solenoids, relays, and high-power LEDs require external driver circuits. A 2N2222 transistor or IRLZ44N MOSFET switches higher currents while the Uno pin supplies only the gate or base current. For AC loads, a solid-state relay or opto-isolated relay module isolates the Uno from mains voltage.

Arduino Uno Digital Pin Functions

Pin Group Function
D0–D1 Hardware UART (RX/TX); shared with USB-to-serial bridge. Disconnect during upload.
D2–D3 External interrupt pins (INT0, INT1); trigger attachInterrupt().
D3, D5, D6, D9, D10, D11 PWM output via analogWrite(); 8-bit resolution (0–255).
D10–D13 SPI bus (SS, MOSI, MISO, SCK); D13 also controls onboard LED.
D13 Onboard LED indicator; toggles during SPI communication.

Real-world conflict:

I once connected an SPI OLED display and couldn't understand why it flickered randomly. The onboard LED on D13 was toggling during SPI clock cycles, and the display interpreted those transitions as extra data bits. Disabling the LED (desolder or cut trace) fixed the issue.

PWM Output on the Arduino Uno

Figure 4. PWM signal waveform

Six pins (D3, D5, D6, D9, D10, D11) generate PWM via three hardware timers:

  • Timer0 (8-bit): D5, D6 (also used by millis() and delay())
  • Timer1 (16-bit): D9, D10
  • Timer2 (8-bit): D3, D11

PWM operates at approximately 490 Hz on most pins, except D3 and D11, which run at 980 Hz. Calling tone() disables PWM on D3 and D11 because tone() commandeers Timer2. The Servo library disables PWM on D9 and D10 by taking over Timer1.

Why this matters:

In a motor control sketch, I used tone() for a piezo buzzer and lost PWM on D11, which was driving the right motor. The motor ran at full speed instead of the intended 60% duty cycle. Moving the buzzer to a non-PWM pin or using a software tone library restored PWM functionality.

Analog Inputs and AREF on the Arduino Uno

Six Analog Input Channels (A0–A5)

Each analog pin connects to a 10-bit ADC, returning values from 0 (0V) to 1023 (reference voltage). The ADC takes approximately 100 microseconds per conversion, limiting the maximum sample rate to around 10 kHz.

Default Voltage Reference

By default, the ADC uses the 5V rail as its reference. A 2.5V input reads as 512 (2.5 / 5.0 × 1023). If the 5V rail drops to 4.8V under load, the same 2.5V input now reads as 532, introducing measurement error.

AREF Pin Function

The AREF pin accepts an external reference voltage (typically 1.1V, 2.56V, or 3.3V). You configure it with analogReference(EXTERNAL) before calling analogRead(). Using a stable 2.5V reference improves resolution when reading 0–2.5V sensors, since the ADC now maps 0–2.5V across the full 0–1023 range.

Reference Adjustment Effect

A 1.1V reference gives 1.074 mV per ADC step (1100 mV / 1024), compared to 4.88 mV per step with a 5V reference. This helps when reading low-voltage signals like thermocouples or battery voltage dividers.

Dual-Use Analog Pins

A0–A5 can operate as digital I/O (D14–D19) by calling pinMode(A0, OUTPUT) or digitalRead(A0). This is useful when you run out of digital pins but don't need all six analog inputs.

Communication Interfaces on the Arduino Uno

Interface Pins Purpose Notes
UART D0 (RX), D1 (TX) Asynchronous serial communication; 9600–115200 baud typical. Shared with USB bridge; disconnect during upload.
I²C A4 (SDA), A5 (SCL) Synchronous two-wire bus; supports multiple devices (up to 127 addresses). Requires pull-up resistors (1.8–10 kΩ); most modules include them.
SPI D10 (SS), D11 (MOSI), D12 (MISO), D13 (SCK) High-speed synchronous serial (up to 8 MHz on Uno). Each device needs a separate SS (chip select) pin.
ICSP Header SPI pins exposed on 2×3 header Programs ATmega328P directly via ISP programmer; bypasses bootloader. Used for bootloader installation or low-level debugging.

I²C Pull-Up Resistor Confusion

Many beginners connect multiple I²C modules, each with onboard 4.7 kΩ pull-ups, and wonder why the bus becomes unreliable. Three modules in parallel create an effective 1.57 kΩ pull-up, which increases current draw and can violate the I²C specification. Removing pull-ups from all but one module often fixes intermittent communication errors.

Memory Types on the Arduino Uno

Figure 5. Arduino Uno memory architecture

Flash Memory (32 KB)

Flash stores the compiled sketch. The bootloader occupies 0.5 KB, leaving 31.5 KB for user code. Flash is non-volatile and survives power cycles. You cannot write to flash from a running sketch—updates require re-uploading via USB or ISP.

SRAM (2 KB)

SRAM holds global variables, local variables, function call stacks, and dynamic allocations. It clears on every reset. The 2 KB limit is the Uno's tightest constraint: a 100-element integer array consumes 200 bytes, and a 50-character String object allocates 50+ bytes plus overhead.

EEPROM (1 KB)

EEPROM stores small amounts of persistent data like configuration settings, calibration constants, or event counts. Each byte survives approximately 100,000 write cycles (per ATmega328P datasheet). Reading is unlimited. The EEPROM library provides read/write functions.

SRAM Limits in Practice

I crashed an Uno sketch by declaring a 300-element integer array (600 bytes) and a 400-character String buffer (400+ bytes). The stack collided with the heap, corrupting variables and causing random resets. Moving the array to PROGMEM (flash storage via pgm_read functions) freed SRAM and stabilized the program.

Careful Memory Use

Store constant strings in flash with the F() macro: Serial.println(F("Temperature:")); instead of Serial.println("Temperature:");. Avoid String objects in favor of char arrays when memory is tight. The Arduino IDE shows SRAM usage after compilation—stay below 75% to leave stack headroom.

Common Arduino Uno Issues and Quick Fixes

Problem Likely Cause Quick Fix
Board not powering Incorrect or insufficient input voltage Verify 7–12V on barrel jack or 5V via USB; check polyfuse continuity.
Upload fails D0 or D1 held high/low by external circuit Disconnect wires from D0/D1 during upload; reconnect after.
Random resets Unstable power supply or insufficient current Add 100 µF capacitor across VIN and GND; use adequate power adapter.
Sensor noise Missing common ground between Uno and sensor Connect all GND pins; use twisted-pair or shielded cable for analog signals.
Pin damage Sustained overcurrent or short circuit Replace with MOSFET/transistor driver; never exceed 20 mA continuous.

Upload Troubleshooting Detail

If upload fails with "avrdude: stk500_recv(): programmer is not responding," the bootloader isn't receiving the initial handshake. Causes include wrong COM port, D0/D1 interference, or a damaged USB bridge (ATmega16U2). Testing with a loopback (short D0 to D1, open Serial Monitor, type—characters should echo) confirms the USB bridge works.

Conclusion

The Arduino Uno's 5V logic, 20 mA pin budget, and 2 KB SRAM define what you can build without external support circuitry or memory management. Staying within 7–12V input, respecting the 40 mA absolute pin maximum, and tracking SRAM usage prevents the most common hardware and software failures. The Uno remains a practical choice for learning and prototyping when you understand where its electrical and memory limits sit—not because it's the most capable board, but because its constraints are predictable and well-documented.