Bootloader Burning Issue

I have a custom CCA that utilizes an ATMEGA328 but with an external clock of 1MHz that I originally burned the ADABOOT bootloader on using an Arduino Nano. Everything worked as expected, only issue is I noticed the boot up time is a little long and after some research it seems that putting the Opti bootloader on may help with this.

Thus, I am trying to burn the opti bootloader onto my CCA, this time using an Elegoo Uno R3. I successfully was able to upload the ArduinoISP sketch onto the Uno but when I go to burn the bootloader I get the following error:

avrdude: Version 6.3-20190619
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2014 Joerg Wunsch

         System wide configuration file is "C:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf"

         Using Port                    : COM7
         Using Programmer              : stk500v1
         Overriding Baud Rate          : 19200
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x03
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x03
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x03
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x03
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x03
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x03
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x03
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x03
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x03
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x03

avrdude done.  Thank you.

Error while burning bootloader.

I'm wondering if there is some sort of communication error since my custom CCA has the other bootloader on with different boards.txt settings than the default

f_cpu = 8000000L
upload speed = 7200
low fuse = 0XCB
high fuse = 0xDA
extended fuse = 0xFD

When I perform the loopback test I don't get an echo on the serial monitor. I see both the "Rx" and "Tx" lights blink on the Uno, not sure if something is up there... Do you need to have a certain sketch uploaded for that to work?

Thanks,
Pete

Did you disable auto-reset on the Elegoo?

I did not, I see that requires cutting a trace on the Uno. Why wouldn't have this been an issue with the original Nano board I used to burn the bootloader originally?

There are ways to disable the autoreset that does not require cutting traces.

Google "arduino disable auto reset".

Put a 10uF cap from reset to ground to temporarily disable autoreset. Be sure to observe polarity of the cap.

1 Like

I see that, unfortunately I don't have any components on hand to do it that way. Interesting why the how to on burning a bootloader doesn't mention this.... I'll give it a shot.

Similar to burning the bootloader, you can upload your sketch via ICSP. That way there will be no delay, your sketch will run straight away.

You will still have to take the hurdle that prevents you from burning the bootloader.

1 Like

What clock setting are you choosing when you burn the Optiboot bootloader?

1 Like

Optiboot, the bootloader that should be on your Nano, times-out after one second. That's also the timeout for avrdude. If the board runs a bit fast or avrdude runs a bit slow everything works. Otherwise, it too would have needed auto-reset to be disabled.

In other words, you got lucky.

Instructables? Blog? (Please don't be an Arduino webpage.)

1 Like

Clock settings:

Low fuse setting is 0XCB which =
Ext. Crystal Osc; Frequency 0.9-3.0MHz; Start-up time PWRDWN/RESET: 1K CK/14CK + 65ms; [CKSEL=1011 SUT = 00]

As mentioned my f_cpu is set to 8000000L and upload speed is set to 7200.

Just in case it matters, when my custom board is functioning I have to set the serial monitor to 1200 baud to be able to communicate.

My custom board runs a 2MHz external resonator.

Yes an arduino page instruction.... hangs head low.

If you could post a link / url, somebody might be able to fix / raise awareness :wink:

Could u pls share the page link

https://learn.sparkfun.com/tutorials/installing-an-arduino-bootloader/all

I have same problem, I'm going boat loading atmega 8a with Aduino atmega 2560.

Still riding the struggle bus... Cut the trace for the auto reset on the Uno, confident i'm successful because i wasn't able to upload the code to the uno without jumping it again.

After that I tried to burn the bootloader once again and now i get this:

avrdude: Version 6.3-20190619
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2014 Joerg Wunsch

         System wide configuration file is "C:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf"

         Using Port                    : COM7
         Using Programmer              : stk500v1
         Overriding Baud Rate          : 19200
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x4b
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x4b
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x4b
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x4b
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x4b
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x4b
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x4b
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x4b
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x4b
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x4b

avrdude done.  Thank you.

Error while burning bootloader.

avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00

Are you sure you uploaded the File > Examples > 11.ArduinoISP > Arduino ISP sketch to the Uno board you are using as a programmer?

Yes, I did... Here is some updates, I was able to play with the settings in the Arduino ISP sketch and board.txt file and got it to burn the bootloader.

Now my problem is it won't let me upload a sketch, I get this error:

 Using Port                    : COM6
         Using Programmer              : arduino
         Overriding Baud Rate          : 115200
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x7a

I think the issue is that Overriding Baud Rate of 115200... I don't understand where it is getting that value from. It's not in the Uno portion of the Boards.txt file nor is it in the Arduino ISP code I had used. I feel like if i can change that then i'll be in business.

You do realize that when you do "burn bootloader" the port needs to be set to the port that has the Uno running ArduinoAsISP on it, and to upload a sketch, it needs to be changed to the port that actually has your new board on it?

Overriding Baud Rate          : 115200

Which bootloader did you use, exactly? MiniCore has optiboots built for a wide variety of CPU clock speeds and upload baudrates, but I think that the maximum upload rate with a 1MHz clock is going to be 9600bps. You certainly won't get 115200... (this means that I'm not sure that Optiboot will be any faster that Adaboot...)

Yes, but they're two different USB cables because the the one for the uno is your typical usb to usb but by custom board uses an ftdi cable. The computer just assigns them different COM numbers.

I'm using the optiboot from here. https://www.google.com/url?sa=t&source=web&rct=j&url=https://github.com/Optiboot/optiboot&ved=2ahUKEwjA5PuBzcX3AhWwjokEHclyDvIQFnoECAYQAQ&usg=AOvVaw0DuwLtdeI7YCn1hzDbSoev

Although i went back and tried to load the Adaboot one i had used originally and still seem to be having issues for some reason.

Also i misspoke earlier, I'm using a 2 Mhz resonator.

My understanding was the optiboot had some sort of fast start feature that the others don't which made it faster.... regardless, it isn't uploading the sketch.