Go Down

Topic: Arduino Serial Monitor (Ubuntu 10.04 64bit) [SOLVED] (Read 8705 times) previous topic - next topic

IAmCorbin

Jan 29, 2011, 09:15 pm Last Edit: Feb 06, 2011, 06:55 am by IAmCorbin Reason: 1
I am still having trouble reading serial output from the Arduino. I am able to do it via the linux terminal but it crashes the Arduino IDE when I open the monitor. I also get the same error when I try and use the RxTx library to read serial with java through Eclipse.

If I run the Arduino IDE as root it results in the same crash as well.

The Arduino monitor actually worked when I first installed it up until I ran this command:
Code: [Select]
stty -F /dev/ttyUSB0 cs8 9600 ignbrk -brkint -icrnl -imaxbel -opost -onlcr -isig -icanon -iexten -echo -echoe -echok -echoctl -echoke noflsh -ixon -crtscts
which now allows me to use the command:
Code: [Select]
tail -f /dev/ttyUSB0
to read the serial output to the terminal

Here is the original post with all the details: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1295756150


mrtaylor

I have working on another problem which may or may not be related to yours. so I have to ask what kernel version are you running? (uname -mrs)

mellis

In the original post, it looks like you had a version mismatch between the RXTX jar and the native library.  Have you tried it with both pieces at 2.2pre2 (or whatever the latest version for your distribution is)?

IAmCorbin

@mrtaylor - I am running Linux 2.6.32-24-generic x86_64

@mellis - I tried updating to the latest version multiple times but can't seem to update my native lib version. Does this just mean there is a RxTx jar on my system I need to replace with the latest version? I thought I had moved all the RxTx files to the necessary locations, but I guess not?

mellis

The native lib is probably called something like libRXRX.so or librxtxSerial.so or similar.  I'm not sure where it is, but having a mismatch between the Java and native version of the library could definitely cause problems or crashes.

IAmCorbin

#5
Feb 05, 2011, 12:54 am Last Edit: Feb 06, 2011, 06:36 am by IAmCorbin Reason: 1
I'm trying to search for the old library files like so:

Code: [Select]
find /. -readable -name *RXTX*
find /. -readable -name *rxtx*


But the only results are in my arduino workspace directory where I downloaded the rxtx files.

Does anyone else know where these files are hiding? or why it's still showing the old native versions when I can't even find them on the system?

mrtaylor

#6
Feb 05, 2011, 04:11 am Last Edit: Feb 05, 2011, 04:18 am by mrtaylor Reason: 1
find / -ls 2>&1 | grep -i librxtxSerial

edit added:  I believe my is the same.  mine works great.
./arduino
Stable Library
=========================================
Native lib Version = RXTX-2.2pre2
Java lib Version   = RXTX-2.1-7
WARNING:  RXTX Version mismatch
   Jar version = RXTX-2.1-7
   native lib Version = RXTX-2.2pre2

mrtaylor

I believe and don't quote me on this, your problem is related to a bug in the linux kernel.
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/690798.  This is a long and drawn out bug and seems to affect a lot of different kernel versions.  Maybe you could search and find a kernel that works and upgrading to that kernel.

The kernel version I am running is: Linux 2.6.35-25-generic x86_64


IAmCorbin

Alright, I upgraded my kernel to 2.6.32-28 and was still getting the same crash.

I found and replaced the conflicting RXTX files with the 2.2pre2 version ones and now it is working. Thanks for the help.

mrtaylor


Go Up