Turn-key PCB assembly services in prototype quantities or low-volume to mid-volume production runs

USB bootloaders for AVR microcontrollers

Probably the most proper microcontroller programming method is using a bootloader program. Because you don’t need any special programming adapters or special knowledge – you need to connect a standard cable from your PC to the target board and run a special program on the PC which communicates with the MCU bootloader program. The idea is simple:

AVR bootloader model

If the microcontroller is preconfigured, then after reset, it starts running not from the start memory location, which is usually at 0x0000 address, but at some specific location, where usually bootloader lies.

All AVR ATmega family microcontrollers can be programmed with a bootloader. Program start address depends on AVR fuse settings. If settings say that the program counter PC has to jump to the bootloader section after reset, then the bootloader has to be executed. Bootloaders can be of various sizes and can use different algorithms and interfaces from where the program will be loaded. Sources can be Flashcards (MMC/SD), I2C, USART, SPI, and USB.

Variety of AVR bootloaders

Most AVR bootloaders are using a COM port for connectivity with PC. This can be OK if a USB-USART bridge is used. As a matter of fact, it is not always to run somebody’s written bootloader for the first time. Usually, it may require some customizations, reading help documents. IN the list, you can see a list of the most popular bootloaders available (there may be more):

There are even more bootloaders, but most of them are for COM port. These can be adapted to USB by using USART to USB bridges like FT245BM. It is probably more convenient when the USB is connected directly to MCU, and the firmware USB driver does the communication part.

3 Comments:

  1. Pingback: Electronics-Lab.com Blog » Blog Archive » USB bootloaders for AVR microcontrollers

  2. Yes, the bootloaders are nice, but the problem is that you must put the bootloader program in the micro by normal programming…

  3. Pingback: Ninjia Arduino» Blog 存档 » 对AVR-USB的初步研究

Leave a Reply