Ferraganchos & Pinchos

Or how to rip all this stuff out of my head…

Archive for the tag “bootloader”

CDC Bootloader on (Dealextreme) Teensy

The bootloader provided by Dealextreme in Teensy boards is not compatible with Teensy Loader (At least the boards I have with loader 1.06).
In order to have a better (non-proprietary) bootloader we can choose from three provided by LUFA:
  • CDC Class, AVR109 protocol compatible (AVRDude)
  • DFU Class, Atmel DFU protocol compatible (Atmel FLIPdfu-programmer)
  • HID Class, with an included custom cross-platform loader application (Teensy Loader compatible???)
From an Arduino point of view, CDC is the best choice now, but DFU procedure is similar.
I’ve used an avrdragon with avrdude. Here is the connection between Teensy and avrdragon ISP connector:
And now the software part:
MCU=at90usb162
BOARD= TEENSY
F_CPU = 16000000
FLASH_SIZE_KB = 16
  • make
  • WOW!!! We have BootloaderCDC.hex
  • upload
sudo avrdude -v -pusb162 -cdragon_isp -Pusb -Uflash:w:BootloaderCDC.hex
Using ‘lsusb’ you should see something like:
Bus 003 Device 004: ID 03eb:204a Atmel Corp. LUFA CDC Class Bootloader
Now we can upload code using CDC bootloader:
sudo avrdude -v -pusb162 -cavr109 -P/dev/ttyACM0 -Uflash:w:blink.hex
Due to reset circuit on Teensy 1.0 you must repower the board in order to launch the uploaded app (reset button always enters to bootloader mode).
Advertisements

Post Navigation