Add AVR detection logic