Go Down

Topic: Install Bootloader to use 8Mhz internal resonator - and upload program after? (Read 1 time) previous topic - next topic

tim7

Isn't the bootloader you're using compiled to run at 16MHz?  I only have experience with Optiboot, but it looks like there's an 8MHz version of ATmegaBOOT supplied with IDE v0022.  Try changing these two lines in boards.txt:

atmega328bb.bootloader.high_fuses=0xDA
atmega328bb.bootloader.file=ATmegaBOOT_168_atmega328_pro_8MHz.hex

coofercat

Not sure how I missed that one, but either way, it doesn't seem to work either. Looks like I'm  out of luck :-(

Caliber Mengsk

Anyone figure this out fully?

I ask because I'm working on trying to make a 1inx1in arduino circuit using the 328p (smd), and while I have all 20 output pins, and it could be programmed through ftdi and a breadboard, I forgot to put in a crystal, and after diodes, voltage regulator and capacitors for the vreg, I'm out of space. Using the internal 8mhz would be amazing. Unfortunately, I have absolutely no place left for the crystal, as it was tricky just getting all 20 pins, 4 grounds, and the input voltage/ground on the circuit with the limitations of the pcb process sizes (I use 8mil spacing to be safe)

madworm

What is the problem ;-)

I do this on a regular basis with ATmega168 chips using the 8MHz optiboot running at 115200. And it even works most of the time.

Code: [Select]

RGBLedRing2.name=RGB LED RING - ATmega168 / 8MHz RC OSC / optiboot Bootloader
RGBLedRing2.upload.protocol=stk500
RGBLedRing2.upload.maximum_size=15872
RGBLedRing2.upload.speed=115200
RGBLedRing2.bootloader.low_fuses=0xE2
RGBLedRing2.bootloader.high_fuses=0xDD
RGBLedRing2.bootloader.extended_fuses=0x04
RGBLedRing2.bootloader.path=optiboot
RGBLedRing2.bootloader.file=optiboot_pro_8MHz.hex
RGBLedRing2.bootloader.unlock_bits=0x3F
RGBLedRing2.bootloader.lock_bits=0x0F
RGBLedRing2.build.mcu=atmega168
RGBLedRing2.build.f_cpu=8000000L
RGBLedRing2.build.core=arduino


You'll have to adjust the fuse-settings, target and maximum_size. And don't forget the 100nF capacitor and 10k pull-up on the reset line to make the auto-reset work.
• Upload doesn't work? Do a loop-back test.
• There's absolutely NO excuse for not having an ISP!
• Your AVR needs a brain surgery? Use the online FUSE calculator.
My projects: RGB LED matrix, RGB LED ring, various ATtiny gadgets...
• Microsoft is not the answer. It is the question, and the answer is NO!

Go Up