วันอาทิตย์ที่ 12 กรกฎาคม พ.ศ. 2552

AVRUSBBoot

AVRUSBBoot - USB bootloader for Atmel AVR controllers

AVRUSBBoot is a bootloader for the Atmel AVR controllers. It uses a firmware-only USB driver to transfer binary data from the
PC to the flash of the controller. Once the AVR is flashed with the bootloader, no other ISP programmer is needed; then the
microcontroller can be reprogrammed over USB.
Features
Software works under multiple platforms. Linux, Mac OS X and Windows are tested.
Tested with ATMega8-16
No special USB controllers or smd components are needed.
Bootloader fits into 1024 word bootloader block
Hardware
Basically AVRUSBBoot can be used with all circuits which are supported by the AVR USB driver. To switch between the
bootloader and the application, an aditional jumper is necessary. Here is an example (Here the levels on the data lines are 5V
which doesn't meet the USB specification! The supply voltage should be regulated to 3,3V - 3,6V):

Firmware and adaptation
The firmware has to be adapted to your hardware. All necessary changes has to be done in the following two files:
bootloaderconfig.h:
Define the condition when the bootloader should be started, e.g. if a special pin is put to ground with a jumper, and the
initialisation of the hardware.
usbconfig.h:
Define the used data line pins. You have to adapt USB_CFG_IOPORT, USB_CFG_DMINUS_BIT and
USB_CFG_DPLUS_BIT to your hardware. The rest should be left unchanged.
Compile the firmware. You need avr-gcc, avr-binutils and avr-libc:

$ cd firmware
$ make


The bootloader firmware has to be written to the controller with a ISP programmer. Once the bootloader is flashed, you don't
need a programmer and you can download the binary data over USB. Don't forget to set the fuses for the external clock source
when flashing the bootloader for the first time!

Software
A C++ tool for downloading hex files is provided. To compile the program, you need libusb.

$ cd software
$ make


When the device is connected and the bootloader is started (set the jumper before connecting the device), hex files can be
written to the flash of the microcontroller:

$ ./avrusbboot test.hex


Download
avrusbboot.2006-06-25.tar.gz (128 kB)
Links
http://www.obdev.at/products/avrusb/ Firmware-only AVR USB driver
http://libusb.sourceforge.net/ libusb
http://libusb-win32.sourceforge.net/ LibUsb-Win32

ไม่มีความคิดเห็น:

แสดงความคิดเห็น