Hi Christian,
Sorry about the late reply.
The relationship between the bootloader and the application
*********************************************************************
The AVR's flash memory space goes from 0x0000 to 0x3FFF (on an AtMega168) or to 0x7FFF (on an AtMega328). By setting fuses on an AVR it's possible to configure the chip to support two programs: an application which starts at 0x0000 and a bootloader which can start 0.5Kb (in the case of the AtMega168), 1Kb, 2Kb , or 4Kb (in the case of an AtMega328) from the end of flash. This means that both the application/bootloader sections would begin with a set of interrupt vectors, the first one of which is the reset vector. In the case of FIGnition they're both set to 2Kb before the end of flash:
AtMega168: [0x0000:Application...][0x3800:Bootloader...0x3FFF]
AtMega328: [0x0000:Application...][0x7800:Bootloader...0x7FFF]
So, the question is, how does the AVR know which one to run? The answer is that other fuse settings tell it which one to run, but this can also be temporarily modified in software. So, normally FIGnition always resets to the bootloader, and the bootloader first checks to see if SW1 is already pressed - if it is, then FIGnition changes the vectors so that the application would be in control and then jumps to the start of the application.
Other Fuse Settings
***********************
But we also need to set other fuse settings so that e.g. the AVR knows it should expect the clock input to be taken from an external Crystal instead of an internal Resistor/Capacitor oscillator; and so that it knows that /RESET is still the reset pin and not PortC6 etc.
Setting up the Programmer
*******************************
So, there are two things you need to get right.
Firstly, you need to know which bootloader to store on a FIGnition. There's a different one for the AtMega168 and AtMega328 FIGnitions. On this page:
FIGnitionBootloader.hex is the one for the AtMega168 and Bootloader328Rev1_0.hex is the one for the AtMega328.
Secondly, you need to know the correct fuse settings.
On the AtMega168 it's: FuseLow=0xd7, FuseHigh= 0xd6, FuseExtended= 0xf8.
On the AtMega328 it's: FuseLow=0xff, FuseHigh= 0xd2, FuseExtended=0xd7.
They basically mean the same thing, because the fuse bits are in a different order on the two chips (oddly enough).
I hope this helps!
-cheers from Julz