From 5c9f61600f3a81de6d1750b07dd609e19af4212f Mon Sep 17 00:00:00 2001
From: Sadeep Madurange
$ openocd -f openocd-due.cfg
Open a telnet session and check that the GPNVM1 bit is set. Otherwise -set it to 1:
- +$ telnet localhost 4444
> halt
> at91sam3 gpnvm show
diff --git a/_site/archive/arduino-uno/index.html b/_site/archive/arduino-uno/index.html
index 0c233c5..7509267 100644
--- a/_site/archive/arduino-uno/index.html
+++ b/_site/archive/arduino-uno/index.html
@@ -43,10 +43,10 @@
PROGRAMMING ATMEGA328P CHIPS
10 APRIL 2025
- This post is a step-by-step guide for wiring up ATmega328P ICs to run at 5 V
-with a 16 MHz crystal and 3.3 V with an 8 MHz crystal. While the 5 V
-configuration is common, the 3.3 V configuration can be advantageous in
-low-power applications and when interfacing with parts that run at 3.3 V.
+ This post is a step-by-step guide for wiring up ATmega328P ICs to run at 5V
+with a 16MHz crystal and 3.3V with an 8MHz crystal. While the 5V
+configuration is common, the 3.3V configuration can be advantageous in
+low-power applications and when interfacing with parts that run at 3.3V.
5V-16MHz configuration
@@ -66,46 +66,46 @@ low-power applications and when interfacing with parts that run at 3.3 V.
- - Connect pin 1 to 5 V via a 10 kΩ resistor.
- - Connect a 16 MHz crystal oscillator across pins 9 and 10.
- - Connect each pin of the crystal to ground via 22 pF capacitors.
- - Connect pins 7, 20, and 21 to 5 V.
+ - Connect pin 1 to 5V via a 10kΩ resistor.
+ - Connect a 16MHz crystal oscillator across pins 9 and 10.
+ - Connect each pin of the crystal to ground via 22pF capacitors.
+ - Connect pins 7, 20, and 21 to 5V.
- Connect pins 8 and 22 to ground.
-In addition to the connections described above, it’s a good idea to add 0.1 μF
+
In addition to the connections described above, it’s a good idea to add 0.1μF
decoupling capacitors between pins 7, 20, and 21 and ground.
Here’s a sample Makefile for avr-gcc and avrdude.
3.3V-8MHz configuration
The following steps use Arduino Uno as an ISP and Arduino utilities to program
-ATmega328P’s bootloader and the fuses (e.g., BOD level) for a 3.3 V supply.
+ATmega328P’s bootloader and the fuses (e.g., BOD level) for a 3.3V supply.
- Upload the ‘ArduinoISP’ sketch to the Uno.
- - Wire up the ATmega328P as described in the previous section. Replace the 5 V
-supply with a 3.3 V supply and use an 8 MHz crystal instead of the 16 MHz
+
- Wire up the ATmega328P as described in the previous section. Replace the 5V
+supply with a 3.3V supply and use an 8MHz crystal instead of the 16MHz
crystal.
- Connect the SPI ports (SCK, MISO, and MOSI) of the two MCUs.
- Connect Uno’s SS pin to the IC’s pin 1 (RESET).
- - The IC can be powered by the Arduino Uno’s 5 V pin.
+ - The IC can be powered by the Arduino Uno’s 5V pin.
- Burn the bootloader to the ATmega328P:
- - Select ‘ATmega328P (3.3 V, 8 MHz)’ from Tools > Processor.
+ - Select ‘ATmega328P (3.3V, 8MHz)’ from Tools > Processor.
- Select ‘Arduino as ISP’ from Tools > Programmer.
- Select Tools > Burn Bootloader.
-The ATmega328P is now ready to run at 8 MHz with a 3.3 V power supply. You can
+
The ATmega328P is now ready to run at 8MHz with a 3.3V power supply. You can
upload programs to the ATmega328P as you usually would using avrdude.
Here’s a sample Makefile with adjusted parameters (e.g., baud
-rate) for an 8 MHz clock.
+rate) for an 8MHz clock.
In both configurations, if you intend to use the ATmega328P’s analog-to-digital
-converter with the internal 1.1 V or AVcc voltage as reference, do
+converter with the internal 1.1V or AVcc voltage as reference, do
not connect AREF (pin 21) to Vcc. Refer to section 23.5.2 ADC
Voltage Reference in the datasheet for more information.
diff --git a/_site/feed.xml b/_site/feed.xml
index d2dcedc..3548f7c 100644
--- a/_site/feed.xml
+++ b/_site/feed.xml
@@ -1 +1 @@
-Jekyll 2025-11-02T11:27:10+08:00 http://localhost:4000/feed.xml ASCIIMX | Archive Wickramage Don Sadeep Madurange Neo4J A* search 2025-09-14T00:00:00+08:00 2025-09-14T00:00:00+08:00 http://localhost:4000/archive/neo4j-a-star-search Wickramage Don Sadeep Madurange My first PCB 2025-07-14T00:00:00+08:00 2025-07-14T00:00:00+08:00 http://localhost:4000/archive/my-first-pcb Wickramage Don Sadeep Madurange MOSFETs 2025-06-22T00:00:00+08:00 2025-06-22T00:00:00+08:00 http://localhost:4000/archive/mosfet-switches Wickramage Don Sadeep Madurange Awesome books 2025-04-20T00:00:00+08:00 2025-04-20T00:00:00+08:00 http://localhost:4000/archive/awesome-books Wickramage Don Sadeep Madurange Programming ATmega328P chips 2025-04-10T00:00:00+08:00 2025-04-10T00:00:00+08:00 http://localhost:4000/archive/arduino-uno Wickramage Don Sadeep Madurange Bare-metal ARM Cortex M3 chips 2024-10-05T00:00:00+08:00 2024-10-05T00:00:00+08:00 http://localhost:4000/archive/arduino-due Wickramage Don Sadeep Madurange
\ No newline at end of file
+Jekyll 2025-11-02T11:45:12+08:00 /feed.xml ASCIIMX | Archive Wickramage Don Sadeep Madurange Neo4J A* search 2025-09-14T00:00:00+08:00 2025-09-14T00:00:00+08:00 /archive/neo4j-a-star-search Wickramage Don Sadeep Madurange My first PCB 2025-07-14T00:00:00+08:00 2025-07-14T00:00:00+08:00 /archive/my-first-pcb Wickramage Don Sadeep Madurange MOSFETs 2025-06-22T00:00:00+08:00 2025-06-22T00:00:00+08:00 /archive/mosfet-switches Wickramage Don Sadeep Madurange Awesome books 2025-04-20T00:00:00+08:00 2025-04-20T00:00:00+08:00 /archive/awesome-books Wickramage Don Sadeep Madurange Programming ATmega328P chips 2025-04-10T00:00:00+08:00 2025-04-10T00:00:00+08:00 /archive/arduino-uno Wickramage Don Sadeep Madurange Bare-metal ARM Cortex M3 chips 2024-10-05T00:00:00+08:00 2024-10-05T00:00:00+08:00 /archive/arduino-due Wickramage Don Sadeep Madurange
\ No newline at end of file
diff --git a/_site/posts.xml b/_site/posts.xml
index feb444a..1ecb22e 100644
--- a/_site/posts.xml
+++ b/_site/posts.xml
@@ -1 +1 @@
-Jekyll 2025-11-02T11:27:10+08:00 http://localhost:4000/posts.xml ASCIIMX Wickramage Don Sadeep Madurange
\ No newline at end of file
+Jekyll 2025-11-02T11:45:12+08:00 /posts.xml ASCIIMX Wickramage Don Sadeep Madurange
\ No newline at end of file
--
cgit v1.2.3