3 Simple Ways to
Share What You Make

With Instructables you can share what you make with the world — and tap into an ever-growing community of creative experts.

PhotosPhotos

Share one or more photos of a project, recipe, or whatever you've made, quickly and easily.

Step by StepStep-By-Step

Share your step-by-step photos with text instructions of what you made so others can do it too!

VideoVideo

Share your how-to video. You'll need your embed code from a video site such as YouTube.

Ghetto Programming: Getting started with AVR microprocessors on the cheap.

Step 2Get and Install Software: Linux Version

Get and Install Software: Linux Version
If you run Windows, skip this page. Or install Linux, then come back. :)

The Linux AVR software toolchain used is:
1) an editor of your choice (emacs, gedit, kate, etc)
2) AVR-GCC compiler and libraries
3) AVRdude programmer
4) A nice Makefile to tie it all together

May 2008 Edit: Ubuntu has packages for the whole toolchain. Your installation is now as easy as: "sudo apt-get install avrdude avr-libc binutils-avr gcc-avr". Bam! The versions that come with 8.04 are good all around. Woot Ubuntu!

If you want to do it "by hand", the script below automates most of the work for you. Note that as of May 2008, it's a year old, and doesn't support the newer ATTinyx5 series chips. You can mess around with updated versions of all the software is you'd like. (It's saved with a .txt extension b/c Instructables wants it. Doesn't matter.)

You're going to have to edit the first command in the install script depending on whether you're using an apt-based package system or a yum-based one. Just uncomment the relevant line. It needs to make sure you've got some packages which are required for the compilation stage.

Have a read through the script to make sure it's not doing anything stupid, then get root and run it and you should be golden.

It will create a directory /usr/local/AVR and install all the AVR tools there.

The last thing the script does is to add avr-gcc to your path so that you can run avr-gcc directly by adding a line to the tail of your /etc/profile.



The other file, setupParport.txt, is just a (very) simple script to set up your parallel port for user use. If you're savvy, you can add the same commands to a boot script so that it enables the parallel port every time you boot up. Otherwise, just run it by hand.



Websites with similar, but different and possibly outdated, procedures include: Psychogenic.com, AVRWiki, and this (old) Linux Focus article.

Alternatively, I hear cdk4AVR has a complete set of compiler tools in RPM format. I haven't tried it, but it could save you the 30 min of compiling time on a slow, old laptop.

« Previous StepDownload PDFView All StepsNext Step »
3 comments
Oct 10, 2009. 1:52 PMmitch_feaster says:
The toolchain you get out of the Ubuntu repos is *painfully* outdated. A guy named "Bingo" over at AVRfreaks has set up a very nice script to build a more up-to-date version of the toolchain. I had mine up and running in about the same amount of time an aptitude install would have taken. You can find the build script it here.
Jan 1, 2007. 6:12 PMDeominous says:
The hardest things are actually simple but left unexplained. I run windows. I have installed Dapper Drake on an older computer of mine. ATTINY2313's cost $1.50 downtown my simple questions: How do you change a text file into a script and run it on linux? What version of linux are you using? I tried typing all the commands in by hand (sudo) through the console but the install crapped out in the 4.0.3 libraries. I downloaded the 4.1.1 libraries and they didn't work either. The windows program worked on the first click. What did I do wrong?

Pro

Get More Out of Instructables

Already have an Account?

close

All Steps Viewing
View all steps of an Instructable on the same page when you're a Pro Member.

Upgrade to Pro today!
95
Followers
7
Author:The Real Elliot