|
From: | Larry Barello |
Subject: | RE: [avr-gcc-list] AT90CAN128 bootloader |
Date: | Sat, 25 Nov 2006 09:58:43 -0800 |
Thanks!
IIRC you can cut out the EEPROM support and the boot loader fits into 256 words…
While paring down the size I cut out the C startup (there is no “main()”) & runtime support and moved statics/globals into automatics assuming they would go onto the stack. However that clever compiler kept everything in registers and the resulting code generation was spectacular.
One thing not mentioned in the README is if your application scans for 0x30, 0x20 (no echo) and then “jumps” to the bootloader + one instruction, you can have entry into the loader automatic. I do that with all my projects (that have user interfaces) with a tiny state machine that eats the two characters (printing them if it fails). That way I don’t have to reset or otherwise fool around: Just run AvrDude and tada! new code in 10 seconds or less. “0 “ is an unusual sequence so I never trip across it otherwise.
Cheers!
Nice work! Compiled with avr-gcc 3.4.6 it uses
just 418 instructions out of 512 and it works with "avrdude"! -- Bruce D. Lightner Lightner Engineering La Jolla, California Voice: +1-858-551-4011 FAX: +1-858-551-0777 Email: address@hidden URL: http://www.lightner.net/lightner/bruce/ |
[Prev in Thread] | Current Thread | [Next in Thread] |