HowTo build qemu emulator for beagleboard and run the GsoC rtems on beagleboard project on it...

Claas Ziemke der_stuttgarter_25 at hotmail.de
Fri Jun 29 13:02:32 UTC 2012


hi everybody,

as some of you already know i am currently working on the BeagleBoard BSP.

as for now RTEMS boots succesfully and the printk routine is working.

if anyone wants to replicate my setup here is a short guide on how to do that,
prequesite is a working arm-rtemseabi4.11 toolchain:

1. clone and build qemu-maemo:

git clone git://gitorious.org/qemu-maemo/qemu.git 
cd qemu
./configure --target-list="arm-softmmu"
make

(thx for the great work to the maemo/meego team!)

2. clone and build rtems from my fork: 

git clone git://github.com/claas/rtems.git
git checkout beagle
mkdir rtems-b
cd rtems
./bootstrap
cd ../rtems-b
../rtems/configure --target=arm-rtemseabi4.11 --disable-posix --disable-networking --disable-cxx --enable-rtems-debug --enable-rtemsbsp=beagle_mzx --prefix=PUT_YOUR_PREFIX_HERE
make
make install

3. clone my tools repository:

git clone git://github.com/claas/tools.git

4. build the hello_world example ( change the use of printf to printk, printf is not working as for now)

5. download the x-loader and uboot images from: http://qemu-omap3.googlecode.com/files/image-v0.01.tar.bz2

6. build the nand flash image, the script to do that is in the tools repo, the name is: build_nand.sh

./build_nand.sh NAME_OF_YOUR_EXECUTABLE OUTPUT_NAND_IMAGE
( you need to adapt the scrupt to your filesystem layout, sorry i was too lazy to make the scripts more general
yes, i will do that in the future)

7. boot up qemu: 
qemu-system-arm -M beagle -mtdblock OUTPUT_NAND_IMAGE -serial stdio (add -s -S if you want to use gdb)

when the uboot promt shows up enter: 
nand read 0x80800000 0x280000 0x400000
bootm 0x80800000

the magic numbers are as follows: 0x80800000 destination location to load the kernelimage, 0x28000 location of the
kernel image on the nand, 0x400000 size of data to load, this number certainly is too big, but it works for me...

you are done and should see a couple of "Hello world!" lines, congratulations!

you can check out the other helper scripts and files in the tools directory too...

I had to comment out a assertion in cpukit/libfs/src/imfs/imfs_readlink.c if anyone can tell me why and how i can revert
that, thank you in advance...

if you have any question or suggestions on how to improve this guide or the scripts or the build commands, let me know!
as always, feedback is appreciated!

and also please tell me where i should put this guide in the rtems wiki.

thank you and have fun trying it out...

greetz,

claas ziemke 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/devel/attachments/20120629/f40507b1/attachment.html>


More information about the devel mailing list