PM9263-REAL-TIME-LINUX

From Ronetix
Jump to navigation Jump to search
Pm9263 top.png

Xenomai

Building kernel and xenomai

For Linux kernel 2.6.28.10

$ wget http://download.ronetix.at/boards/linux/kernel/2.6.28/linux-2.6.28.10.tar.bz2
$ wget http://download.ronetix.at/boards/linux/real_time/adeos-ipipe-2.6.28.10-arm-1.12-07.patch
$ wget http://download.ronetix.at/boards/linux/kernel/2.6.28/001_linux-2.6.28-at91.patch
$ wget http://download.ronetix.at/boards/linux/kernel/2.6.28/002_linux-2.6.28-exp.patch
$ wget http://download.ronetix.at/boards/linux/kernel/2.6.28/003_linux-2.6.28-at91-ronetix-20112009.patch 
$ wget http://download.ronetix.at/boards/linux/real_time/xenomai/xenomai-2.5.4.tar.bz2
$ tar xjf linux-2.6.28.10.tar.bz2
$ cd linux-2.6.28.10
$ patch -p1 < ../adeos-ipipe-2.6.28.10-arm-1.12-07.patch
$ patch -p1 < ../linux-2.6.28-at91.patch.bz2
$ patch -p1 < ../linux-2.6.28-exp.patch.bz2
$ patch -p1 < ../003_linux-2.6.28-at91-ronetix-20112009.patch
$ cd ..
$ tar xjf xenomai-2.5.4.tar.bz2
$ cd xenomai-2.5.4
$ scripts/prepare-kernel.sh --arch=arm --linux=${PWD}/../linux-2.6.28.10
$ cd ../linux-2.6.28.10
$ export ARCH=arm
$ export CROSS_COMPILE=/usr/cross/arm-linux-4.3.3/bin/arm-linux-
$ make pm9263_defconfig
$ make uImage
$ cd xenomai-2.5.4
$ ./configure --build=i686-pc-linux-gnu --host=arm-linux --enable-arm-mach=at91sam926x --enable-arm-tsc
$ make DESTDIR=${PWD}/staging_dir install # !!!Note: don't give correct root password in order not to populate /dev 

Programming/Writing

After successful building the file for programming/writing is uImage. On how to program it see the README for programming.

Installing Xenomai

Transfer the xenomai-2.5.4/staging_dir/usr/xenomai to /usr on the target rootfs.

Make Xenomai as part of the jffs2 rootfs image

See README-linux_kernel.ronetix.

Through network with tftp-hpa

On build computer:

$ tar czf xenomai.tar.gz staging_dir/usr/xenomai --exclude=xenomai/include --exclude=xenomai/share/doc --exclude=xenomai/share/man

On host computer(target):

# tftp <dns or /etc/hosts tftp server name> -c get /path/to/xenamai.tar.gz ~/xenamai.tar.gz
# gunzip xenamai.tar.gz
# tar xf xenamai.tar -C /usr