I attended the BACnet Interoperability Workshop again this year. The Plugfest was held in Milwaukee. I tested another BACnet Stack at SourceForge enabled device. This time it was an Atmel AVR ATmega168 using the GCC WinAVR compiler. It was utilizing the BACnet MS/TP datalink layer, and had a Device object and 9 Analog Input objects inside. It supported the ReadProperty service, and WhoIs and I-Am services for binding. It had a Maximum APDU size of 128 bytes.
AVR Memory Usage
Program: 16350 bytes (99.8% Full)
(.text + .data + .bootloader)
Data: 630 bytes (61.5% Full)
(.data + .bss + .noinit)
Here is the key that helped me fit the code. I found a GCC compiler and linker directive that allowed all the unused functions and dead code to be removed. I found the directive initially on the GCC M68HC11 FAQ. It saved me from having to split out all the functions into separate files and put them into a single library.
I also met some great folks, some of whom were using the BACnet Stack at SourceForge in their products. I also saw a lot of folks using Wireshark for BACnet protocol analysis. I also got to see a lot of friends that I have made over the years.
Edit: I compiled the project with IAR AVR version 4 compiler and here are the memory usage statistics:
10 055 bytes of CODE memory (+ 36 range fill )
553 bytes of DATA memory (+ 24 absolute )