AVR code improvements
Update AVR files
Merge branch 'beta'