📬❄️📦Adafruit Holiday Shipping Deadlines 2019: Please place all UPS 3 Day orders by 11am ET Friday December 13 📬❄️📦
0

Problem with Howto getting 328 to work Arduino 12 on linux
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Problem with Howto getting 328 to work Arduino 12 on linux

by gordonendersby on Fri Nov 14, 2008 4:52 pm

Hi,
Ive recieved my 328p chips and now spent many hours trying to get the ide to work and Im getting a bit frustrated.
Im using XUbuntu8.04 but have also tried this on Ubuntu Hardy without success.

Ive followed the howto, on this forum, to update avr-gcc and applied the diff to the arduino 12 ide but Im getting an error message when the ide starts up as follows:
java.io.IOException: Cannot run program "avr-g++": java.io.IOException: error=2, No such file or directory
at java.lang.ProcessBuilder.start(ProcessBuilder.java:459)
at java.lang.Runtime.exec(Runtime.java:593)
at java.lang.Runtime.exec(Runtime.java:466)
at processing.app.Library.build(Library.java:432)
at processing.app.LibraryManager.buildAllUnbuilt(LibraryManager.java:228)
............... goes on a bit more.....

Ive checked my path and the permissions on the directories and everything looks as it should.
echo $PATH
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/gordon/bin:/home/gordon/local/avr/bin

avr-g++ is under /home/gordon/local/avr/bin

Shouldnt the ide use the path to find avr-g++?
or is there something in the ide I need to change?

Thanks

Gordon

gordonendersby
 
Posts: 10
Joined: Fri Nov 14, 2008 4:41 pm

Re: Problem with Howto getting 328 to work Arduino 12 on linux

by gordonendersby on Sun Nov 16, 2008 6:17 am

Should I have ignored the instructions to do with the PATH and PREFIX and installed to the default directories?

Has anyone else followed the instructions for Linux and successfully installed the upgraded GCC stuff?
Did you follow the PATH and PREFIX instructions as well?

Thanks

Gordon

gordonendersby
 
Posts: 10
Joined: Fri Nov 14, 2008 4:41 pm

Re: Problem with Howto getting 328 to work Arduino 12 on linux

by SolidSilver on Sun Nov 16, 2008 12:11 pm

There are two things I'd check. First, put the avr/bin directory at the beginning of your path instead of the end. And make sure you have logged out and back in. Otherwise, the environment in which your window manager launched will not see the changed path.
SolidSilver
 
Posts: 65
Joined: Sat Mar 31, 2007 11:29 am
Location: Portland, ME

Re: Problem with Howto getting 328 to work Arduino 12 on linux

by gordonendersby on Sun Nov 16, 2008 2:18 pm

Yes, I have ensured I re-logged in and that the path was correct.
I hadnt tried changing the order of the path variable.
Ill give it a go but that sounds a bit strange to have to have the directories Arduino needs at the beggining of the path variable.
Ill give it a go.
If that doesnt work then Im going to try installing to the default directories.
Luckily Im working in a virtual machine in virtualbox so can just rollback my snapshot.
Even so this is taking a lot of time to get going.

Gordon

gordonendersby
 
Posts: 10
Joined: Fri Nov 14, 2008 4:41 pm

Re: Problem with Howto getting 328 to work Arduino 12 on linux

by gordonendersby on Tue Nov 18, 2008 7:38 am

Got a bit further.
Re-installed the avr-gcc support again but this time in the default location without the prefix.
Its seems to have found the GCC stuff but now Im getting errors about not finding supporting files.
Error building library "EEPROM"


EEPROM.cpp:24:24: error: avr/eeprom.h: No such file or directory
In file included from /home/gordon/arduino-0012/hardware/cores/arduino/WConstants.h:1,
from EEPROM.cpp:25:
/home/gordon/arduino-0012/hardware/cores/arduino/wiring.h:28:20: error: avr/io.h: No such file or directory
In file included from EEPROM.cpp:26:
EEPROM.h:23:22: error: inttypes.h: No such file or directory
In file included from /home/gordon/arduino-0012/hardware/cores/arduino/WConstants.h:1,
from EEPROM.cpp:25:

This goes on for a while as all the includes in EEPROM.CPP cant be found.
Ive tried modifying the path and rebooting but still no good.

I think Ill have to leave this for a while and get on with something else.
Which is a shame as I wanted to use the 328's but I can get on with another part of the project and merge it in later when I finally get this going. Ill probably end up using the windows version of version 12 as a last resort.

Gordon

gordonendersby
 
Posts: 10
Joined: Fri Nov 14, 2008 4:41 pm

Re: Problem with Howto getting 328 to work Arduino 12 on linux

by adafruit on Tue Nov 18, 2008 2:01 pm

it isnt useful now, but i know that the next rev of the IDE will support the '328

adafruit
 
Posts: 12151
Joined: Thu Apr 06, 2006 4:21 pm
Location: nyc

Re: Problem with Howto getting 328 to work Arduino 12 on linux

by gordonendersby on Tue Nov 18, 2008 2:13 pm

That will be handy. I wonder when that will be released.
I think Ubuntu 8.10 Intrepid Ibex has a new version of the avr gcc toolchain that supports the 328.
So then its just a matter of applying the patch to version 12.
Im going to have a look and load that up as a virtual machine to see it that gets me working.

Gordon

gordonendersby
 
Posts: 10
Joined: Fri Nov 14, 2008 4:41 pm

Re: Problem with Howto getting 328 to work Arduino 12 on linux

by gordonendersby on Tue Nov 18, 2008 5:39 pm

Success!

Installed Ubuntu 8.10 Intrepid Ibex as a virtual machine and it has avr-gcc ver 4.3.0 and it contains support for the 328.

So all I had to do was install Java, avr-gcc and avr-libc as per the standard linux instructions then applied the diff to Arduino version 12 and it all seems to work.

Installing Ubuntu 8.10 to a virtual machine is far quicker than compiling manually.
So I now have two virtual machines. One with the standard arduino 12 ide and earlier avr gcc toolchain and a second one with the 328 support.

Gordon

gordonendersby
 
Posts: 10
Joined: Fri Nov 14, 2008 4:41 pm

Please be positive and constructive with your questions and comments.