part · Level 7 · Code · board
What an Arduino Nano is
Arduino-compatible board (Nano) — A brain for your box. Now every part you own can be programmed.
What it is
An Arduino Nano is a thumb-sized circuit board with a microcontroller on it — a complete tiny computer on one chip, with no screen or keyboard, built to read and control pins. You write a short program on a laptop, send it over USB, and the board runs it forever, thousands of times a second.
Along each edge are pins that plug straight into your breadboard. Digital pins (D2–D13) can be switched high (5 V) or low (0 V) from code, or read as on/off inputs — a button, a switch. Analog pins (A0–A7) measure a voltage between 0 and 5 V as a number from 0 to 1023 — that is how it reads the voltage divider you built with an LDR or thermistor at Level 3.
Every part you own so far still works. The difference is that the "switch" is now a line of code, and it can make decisions: if the room is dark and it is after 9 pm, blink twice.
How it works
The board runs at 5 V. Power it from USB, or from a battery pack into the VIN pin (7–12 V; a 9 V battery is the classic choice — 3×AA at 4.5 V is too low for VIN but can feed the 5V pin directly, just about).
A digital pin can source or sink at most 40 mA (20 mA is the comfortable figure). The LED rule is unchanged: 5 V − 2.0 V = 3 V across 220 Ω = 13.6 mA, fine. A motor or a buzzer wanting 100 mA is not fine — that is what the transistor from Level 3 is for: the pin drives the base through 1 kΩ, (5 − 0.7) ÷ 1 000 ≈ 4.3 mA, and the transistor carries the load.
Reading a sensor: an LDR and a 10 kΩ resistor as a divider on A0. In bright light the LDR is about 1 kΩ, so the divider gives 5 × 10 ÷ 11 ≈ 4.5 V → analogRead ≈ 930. In the dark it is 100 kΩ+, giving 5 × 10 ÷ 110 ≈ 0.45 V → ≈ 93. Pick a threshold in the middle and your night light now has a brain.
The numbers
| Logic level | 5 V — HIGH = 5 V, LOW = 0 V |
|---|---|
| Pin current | 40 mA absolute max per pin — aim for ≤ 20 mA; 200 mA total for the chip |
| Power in | USB, or 7–12 V on VIN — 9 V battery works; 3×AA cannot feed VIN |
| Digital pins | D2–D13 (6 with PWM) — PWM pins can dim an LED or drive a servo |
| Analog inputs | A0–A7, 0–1023 — 10-bit: about 4.9 mV per step |
Mistakes everyone makes
- Motor straight on a pin. The pin browns out or the chip dies. Fix: a 2N2222 (up to 600 mA) or the L293D driver.
- Reading a floating input. An unconnected pin reads random noise. Fix: a 10 kΩ pull-down resistor, or use the built-in pull-up in code.
- 9 V into the 5V pin. VIN has a regulator; the 5V pin does not. Fix: battery to VIN only.
- Wrong board or port selected in the IDE. The sketch "uploads" to nowhere. Fix: Tools → Board → Nano, and pick the right processor variant.
Questions people ask
- Can an Arduino Nano run on 3 AA batteries?
- Not through VIN, which needs 7–12 V. A 9 V battery on VIN is the usual choice, or 4×AA (6 V) works on VIN with some boards. USB power banks are the easiest.
- How much current can an Arduino pin give?
- 40 mA absolute maximum, 20 mA recommended. That is one LED with a resistor. Anything bigger — motors, buzzers, strings of LEDs — goes through a transistor.
- Do I need to know electronics before learning Arduino?
- You need the loop, Ohm's law and the LED resistor — Levels 1–3 here. Without them the first motor or bare LED you connect damages the board.
Projects that use this part
No project uses it yet — it arrives at Level 7, and the projects for that level are still being written and verified.
verified against: Arduino docs — Nano · Arduino docs — Blink · Arduino docs — AnalogReadSerial