Pages: [1]   Go Down
Author Topic: [SOLVED] atmega8 slow bootloader?  (Read 1163 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 1
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I burned bootloader to atmega8 with ponyprog2000, then uploaded testing sketch with usb-ttl, it works fine but the bootloader seems to be VERY slow, it takes about 10 seconds. On arduino nano (atmega168) and arduino mega (atmega2560) it takes only 2 seconds.
I burned bootloader from hardware\arduino\bootloaders\atmega8\ATmegaBOOT.hex.
Atmega8 in this circuit is working from external ceramic 16mhz resonator (ZTT 16.0MX). Is it normal that boot process takes so long or I'm doing smth wrong? I've googled atmega8 slow boot and have found nothing, pls help.
« Last Edit: April 26, 2011, 08:30:01 am by b0bbykey » Logged

0
Offline Offline
Shannon Member
****
Karma: 206
Posts: 12070
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Probably the wrong version of the bootloader - for instance the Arduino Mini 4 has an 8 second wait for reset-button press in its bootloader since it doesn't have auto-reset circuit.
Logged

[ I won't respond to messages, use the forum please ]

Offline Offline
Newbie
*
Karma: 1
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Probably the wrong version of the bootloader - for instance the Arduino Mini 4 has an 8 second wait for reset-button press in its bootloader since it doesn't have auto-reset circuit.

You were right! I took this "slow" bootloader from arduino-021 distribution. It seems to have intentional delay here it is if I am not mistaken:

Code:
char getch(void)
{
  /* m8 */
uint32_t count = 0;
  while(!(inb(UCSRA) & _BV(RXC))) {
/* HACKME:: here is a good place to count times*/
count++;
if (count > MAX_TIME_COUNT)
app_start();
  }
  return (inb(UDR));
}

I've found another bootloader on the net, here it is if anybody is in need http://www.ngcoders.com/downloads/arduino-atmega8-bootloader-2-second-autoreset.

Thanks for the help!
« Last Edit: April 26, 2011, 08:31:21 am by b0bbykey » Logged

Offline Offline
Sr. Member
****
Karma: 7
Posts: 447
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Cool, Thanks a lot for Sharing
Logged

Offline Offline
Full Member
***
Karma: 12
Posts: 150
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Optiboot supports the mega8. It is included with the IDE. arduino-1.0.5/hardware/arduino/bootloaders/optiboot
Logged

Pages: [1]   Go Up
Jump to: