Posted on November 4, 2007 in Computers by seadog1 Comment »

Fixed a bug related to python-xml and libexpat. Download the latest version from here

Posted on November 1, 2007 in Computers by seadogNo Comments »

I have just added bluetooth support in my python distribution for the CRIS architecture. You can download the latest python 2.5.1 package (which also features Twisted Python, PyXML and bzr support) from here.

Don’t forget to recompile your AcmeLinux images with libbluetooth.so.2 which you can fetch precompiled from my repo.

You can follow this great tutorial to compile your own image for FoxBoard. Be careful to place libbluetooth.so.2 in /devboard-R2_01/usr/lib/ and not in /devboard-R2_01/usr !

After installing you can test by executing in your cris python console

import bluetooth
bluetooth.discover_devices()

Posted on October 9, 2007 in Computers by seadogNo Comments »

You can download a new version of python 2.5.1 for CRIS platform with zlib which wasn’t compiled on previous versions. Still missing curses libraries. This release also contains bzr vcs (see CHANGES for more)

Download or update your bzr repo

bzr update http://www.sealabs.net/cris/cris-binary/

Posted on September 26, 2007 in Computers by seadog11 Comments »

Using a howto from this site I managed to cross-compile python 2.5.1 for my embedded linux board . Although AXIS provides python 2.4 with their SDK and configures it with no threads and stuff, I compiled the the original python 2.5.1 with only this patch applied to prevent tests from running while cross compiling and to byte-compile python scripts using host’s python compiler.

The patch is heavily based on Chris’, which is heavily based on K’s :) I modified only what was need to successfully patch 2.5.1 (Chris’ patch is for 2.5.0)

Here is a small howto to get you going:

Get python

wget http://python.org/ftp/python/2.5.1/Python-2.5.1.tgz
wget http://www.sealabs.net/seadog/files/python-2.5.1-cris.patch
tar zxf Python-2.5.1.tgz

Apply Patch

cd Python-2.5.1
patch < ../python-2.5.1-cris.patch

Now we compile python for our host architecture to get python and Parser/pgen executables. These are needed to byte-compile python during our cross compile procedure.

./configure
make

Save native python and pgen

mv python hostpython
mv Parser/pgen Parser/hostpgen

Clean everything up

make clean

Now we are ready to cross-compile!

If you have downloaded Acme criss-gcc debian package, don’t forget to add /usr/local/cris/bin to PATH

export PATH="/usr/local/cris/bin:$PATH"

Set enviroment variables

export HOST="cris-axis-linux-gnu"
export CC=" gcc-cris -mlinux -mno-mul-bug-workaround"
export CXX=$(CC)

export LN=” ln”
export RM=” rm -f”

export AR=” ar-cris”
export INSTALL=” install_elinux -p”
export LD=” ld-cris -mcrislinux”
export OBJCOPY=” objcopy-cris”
export RANLIB=” ranlib-cris”
export STRIP=” strip-cris”

export OPT=”-Os”
export CFLAGS=”-Wall -Wshadow -g”
export LDFLAGS=”-fPIC”
export HOSTPYTHON=./hostpython
export HOSTPGEN=./Parser/hostpgen
export CROSS_COMPILE=yes

Configure

./configure --host=$HOST --prefix=/tmp/cris-python --build=`uname -m`-pc-linux-gnu

Make and install respecting enviroment variables

make -e
make -e install

Now check if you can run your cross compiled binary /tmp/cris-python/bin/python. (You shouldn’t!)

seadog@plu:~/Projects/fox/cris-binary/python/bin$ ./python
bash: ./python: cannot execute binary file

Dada! You have a cross-compiled binary!

I also cross compiled twisted python 2.5.0 and pyxml 0.8.

You just untar and execute (python is native binary)

python -E setup.py install --prefix=../cris-python --install-scripts=/tmp/cris-python/bin

I have a bazaar repository with binary python here http://www.sealabs.net/cris/cris-binary which you can checkout using

bzr checkout http://www.sealabs.net/cris/cris-binary

And now my jabber bots can run on my fox board! :)

Posted on September 25, 2007 in Computers by seadogNo Comments »

Πέρασα μία ολόκληρη μέρα προσπαθώντας να εγκαταστήσησω το scratchbox και το build toolchain για την αρχιτεκτονική cris του fox board. ΔΕΝ ΠΑΙΖΕΙ! Για την ακρίβεια -τουλάχιστον το cris κομμάτι- είναι γεμάτο bugs και τελικά παρόλο που κατάφερα να προσπεράσω μερικά δεν τα κατάφερα όλα. Τα debian packages του scratchbox δεν είναι και πολύ προσεγμένα (setup scripts δεν παίζουν!) και λίστα φαίνεται ανενεργή, αφού ακόμη περιμένω το confirmation mail :(
Κρίμα γιατί το project φαίνεται αρκετα ενδιαφέρον και είναι πολύ καλό να έχεις ένα προστατευμένο περιβάλλον για cross-compile.

Θα περάσω μερικές ώρες δοκιμάζοντας και το scratchbox 2, ελπίζοντας μέχρι το βράδυ να έχω μία full python distribuction για την αρχιτεκτονική cris.

Posted on September 22, 2007 in Computers by seadogNo Comments »


Yesterday my fox board arrived! A complete linux system in just 66×72mm based on Axis Etrax 100LX with 32Mib RAM and 8Mib flash memory.

Features:

  • Axis ETRAX 100LX 32 bit, RISC, 100MHz (100MIPS)
  • 8MB FLASH 32MB RAM
  • 1 Ethernet (10/100 Mb/s)
  • 2 USB 1.1
  • 1 serial console port
  • 2 extension sockets with IDE, SCSI, serial lines, parallel ports, I/O lines, I2C bus interface

Yet I haven’t tested the device perfomance comprehensively but I ran some (a bit dissapointing) network tests. I get aroung 150Kib / sec using secure copy which means I will have to wait for a stronger Fox to build my embedded torrent download server :)

Acmesystems, the company which builds fox, besides the great name (see Acme Corp) is linux friendly and offers good (but not complete) documentation on various usage scenarios (e.g. lcd connections, wifi modules). The tools provided have some glitches as I haven’t managed yet to recompile successfully the flash image using Axis SDK, even if I use the provided config file.

Anyway this board seems to be the best choise for starters on embedded systems considering both price and capabilities. If only Atmel’s NGW100 had build in USB support…