Did you change the xtal to a 20MHz one?
1) whether or not you can actually operate the ATmega328p on a breadboard with a 20Mhz crystal, while all the things requiring timing remain correct,
delay (1000UL * 20 / 16);
I think this would only complicate matters. For example....the "UL" that you placed behind 1000 is new to me, what does it do? Otherwise, delay(1000 * 20/16) does actually make a little sense to me.
Same goes for the ICSP. I haven't a clue what that is.( in spite of many, many previous searches on the topic)
My conclusion is that it is just "another" method to program Arduino that I need not concern myself with right now.
1) is there a proper bootloader that I can install onto a bare ATmega328p(on a breadboard with 20Mhz crystal) that will allow me to load sketches from the IDE without requiring to account for the timing differences within the sketches?
fasteruno.name=Arduino Uno at 20 MHzfasteruno.upload.protocol=arduinofasteruno.upload.maximum_size=32256fasteruno.upload.speed=144000fasteruno.bootloader.low_fuses=0xfffasteruno.bootloader.high_fuses=0xdefasteruno.bootloader.extended_fuses=0x05fasteruno.bootloader.path=optibootfasteruno.bootloader.file=optiboot_atmega328.hexfasteruno.bootloader.unlock_bits=0x3Ffasteruno.bootloader.lock_bits=0x0Ffasteruno.build.mcu=atmega328pfasteruno.build.f_cpu=20000000Lfasteruno.build.core=arduinofasteruno.build.variant=standard
3)is there any other files, ie, Makefile, optiboot, etc. that would need to be changed as well to allow me to load sketches from the IDE to the same breadboard without accounting for the timing differences from within the sketches?
I have found the boards.txt file that came with the IDE, and could cut and paste the fasteruno code you posted into it, but I am not sure that is what you are suggesting that I try, especially regarding your following "compiling errors" comment.
WhatEver.upload.speed=144000 : :WhatEver.build.f_cpu=20000000L
I hope your end application is worth all this pain. You are going to quite a bit of effort for only a 25% speed increase. With most applications the chip is sitting around waiting for input, the raw chip speed isn't all that important.
Binary sketch size: 2,594 bytes (of a 32,256 byte maximum)avrdude: ser_setspeed(): tcsetattr() failedavrdude: ser_open(): can't set attributes for device "/dev/cu.usbserial-FTFAYL28": Invalid argumentioctl("TIOCMGET"): Bad file descriptoravrdude: ser_close(): can't reset attributes for device: Bad file descriptor
As regards your sketch not working at 115200, could it be that at 20MHz there is no division ratio that will generate that baudrate closely enough?
Is it necessary to compensate in the code for example, delay(1000*20/16) for a 1 sec delay, or will a simple edit of the boards.txt file be sufficient?
Is the baudrate edit also required?
UBRR and clock speed are between 1% and 2% off
Please enter a valid email to subscribe
We need to confirm your email address.
To complete the subscription, please click the link in the
email we just sent you.
Thank you for subscribing!
via Egeo 16