ATmega328 / ATmega328P / ATmega168 / ATmega8 connection guide
ATmega328 / ATmega328P / ATmega168 / ATmega8 PDIP-28 wiring guide with power, signal assignments, and bench checks.
16 KiB flash · 1 KiB SRAM · 512 B EEPROM. Choose the marked order code for voltage, clock, and temperature.
Power and reset
RequiredUse a current-limited supply at a voltage permitted by the order code and system clock. Tie the listed supply pins to that rail. Fit one 100 nF ceramic capacitor close to each supply-and-ground pair. Use a 10 kΩ reset pull-up for this bench circuit.
- Target rail
- Ground
- Reset
Bench checks
- With power off, check for a short across the supply. Power on and measure voltage at every supply pin and at reset.
- Check the clock source configured by CKSEL. If a used part expects an external clock, provide it before attempting serial programming.
AN2519 §§2–3 and 2545W · Pin descriptions and clock source
Connection scenarios
Connect USART0 to a logic-level serial adapter
Use a UART adapter that supports the target’s I/O voltage. Cross the transmit and receive lines. Leave adapter power disconnected when using the bench supply.
Bench checks
- Configure both sides for the same baud rate, frame length, parity and stop bits. Base the MCU baud divider on the actual clock after prescaling.
- Send a known byte such as 0x55 from the MCU and check that it arrives unchanged. If it fails, inspect TX idle voltage and bit period before attaching the adapter TX line.
2545W · USART0 asynchronous operation and pin assignments
PDIP-28 wiring map
2 · PD0
General-purpose digital I/O. Alternate assignments: RXD (USART0), PCINT16 (EXINT).
After reset · GPIO driver is high impedance during reset. Clock, debug, and alternate-function use depend on fuse and peripheral configuration.
Models and documents
Each package lists the documented order codes and variants covered by this map. Select the marked model to see its peripheral assignments and memory. Check the exact order code and datasheet revision before laying out a PCB.
- ATmega328
- 32 KiB flash · 2 KiB SRAM · 1 KiB EEPROM. Choose the marked order code for voltage, clock, and temperature.
- ATmega328-PU
- 32 KiB flash · 2 KiB SRAM · 1 KiB EEPROM · 1.8–5.5 V · 20 MHz maximum · -40 to +85 °C
- ATmega328P
- 32 KiB flash · 2 KiB SRAM · 1 KiB EEPROM. Choose the marked order code for voltage, clock, and temperature.
- ATmega328P-PU
- 32 KiB flash · 2 KiB SRAM · 1 KiB EEPROM · 1.8–5.5 V · 20 MHz maximum · -40 to +85 °C
- ATmega328P-PN
- 32 KiB flash · 2 KiB SRAM · 1 KiB EEPROM · 1.8–5.5 V · 20 MHz maximum · -40 to +105 °C
- ATmega168
- 16 KiB flash · 1 KiB SRAM · 512 B EEPROM. Choose the marked order code for voltage, clock, and temperature.
- ATmega168V-10PU
- 16 KiB flash · 1 KiB SRAM · 512 B EEPROM · 1.8–5.5 V · 10 MHz maximum · -40 to +85 °C
- ATmega168-20PU
- 16 KiB flash · 1 KiB SRAM · 512 B EEPROM · 2.7–5.5 V · 20 MHz maximum · -40 to +85 °C
- ATmega8
- 8 KiB flash · 1 KiB SRAM · 512 B EEPROM. Choose the marked order code for voltage, clock, and temperature.
- ATmega8L-8PU
- 8 KiB flash · 1 KiB SRAM · 512 B EEPROM · 2.7–5.5 V · 8 MHz maximum · -40 to +85 °C
- ATmega8-16PU
- 8 KiB flash · 1 KiB SRAM · 512 B EEPROM · 4.5–5.5 V · 16 MHz maximum · -40 to +85 °C
- ATmega8L-8PN
- 8 KiB flash · 1 KiB SRAM · 512 B EEPROM · 2.7–5.5 V · 8 MHz maximum · -40 to +105 °C
- ATmega8-16PN
- 8 KiB flash · 1 KiB SRAM · 512 B EEPROM · 4.5–5.5 V · 16 MHz maximum · -40 to +105 °C
- ATmega328/ATmega328P data sheet· DS40002061B · Pin configuration, electrical characteristics, ordering table and serial programming.
- ATmega168 data sheet· 2545W · Pin configuration, electrical characteristics, ordering table and serial programming.
- ATmega8 data sheet· 2486AA · Pin configuration, electrical characteristics, ordering table and serial programming.
- ATmega_DFP Device Family Pack· Machine-readable device definition: package contacts, peripheral routes, and memory sizes.
- AVR Microcontroller Hardware Design Considerations· Power supply, reset network, and programmer connection guidance.
- ATmega328 documentation and errata· Check current manufacturer documentation, ordering status and silicon revision applicability.
- ATmega328P documentation and errata· Check current manufacturer documentation, ordering status and silicon revision applicability.
- ATmega168 documentation and errata· Check current manufacturer documentation, ordering status and silicon revision applicability.
- ATmega8 documentation and errata· Check current manufacturer documentation, ordering status and silicon revision applicability.
- AVR source register· Source identifiers, applicability, retrieval dates, and SHA-256 digests.
