Which bootloader? Atemga8 w/ 8MHz EXTERNAL xtal

Hi I have a non-arduino board that uses an Atmega8 and an 8 MHz external xtal. I'd like to load the arduino bootloader onto it, but I'm not sure how to proceed. I think there are few options, but I'm not sure which is right. Do I...

  1. Burn the regular 16 MHz bootloader onto it, and just change the board definition to:
atmega8.build.f_cpu=8000000L

or:

  1. Burn the 8 MHz bootloader, and just change the fuse bits to external xtal instead of internal. Also, change the board definition as above.

Will either of these options work? Thanks.

i think you should recompile the bootloader for atmega8 @ 8Mhz and change the fuse bits - if you burn the 16Mhz bootloader youll probably have problems uploading code to it :slight_smile:

also i recommend the optiboot for the bootloader - cause its small and i had a lot of success with it using the same mcu :slight_smile: https://github.com/WestfW/Arduino/tree/master/hardware/arduino/bootloaders/optiboot

Hi, thanks for the input. For other reasons, now, it appears that I do need a custom bootloader. Is it possible to compile the bootloader in the arduino software, or do I need to use something like winavr? I would like to work with optiboot, because it appears that there is a soft serial port option, which would be very useful for my project. Thanks.