Refers to the code burned on the Arduino flash memory that runs every time the board is powered up. It starts the execution of user-loaded programs and allows uploading sketches from a PC through the USB connection. This tag should be used for questions about modifying, changing, uploading the default bootloader.
The bootloader is a small piece of code loaded into the high part of program memory (flash memory). It is optionally invoked by the processor after a reset (depending on
BOOTRST fuse setting).
Its purpose is to allow self-programming of the flash, generally by checking the serial port for specific "programming" sequences within the first second or so after a reset. If such a sequence is found the bootloader responds to the programmer (usually
avrdude running on the host computer), and in conjunction with the programmer accepts and acts upon instructions to erase and reprogram memory, change the EEPROM if desired, and change the fuses if desired.
The use of the bootloader avoids the need for special hardware to upload new code. However to change the bootloader itself (something not normally necessary) a special programmer is needed which plugs into the ICSP (In Circuit Serial Programming) header of the Arduino.
Once the bootloader has finished uploading new code (if required) it jumps to address 0x0000 which is the start of the actual code, so that the newly-uploaded sketch can now start.
If no programming instructions are detected by the bootloader after a short delay, it jumps to address 0x0000 to execute the previously-loaded code.