-
Download ATmega's support pack from Microchip's website
-
Unzip the relevant files
unzip -j Atmel.ATmega_DFP.x.y.zzz.atpack \ gcc/dev/atmega328pb/avr5/crtatmega328pb.o \ gcc/dev/atmega328pb/avr5/libatmega328pb.a \ include/avr/iom328pb.h -
Place the
.oand.afiles in/usr/avr/lib/avr5/ -
Place the
.hfile in/usr/avr/include/avr/ -
Add the following to
/usr/avr/include/avr/io.h#elif defined (__AVR_ATmega328PB__) || defined (__AVR_ATmega328__) # include <avr/iom328pb.h>
All set. Ready to compile.
Add the following to /etc/avrdude.conf, right below the definition for ATmega328P.
part parent "m328"
id = "m328pb";
desc = "ATmega328PB";
signature = 0x1e 0x95 0x16;
ocdrev = 1;
;
Happy flashing!
typo: arv-gcc -> avr-gcc