- Create a directory called /opt to place the downloaded AVR tools.
Do this by typing: sudo mkdir /opt
- Then, download all the tools by first going to Microchip's well-hidden website:
AVR and Arm Toolchains (C Compilers)
- Scroll down to GCC Compilers for AVR and Arm-Based Devices.
Select the link: AVR 8-bit Toolchain (Linux) 3.7.0
Click on it to download the file:
avr8-gnu-toolchain-3.7.0.1796-linux.any.x86_64.tar.gz
- Once downloaded, move the file into the /opt directory you created.
sudo mv avr8-gnu-toolchain-3.7.0.1796-linux.any.x86_64.tar.gz /opt
Hint: Use file completion to prevent errors
- Within /opt, unzip and untar the file with:
sudo tar zvxf avr8-gnu-toolchain-3.7.0.1796-linux.any.x86_64.tar.gz
- If not installed, install
sudo apt-get install vim
- Now, we need to tell your system where to look for these tools. To do this,
we alter your $PATH variable. Do this by editing the file ~/.bashrc
That's a tilde, not a hyphen.
At the bottom of the file, add this line:
export PATH=/opt/avr8-gnu-toolchain-linux_x86_64/bin:$PATH
This prepends the new path to the avr executables to your existing $PATH.
- This change will not be recognized by the OS until you rerun the .bashrc file
or logout and back in again. To avoid this:.
cd; source $HOME/.bashrc
- Download and install the programmer utility avrdude 6.3.
sudo apt-get install avrdude
Ubuntu automatically knows to look where avrdude will be installed.