Pages: [1]   Go Down
Author Topic: arduino on Gentoo AMD64  (Read 807 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 10
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,
I have problems getting arduino 0006 to work. I followedthe manual on http://www.arduino.cc/playground/Linux/Gentoo but it won't make it happen.

# ./run.sh
Warning: Cannot convert string "-b&h-lucida-medium-r-normal-sans-*-140-*-*-p-*-iso8859-1" to type FontStruct
java.lang.UnsatisfiedLinkError: /root/arduino-0006/build/linux/work/lib/librxtxSerial.so: /root/arduino-0006/build/linux/work/lib/librxtxSerial.so: wrong ELF class: ELFCLASS32 thrown while loading gnu.io.RXTXCommDriver
Exception in thread "main" java.lang.UnsatisfiedLinkError: /root/arduino-0006/build/linux/work/lib/librxtxSerial.so: /root/arduino-0006/build/linux/work/lib/librxtxSerial.so: wrong ELF class: ELFCLASS32
        at java.lang.ClassLoader$NativeLibrary.load(Native Method)
        at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1586)
        at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1511)
        at java.lang.Runtime.loadLibrary0(Runtime.java:788)
        at java.lang.System.loadLibrary(System.java:834)
        at gnu.io.CommPortIdentifier.<clinit>(CommPortIdentifier.java:83)
        at processing.app.Editor.populateSerialMenu(Editor.java:836)
        at processing.app.Editor.buildToolsMenu(Editor.java:730)
        at processing.app.Editor.<init>(Editor.java:174)
        at processing.app.Base.<init>(Base.java:202)
        at processing.app.Base.main(Base.java:177)

Help is very much apreciated!

Thanks, bart
Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 9
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I know nothing about Gentoo, but it sounds like you're getting the 32 bit version of RXTX (which is a Java and native library for doing serial communication) when you need a 64 bit version.  You may need to download it from http://www.rxtx.org/ and compile it yourself.  
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 10
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks, in the end i got the program to run by copying librxtxSerial.so:
 # cp /usr/lib64/rxtx-2/librxtxSerial.so ~/trunk/build/linux/work/lib/

Arduino is recognised, but compiling sketches fails (see below)
Could this be because more .so files are wrong?


error compiling Led_blink:

/home/abortx/trunk/build/linux/work/lib/targets/arduino/WInterrupts.c: In function `attachInterrupt':

/home/abortx/trunk/build/linux/work/lib/targets/arduino/WInterrupts.c:45: error: `GICR' undeclared (first use in this function)

/home/abortx/trunk/build/linux/work/lib/targets/arduino/WInterrupts.c:45: error: (Each undeclared identifier is reported only once

/home/abortx/trunk/build/linux/work/lib/targets/arduino/WInterrupts.c:45: error: for each function it appears in.)

/home/abortx/trunk/build/linux/work/lib/targets/arduino/WInterrupts.c: In function `detachInterrupt':

/home/abortx/trunk/build/linux/work/lib/targets/arduino/WInterrupts.c:56: error: `GICR' undeclared (first use in this function)

Couldn't determine program size: /usr/bin/avr-size: '/tmp/build58558.tmp/led_blink.hex': No such file
« Last Edit: November 30, 2006, 11:10:24 am by bart » Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 9
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Ah, it sounds like you've checked the code out of svn.  It's in development at the moment, so may not be stable.  You might want to use the source distribution at http://www.arduino.cc/en/Main/Software.  Which Arduino board are you using?
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 10
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Ah, it sounds like you've checked the code out of svn.  It's in development at the moment, so may not be stable.  You might want to use the source distribution at http://www.arduino.cc/en/Main/Software.  Which Arduino board are you using?

I will try this tonight.
I have an Arduino NG
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 10
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ok, in the end i reinstalled arduino as you asked me to. It runs ok, no compile errors! I actually copied  /usr/lib/rxtx-2/* and also /usr/share/rxtx-2/lib/RXTXcomm.jar to arduino-0006/build/linux/work/lib/ to make it work.

But it doesn't want to upload to the board:

Code:
Binary sketch size: 4814 bytes (of a 14336 byte maximum)

-dpart: Invalid name.

HEY! ok, just tried my Atmega8 instead of my Atmega168 (and adjusted the setting accordingly) and with my Atmega8 it uploads.
This actually means that also the installation on my older x86 pc works! (same error with same atmega168)
Kewl!! smiley  EDIT: it also worked for the cvs version
Quetsion though: Maybe you have a tip how i can make it work withing a normal user (instead of root) to?
In a normal user the 'serial port' menu is greyed out..
Code:
Binary sketch size: 4610 bytes (of a 7168 byte maximum)

Error: No such file or directory
 -> COM1
« Last Edit: November 30, 2006, 06:36:53 pm by bart » Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 9
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Ah, yes.  The program we use to upload sketches to the board, uisp, is a bit obsolete and the standard release doesn't work with ATmega168s.  The version that comes with the Arduino environment has been patched to work with ATmega168s, but the one you have probably hasn't been.  I'll try to find the patch I applied to the source so you can build a Linux version that supports the 168.
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 10
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

That would be great! Thanks..
Logged

Forum Administrator
Cambridge, MA
Offline Offline
Faraday Member
*****
Karma: 9
Posts: 3538
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

The source package is available here: http://www.arduino.cc/playground/uploads/Linux/uisp-20050207-m168.zip

You'll have to build it yourself, sorry about that.  
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 10
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Super!  
after i installed i had to mv /usr/local/bin/uisp /usr/bin/
Actually for gentoo users who already emerged uisp, it migth be handier to just first
emerge --unmerge uisp
become root and
unzip uisp-20050207-m168.zip
cd uisp-20050207-m168
./configure
make && make install

One more question:  even though i added my user to the uusp group, if i open arduino as non-root user, i don't get acces tom the serial port. This also counts for PD, so it's not arduino related, but if you have a tip where to search?
Logged

Pages: [1]   Go Up
Jump to: