chipKIT® Development Platform

Inspired by Arduino™

Nice, but... startup barf

Created Sat, 30 Jul 2011 03:43:49 +0000 by pickey


pickey

Sat, 30 Jul 2011 03:43:49 +0000

Thanks for trying to get a FOSS IDE going, but it's not nearly as far as arduino (I mean the real thing).

Basic installation instructions would be good for starters.

System: openSUSE 11.4 64bit

As there are no instructions at all, start by unpacking the tar file. Nothing left but to run mpide.

cd mpide-0022-chipkit-linux32-20110619
./mpide

[error removed because this dumb bollocks board says it's too spamy]

Oops. It's only 32bit software. Why is there a librxtxSerial64.so? If it needs to be used on a 64bit system, it obviously isn't. If a 32bit one is needed, there isn't one.

The arduino 0021 IDE provided one that works (also RXTXcomm.jar), though I'm not sure the 0022 does. At least you need to document this somewhere.

Obviously the smart thing to do would be to get your pic changes incorporated into the official arduino IDE.

The mpide script is dubious. It sets paths up for ${APPDIR}/java/bin. Pity there's no ${APPDIR}/java ...

Trying to compile a sample sketch just barfs:

/tmp/pic/mpide-0022-chipkit-linux32-20110619/hardware/pic32/compiler/pic32-tools/bin/../pic32mx/bin/gcc/pic32mx/4.5.1/cc1plus: error while loading shared libraries: libelf.so.1: cannot open shared object file: No such file or directory

The system has: ldconfig -p | grep libelf
libelf.so.1 (libc6,x86-64) => /usr/lib64/libelf.so.1 libelf.so.0 (libc6,x86-64) => /usr/lib64/libelf.so.0 libelf.so.0 (libc6) => /usr/lib/libelf.so.0

Oops, no 32bit libelf 1, only libelf 0. No problem, can be installed:

zypper -vv in libelf1-32bit

Restart IDE. Finally get Blink compiled.


pickey

Sat, 30 Jul 2011 03:46:11 +0000

Exception in thread "main" java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path

Rest deleted becasue of BB. Fix BB please or I won't be using it again.


WestfW

Sat, 30 Jul 2011 07:57:19 +0000

Why is there a librxtxSerial64.so?

IIRC there was a bug in the librxtxSerial64.so tha comes with java that affected Arduino, bu the 32bit version was OK. So the arduino distribution contains its own rxtxserial64.

the smart thing to do would be to get your pic changes incorporated into the official arduino IDE.

I suspect that everyone using chipkit, and a bunch of other people with potentially similar platforms agrees with this, but the (official) arduino team has a somewhat different set of priorities (they're frantically trying to decide on what should be in "Arduino 1.0")

The mpide script is dubious. It sets paths up for ${APPDIR}/java/bin. Pity there's no ${APPDIR}/java ...

You complaints seem valid. in fact, there doesn't seem to be a "java" directory anywhere in the entire directory structure. However, on my Ubuntu10 virtual machine (32bit), the mpide script "just works" (including compiling sketches) when run from the decompressed tar file. That's ... interesting. I don't think I understand how java starts its apps. Perhaps it was working for me because I had already installed Arduino? I dunno. The subtle variations between the various unix systems can be very confusing and frustrating...


pickey

Sat, 30 Jul 2011 10:09:50 +0000

java startup: my mpide script now works too. It looks like a safe bet that the CLASSPATH is set generously and that non-existing parts are ignored. Maybe it's like that for the possibility of shipping java with the IDE (bad idea - not yet another java please). I looked closer at the script to find out what went wrong, but the script itself works.

I had 2 problems only as it turned out:

  1. The 2 rxtx files don't work or are not found. The 64bit one supplied is never used. If it was meant to be renamed on a 64bit system - well don't bother shipping it unless you say to do so. There were some problems with the rxtx bits with the arduino too, I don't recall how I solved them but found functional files somewhere. Since then I just copy them over for each new release.

  2. The 32bit libelf1 is not installed by default on my 64bit system. I can't speak for other 64bit Linux systems. Trivial to fix, one just has to know what package to install.

All of this should go into some installation instructions. Arduino has them too, very helpful they are.

With that the IDE works fine (I don't have a pic board to test), and even the Arduino boards are still in the list and the avr-gcc is run for those. Most impressive.

Re arduino priorities - dunno, but I have no sympathy for egos and 2 foss projects doing essentially the same thing. Improve the IDE instead.