avr fixes
first pass at supporting pebble as a platform, needs work yet