summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSadeep Madurange <sadeep@asciimx.com>2025-12-27 12:39:08 +0800
committerSadeep Madurange <sadeep@asciimx.com>2025-12-27 12:40:52 +0800
commit196cf07dff3e16f6c44bb2a6cca10c0af3652fe9 (patch)
treebb299a248029f496a0b4d6f9b14f5a427d90e649
parentc82f81bc913fc6ed948e3289d7adce839a539a5f (diff)
downloadwww-196cf07dff3e16f6c44bb2a6cca10c0af3652fe9.tar.gz
ATmega328P 3.3V post.
-rw-r--r--_log/arduino-uno.md73
-rw-r--r--_site/feed.xml2
-rw-r--r--_site/index.html2
-rw-r--r--_site/log/arduino-uno/index.html95
-rw-r--r--_site/log/index.html2
-rw-r--r--_site/posts.xml2
6 files changed, 61 insertions, 115 deletions
diff --git a/_log/arduino-uno.md b/_log/arduino-uno.md
index dfdbdce..8521725 100644
--- a/_log/arduino-uno.md
+++ b/_log/arduino-uno.md
@@ -1,17 +1,11 @@
---
-title: How to configure ATmega328P microcontrollers to run at 3.3V and 5V
+title: ATmega328P at 3.3V and 5V
date: 2025-06-10
layout: post
---
-This is a quick reference for wiring up ATmega328P ICs to run at 5V and 3.3V.
-While the 5V configuration is common, the 3.3V configuration can be useful in
-low-power applications and when interfacing with parts that themselves run at
-3.3V. In this guide, the 5V setup is configured with a 16MHz crystal
-oscillator, while the 3.3V configuration makes use of an 8MHz crystal
-oscillator.
-
-The steps that follow refer to the following pinout.
+Quick reference for wiring ATmega328P ICs at 5V and 3.3V. 5V uses 16MHz
+crystal, 3.3V uses 8MHz.
<table style="border: none; width: 100%;">
<tr style="border: none;">
@@ -26,57 +20,36 @@ The steps that follow refer to the following pinout.
</tr>
</table>
-## 5V-16MHz configuration
+## 5V-16MHz
-Powering ATmega328P microcontrollers with 5V is the most common setup. This is
-also how Arduino Uno boards are wired.
+Standard setup. How Arduino Uno boards are wired.
-In this configuration, the microcontroller's pin 1 is connected to 5V via a
-10kΩ resistor. Pins 9 and 10 are connected to a 16MHz crystal oscillator via
-two 22pF capacitors connected to ground. The microcontroller is powered by
-connecting pins 7, 20, and 21 to a 5V DC power supply. Lastly, pins 8 and 22
-are connected to ground. In addition to the these connections, which are
-required, it's a good idea to add 0.1μF decoupling capacitors between pins 7,
-20, and 21 and ground.
+Connections: Pin 1 → 5V via 10kΩ resistor. Pins 9/10 → 16MHz crystal via 22pF
+capacitors to ground. Pins 7/20/21 → 5V supply. Pins 8/22 → ground. Add 0.1μF
+decoupling caps between pins 7/20/21 and ground.
-[Here's](Makefile) a sample Makefile for compiling C programs for ATmega328P
-microcontrollers using avr-gcc/avrdude toolchain.
+Sample Makefile: [Makefile](Makefile)
-## 3.3V-8MHz configuration
+## 3.3V-8MHz
-Electrical connections for running an ATmega328P at 3.3V are identical to that
-of the 5V circuit. The only differences are that all the 5V connections are
-replaced with a 3.3V power source and a 8MHz crystal oscillator takes the place
-of the 16MHz crystal.
+Electrical connections identical to 5V circuit. Replace 5V with 3.3V supply,
+16MHz crystal with 8MHz.
-However, standard ATmega328P chips are preconfigured to run at 5V. To run one
-at 3.3V, we must first modify its fuses that control characteristics like the
-BOD level. If a bootloader that expects a 16MHz clock (e.g., Arduino
-bootloader) is pre-installed on the ATmega328P, it must be swapped with one
-that accepts an 8MHz clock. To accomplish that, we need an in-system programmer
-(ISP).
+Problem: ATmega328P ships configured for 5V. Must modify fuses (BOD level,
+etc.) and replace bootloader. Standard Arduino bootloader expects 16MHz—needs
+8MHz version.
-Fortunately, we can turn an ordinary Arduino Uno board into an ISP by uploading
-the 'ArduinoISP' sketch found in the Arduino IDE. The ISP communicates with the
-microcontroller using a Serial Peripheral Interface (SPI). So, connect the SPI
-port of the ATmega328P to that of the Arduino Uno, and the Uno's SS pin
-to the ATmega328P's RESET pin.
+Solution: Use Arduino Uno as ISP. Upload 'ArduinoISP' sketch from Arduino IDE.
+Connect SPI pins (ATmega328P ↔ Uno), Uno's SS pin → ATmega328P RESET pin. Power
+ATmega328P from Uno's 5V pin during programming.
-Power up the the ATmega328P by connecting its V<sub>CC</sub> to a 5V supply (we
-can use Arduino Uno's 5V pin). From the Arduino IDE, select 'ATmega328P (3.3V,
-8MHz)' for processor from the tools menu. Also from the tools menu, select
-'Arduino as ISP' as programmer. Finally, upload the new bootloader by selecting
-'Burn Bootloader' from the tools menu.
+Arduino IDE: Select 'ATmega328P (3.3V, 8MHz)' processor, 'Arduino as ISP'
+programmer. Burn bootloader via tools menu.
-The ATmega328P is now ready to run at 8MHz with a 3.3V power supply. You can
-upload programs to the ATmega328P as you normally would using avrdude.
-[Here's](3v3.Makefile) a sample Makefile with adjusted parameters (e.g., baud
-rate) for an 8MHz clock.
+Sample Makefile (8MHz): [Makefile.3v3](3v3.Makefile)
## Remarks
-In both configurations, if you intend to use the ATmega328P's analog-to-digital
-converter with the internal 1.1V or AV<sub>cc</sub> voltage as reference, do
-not connect AREF (pin 21) to V<sub>cc</sub>. Refer to section 23.5.2 in the
-datasheet for more information.
+Don't connect AREF (pin 21) to V<sub>cc</sub> if using ADC with internal 1.1V
+or AV<sub>cc</sub> reference. See datasheet section 23.5.2.
diff --git a/_site/feed.xml b/_site/feed.xml
index 1447d49..2f1bab9 100644
--- a/_site/feed.xml
+++ b/_site/feed.xml
@@ -1 +1 @@
-<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="4.4.1">Jekyll</generator><link href="/feed.xml" rel="self" type="application/atom+xml" /><link href="/" rel="alternate" type="text/html" /><updated>2025-12-27T12:19:17+08:00</updated><id>/feed.xml</id><title type="html">ASCIIMX | Log</title><author><name>W. D. Sadeep Madurange</name></author><entry><title type="html">Matrix Rain: 2025 refactor</title><link href="/log/matrix-digital-rain/" rel="alternate" type="text/html" title="Matrix Rain: 2025 refactor" /><published>2025-12-21T00:00:00+08:00</published><updated>2025-12-21T00:00:00+08:00</updated><id>/log/matrix-digital-rain</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[The 2022 version worked but had some loose ends. Unicode support was inflexible–couldn’t mix ASCII with Katakana; Phosphor decay was stored in a separate array when it should’ve been packed with RGB; Code was harder to read than it needed to be.]]></summary></entry><entry><title type="html">Fingerprint door lock (LP)</title><link href="/log/fpm-door-lock-lp/" rel="alternate" type="text/html" title="Fingerprint door lock (LP)" /><published>2025-08-18T00:00:00+08:00</published><updated>2025-08-18T00:00:00+08:00</updated><id>/log/fpm-door-lock-lp</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Second iteration of the RF door lock. Old version worked but drew too much quiescent current. Sensor and servo pulled 13.8mA and 4.6mA idle. Linear regulators were a disaster. Battery didn’t last 24 hours.]]></summary></entry><entry><title type="html">High-side MOSFET switching</title><link href="/log/mosfet-switches/" rel="alternate" type="text/html" title="High-side MOSFET switching" /><published>2025-06-22T00:00:00+08:00</published><updated>2025-06-22T00:00:00+08:00</updated><id>/log/mosfet-switches</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Needed low-power switching for the fingerprint door lock. Servo and FPM draw high quiescent current–had to cut power electronically during sleep. MOSFETs can do this.]]></summary></entry><entry><title type="html">How to configure ATmega328P microcontrollers to run at 3.3V and 5V</title><link href="/log/arduino-uno/" rel="alternate" type="text/html" title="How to configure ATmega328P microcontrollers to run at 3.3V and 5V" /><published>2025-06-10T00:00:00+08:00</published><updated>2025-06-10T00:00:00+08:00</updated><id>/log/arduino-uno</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[This is a quick reference for wiring up ATmega328P ICs to run at 5V and 3.3V. While the 5V configuration is common, the 3.3V configuration can be useful in low-power applications and when interfacing with parts that themselves run at 3.3V. In this guide, the 5V setup is configured with a 16MHz crystal oscillator, while the 3.3V configuration makes use of an 8MHz crystal oscillator.]]></summary></entry><entry><title type="html">Fingerprint door lock (RF)</title><link href="/log/fpm-door-lock-rf/" rel="alternate" type="text/html" title="Fingerprint door lock (RF)" /><published>2025-06-05T00:00:00+08:00</published><updated>2025-06-05T00:00:00+08:00</updated><id>/log/fpm-door-lock-rf</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Wanted to unlock door with fingerprint, wirelessly to avoid drilling.]]></summary></entry><entry><title type="html">Bumblebee: browser automation</title><link href="/log/bumblebee/" rel="alternate" type="text/html" title="Bumblebee: browser automation" /><published>2025-04-02T00:00:00+08:00</published><updated>2025-04-02T00:00:00+08:00</updated><id>/log/bumblebee</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Bumblebee is a tool I built for one of my employers to automate the generation of web scraping scripts.]]></summary></entry><entry><title type="html">How to set up ATSAM3X8E microcontrollers for bare-metal programming in C</title><link href="/log/arduino-due/" rel="alternate" type="text/html" title="How to set up ATSAM3X8E microcontrollers for bare-metal programming in C" /><published>2024-09-16T00:00:00+08:00</published><updated>2024-09-16T00:00:00+08:00</updated><id>/log/arduino-due</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[This article is a step-by-step guide for programming bare-metal ATSAM3X8E chips found on Arduino Due boards. It also includes notes on the chip’s memory layout relevant for writing linker scripts. The steps described in this article were tested on an OpenBSD workstation.]]></summary></entry><entry><title type="html">Etlas: e-paper dashboard</title><link href="/log/etlas/" rel="alternate" type="text/html" title="Etlas: e-paper dashboard" /><published>2024-09-05T00:00:00+08:00</published><updated>2024-09-05T00:00:00+08:00</updated><id>/log/etlas</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Etlas is a news, stock market, and weather tracker powered by an ESP32 NodeMCU D1, featuring a 7.5-inch Waveshare e-paper display and a DHT22 sensor module.]]></summary></entry><entry><title type="html">Experimental e-reader</title><link href="/log/e-reader/" rel="alternate" type="text/html" title="Experimental e-reader" /><published>2023-10-24T00:00:00+08:00</published><updated>2023-10-24T00:00:00+08:00</updated><id>/log/e-reader</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[This project features an experimental e-reader powered by an ESP-WROOM-32 development board and a 7.5-inch Waveshare e-paper display built with the intention of learning about e-paper displays.]]></summary></entry><entry><title type="html">Neo4J A* search</title><link href="/log/neo4j-a-star-search/" rel="alternate" type="text/html" title="Neo4J A* search" /><published>2018-03-06T00:00:00+08:00</published><updated>2018-03-06T00:00:00+08:00</updated><id>/log/neo4j-a-star-search</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Back in 2018, we used Neo4J graph database to track the movement of marine vessels. We were interested in the shortest path a ship could take through a network of about 13,000 route points. Graph theoretic algorithms provide optimal solutions to such problems, and the set of route points lends itself well to graph-based modelling.]]></summary></entry></feed> \ No newline at end of file
+<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="4.4.1">Jekyll</generator><link href="/feed.xml" rel="self" type="application/atom+xml" /><link href="/" rel="alternate" type="text/html" /><updated>2025-12-27T12:40:20+08:00</updated><id>/feed.xml</id><title type="html">ASCIIMX | Log</title><author><name>W. D. Sadeep Madurange</name></author><entry><title type="html">Matrix Rain: 2025 refactor</title><link href="/log/matrix-digital-rain/" rel="alternate" type="text/html" title="Matrix Rain: 2025 refactor" /><published>2025-12-21T00:00:00+08:00</published><updated>2025-12-21T00:00:00+08:00</updated><id>/log/matrix-digital-rain</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[The 2022 version worked but had some loose ends. Unicode support was inflexible–couldn’t mix ASCII with Katakana; Phosphor decay was stored in a separate array when it should’ve been packed with RGB; Code was harder to read than it needed to be.]]></summary></entry><entry><title type="html">Fingerprint door lock (LP)</title><link href="/log/fpm-door-lock-lp/" rel="alternate" type="text/html" title="Fingerprint door lock (LP)" /><published>2025-08-18T00:00:00+08:00</published><updated>2025-08-18T00:00:00+08:00</updated><id>/log/fpm-door-lock-lp</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Second iteration of the RF door lock. Old version worked but drew too much quiescent current. Sensor and servo pulled 13.8mA and 4.6mA idle. Linear regulators were a disaster. Battery didn’t last 24 hours.]]></summary></entry><entry><title type="html">High-side MOSFET switching</title><link href="/log/mosfet-switches/" rel="alternate" type="text/html" title="High-side MOSFET switching" /><published>2025-06-22T00:00:00+08:00</published><updated>2025-06-22T00:00:00+08:00</updated><id>/log/mosfet-switches</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Needed low-power switching for the fingerprint door lock. Servo and FPM draw high quiescent current–had to cut power electronically during sleep. MOSFETs can do this.]]></summary></entry><entry><title type="html">ATmega328P at 3.3V and 5V</title><link href="/log/arduino-uno/" rel="alternate" type="text/html" title="ATmega328P at 3.3V and 5V" /><published>2025-06-10T00:00:00+08:00</published><updated>2025-06-10T00:00:00+08:00</updated><id>/log/arduino-uno</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Quick reference for wiring ATmega328P ICs at 5V and 3.3V. 5V uses 16MHz crystal, 3.3V uses 8MHz.]]></summary></entry><entry><title type="html">Fingerprint door lock (RF)</title><link href="/log/fpm-door-lock-rf/" rel="alternate" type="text/html" title="Fingerprint door lock (RF)" /><published>2025-06-05T00:00:00+08:00</published><updated>2025-06-05T00:00:00+08:00</updated><id>/log/fpm-door-lock-rf</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Wanted to unlock door with fingerprint, wirelessly to avoid drilling.]]></summary></entry><entry><title type="html">Bumblebee: browser automation</title><link href="/log/bumblebee/" rel="alternate" type="text/html" title="Bumblebee: browser automation" /><published>2025-04-02T00:00:00+08:00</published><updated>2025-04-02T00:00:00+08:00</updated><id>/log/bumblebee</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Bumblebee is a tool I built for one of my employers to automate the generation of web scraping scripts.]]></summary></entry><entry><title type="html">How to set up ATSAM3X8E microcontrollers for bare-metal programming in C</title><link href="/log/arduino-due/" rel="alternate" type="text/html" title="How to set up ATSAM3X8E microcontrollers for bare-metal programming in C" /><published>2024-09-16T00:00:00+08:00</published><updated>2024-09-16T00:00:00+08:00</updated><id>/log/arduino-due</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[This article is a step-by-step guide for programming bare-metal ATSAM3X8E chips found on Arduino Due boards. It also includes notes on the chip’s memory layout relevant for writing linker scripts. The steps described in this article were tested on an OpenBSD workstation.]]></summary></entry><entry><title type="html">Etlas: e-paper dashboard</title><link href="/log/etlas/" rel="alternate" type="text/html" title="Etlas: e-paper dashboard" /><published>2024-09-05T00:00:00+08:00</published><updated>2024-09-05T00:00:00+08:00</updated><id>/log/etlas</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Etlas is a news, stock market, and weather tracker powered by an ESP32 NodeMCU D1, featuring a 7.5-inch Waveshare e-paper display and a DHT22 sensor module.]]></summary></entry><entry><title type="html">Experimental e-reader</title><link href="/log/e-reader/" rel="alternate" type="text/html" title="Experimental e-reader" /><published>2023-10-24T00:00:00+08:00</published><updated>2023-10-24T00:00:00+08:00</updated><id>/log/e-reader</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[This project features an experimental e-reader powered by an ESP-WROOM-32 development board and a 7.5-inch Waveshare e-paper display built with the intention of learning about e-paper displays.]]></summary></entry><entry><title type="html">Neo4J A* search</title><link href="/log/neo4j-a-star-search/" rel="alternate" type="text/html" title="Neo4J A* search" /><published>2018-03-06T00:00:00+08:00</published><updated>2018-03-06T00:00:00+08:00</updated><id>/log/neo4j-a-star-search</id><author><name>W. D. Sadeep Madurange</name></author><summary type="html"><![CDATA[Back in 2018, we used Neo4J graph database to track the movement of marine vessels. We were interested in the shortest path a ship could take through a network of about 13,000 route points. Graph theoretic algorithms provide optimal solutions to such problems, and the set of route points lends itself well to graph-based modelling.]]></summary></entry></feed> \ No newline at end of file
diff --git a/_site/index.html b/_site/index.html
index 682339b..0bc5788 100644
--- a/_site/index.html
+++ b/_site/index.html
@@ -95,7 +95,7 @@
<tr>
<td class="posts-td posts-td-link">
- <a href="/log/arduino-uno/" class="link-decor-none">How to configure ATmega328P microcontrollers to run at 3.3V and 5V</a>
+ <a href="/log/arduino-uno/" class="link-decor-none">ATmega328P at 3.3V and 5V</a>
</td>
<td class="posts-td posts-td-time">
<span class="post-meta">
diff --git a/_site/log/arduino-uno/index.html b/_site/log/arduino-uno/index.html
index 45f6456..95681a4 100644
--- a/_site/log/arduino-uno/index.html
+++ b/_site/log/arduino-uno/index.html
@@ -2,12 +2,12 @@
<html>
<head>
<meta charset="utf-8">
- <title>How to configure ATmega328P microcontrollers to run at 3.3V and 5V</title>
+ <title>ATmega328P at 3.3V and 5V</title>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
- <title>How to configure ATmega328P microcontrollers to run at 3.3V and 5V</title>
+ <title>ATmega328P at 3.3V and 5V</title>
<link rel="stylesheet" href="/assets/css/main.css">
<link rel="stylesheet" href="/assets/css/skeleton.css">
</head>
@@ -41,17 +41,11 @@
<main>
<div class="container">
<div class="container-2">
- <h2 class="center" id="title">HOW TO CONFIGURE ATMEGA328P MICROCONTROLLERS TO RUN AT 3.3V AND 5V</h2>
+ <h2 class="center" id="title">ATMEGA328P AT 3.3V AND 5V</h2>
<h6 class="center">10 JUNE 2025</h5>
<br>
- <div class="twocol justify"><p>This is a quick reference for wiring up ATmega328P ICs to run at 5V and 3.3V.
-While the 5V configuration is common, the 3.3V configuration can be useful in
-low-power applications and when interfacing with parts that themselves run at
-3.3V. In this guide, the 5V setup is configured with a 16MHz crystal
-oscillator, while the 3.3V configuration makes use of an 8MHz crystal
-oscillator.</p>
-
-<p>The steps that follow refer to the following pinout.</p>
+ <div class="twocol justify"><p>Quick reference for wiring ATmega328P ICs at 5V and 3.3V. 5V uses 16MHz
+crystal, 3.3V uses 8MHz.</p>
<table style="border: none; width: 100%;">
<tr style="border: none;">
@@ -66,59 +60,38 @@ oscillator.</p>
</tr>
</table>
-<h2 id="5v-16mhz-configuration">5V-16MHz configuration</h2>
-
-<p>Powering ATmega328P microcontrollers with 5V is the most common setup. This is
-also how Arduino Uno boards are wired.</p>
-
-<p>In this configuration, the microcontroller’s pin 1 is connected to 5V via a
-10kΩ resistor. Pins 9 and 10 are connected to a 16MHz crystal oscillator via
-two 22pF capacitors connected to ground. The microcontroller is powered by
-connecting pins 7, 20, and 21 to a 5V DC power supply. Lastly, pins 8 and 22
-are connected to ground. In addition to the these connections, which are
-required, it’s a good idea to add 0.1μF decoupling capacitors between pins 7,
-20, and 21 and ground.</p>
-
-<p><a href="Makefile">Here’s</a> a sample Makefile for compiling C programs for ATmega328P
-microcontrollers using avr-gcc/avrdude toolchain.</p>
-
-<h2 id="33v-8mhz-configuration">3.3V-8MHz configuration</h2>
-
-<p>Electrical connections for running an ATmega328P at 3.3V are identical to that
-of the 5V circuit. The only differences are that all the 5V connections are
-replaced with a 3.3V power source and a 8MHz crystal oscillator takes the place
-of the 16MHz crystal.</p>
-
-<p>However, standard ATmega328P chips are preconfigured to run at 5V. To run one
-at 3.3V, we must first modify its fuses that control characteristics like the
-BOD level. If a bootloader that expects a 16MHz clock (e.g., Arduino
-bootloader) is pre-installed on the ATmega328P, it must be swapped with one
-that accepts an 8MHz clock. To accomplish that, we need an in-system programmer
-(ISP).</p>
-
-<p>Fortunately, we can turn an ordinary Arduino Uno board into an ISP by uploading
-the ‘ArduinoISP’ sketch found in the Arduino IDE. The ISP communicates with the
-microcontroller using a Serial Peripheral Interface (SPI). So, connect the SPI
-port of the ATmega328P to that of the Arduino Uno, and the Uno’s SS pin
-to the ATmega328P’s RESET pin.</p>
-
-<p>Power up the the ATmega328P by connecting its V<sub>CC</sub> to a 5V supply (we
-can use Arduino Uno’s 5V pin). From the Arduino IDE, select ‘ATmega328P (3.3V,
-8MHz)’ for processor from the tools menu. Also from the tools menu, select
-‘Arduino as ISP’ as programmer. Finally, upload the new bootloader by selecting
-‘Burn Bootloader’ from the tools menu.</p>
-
-<p>The ATmega328P is now ready to run at 8MHz with a 3.3V power supply. You can
-upload programs to the ATmega328P as you normally would using avrdude.
-<a href="3v3.Makefile">Here’s</a> a sample Makefile with adjusted parameters (e.g., baud
-rate) for an 8MHz clock.</p>
+<h2 id="5v-16mhz">5V-16MHz</h2>
+
+<p>Standard setup. How Arduino Uno boards are wired.</p>
+
+<p>Connections: Pin 1 → 5V via 10kΩ resistor. Pins 9/10 → 16MHz crystal via 22pF
+capacitors to ground. Pins 7/20/21 → 5V supply. Pins 8/22 → ground. Add 0.1μF
+decoupling caps between pins 7/20/21 and ground.</p>
+
+<p>Sample Makefile: <a href="Makefile">Makefile</a></p>
+
+<h2 id="33v-8mhz">3.3V-8MHz</h2>
+
+<p>Electrical connections identical to 5V circuit. Replace 5V with 3.3V supply,
+16MHz crystal with 8MHz.</p>
+
+<p>Problem: ATmega328P ships configured for 5V. Must modify fuses (BOD level,
+etc.) and replace bootloader. Standard Arduino bootloader expects 16MHz—needs
+8MHz version.</p>
+
+<p>Solution: Use Arduino Uno as ISP. Upload ‘ArduinoISP’ sketch from Arduino IDE.
+Connect SPI pins (ATmega328P ↔ Uno), Uno’s SS pin → ATmega328P RESET pin. Power
+ATmega328P from Uno’s 5V pin during programming.</p>
+
+<p>Arduino IDE: Select ‘ATmega328P (3.3V, 8MHz)’ processor, ‘Arduino as ISP’
+programmer. Burn bootloader via tools menu.</p>
+
+<p>Sample Makefile (8MHz): <a href="3v3.Makefile">Makefile.3v3</a></p>
<h2 id="remarks">Remarks</h2>
-<p>In both configurations, if you intend to use the ATmega328P’s analog-to-digital
-converter with the internal 1.1V or AV<sub>cc</sub> voltage as reference, do
-not connect AREF (pin 21) to V<sub>cc</sub>. Refer to section 23.5.2 in the
-datasheet for more information.</p>
+<p>Don’t connect AREF (pin 21) to V<sub>cc</sub> if using ADC with internal 1.1V
+or AV<sub>cc</sub> reference. See datasheet section 23.5.2.</p>
</div>
<p class="post-author right">by W. D. Sadeep Madurange</p>
diff --git a/_site/log/index.html b/_site/log/index.html
index 659609d..0fcfc51 100644
--- a/_site/log/index.html
+++ b/_site/log/index.html
@@ -85,7 +85,7 @@
<tr>
<td class="posts-td posts-td-link">
- <a href="/log/arduino-uno/" class="link-decor-none">How to configure ATmega328P microcontrollers to run at 3.3V and 5V</a>
+ <a href="/log/arduino-uno/" class="link-decor-none">ATmega328P at 3.3V and 5V</a>
</td>
<td class="posts-td posts-td-time">
<span class="post-meta">
diff --git a/_site/posts.xml b/_site/posts.xml
index 05ccd8a..53b0ad5 100644
--- a/_site/posts.xml
+++ b/_site/posts.xml
@@ -1 +1 @@
-<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="4.4.1">Jekyll</generator><link href="/posts.xml" rel="self" type="application/atom+xml" /><link href="/" rel="alternate" type="text/html" /><updated>2025-12-27T12:19:17+08:00</updated><id>/posts.xml</id><title type="html">ASCIIMX</title><author><name>W. D. Sadeep Madurange</name></author></feed> \ No newline at end of file
+<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="4.4.1">Jekyll</generator><link href="/posts.xml" rel="self" type="application/atom+xml" /><link href="/" rel="alternate" type="text/html" /><updated>2025-12-27T12:40:20+08:00</updated><id>/posts.xml</id><title type="html">ASCIIMX</title><author><name>W. D. Sadeep Madurange</name></author></feed> \ No newline at end of file