Fixes and enhancements for use in embedded environments (IAR).  Tests currently fail on Linux.