rtems on beagleboard on qemu howto 2.0

Joel Sherrill Joel.Sherrill at OARcorp.com
Sat Aug 18 14:22:24 UTC 2012


Hi

I am on travel for the next week (starting today) and will try to look at this but let me 
throw a couple of things to get started:

+ BSP needs an RTEMS wiki page and the Howto should be there. Please document
   the qemu version you have had luck with. Tomorrow it may be broken.
+ Run the check_submission script on your code. It is in rtems-testing/merge_helpers.
    It is far from perfect but will catch a lot of obvious things.
+ Add a script to rtems-testing/sim-scripts that runs qemu on this BSP. There are
    plenty of qemu examples. If you need a ROM image file not included in qemu, 
    it can go in the qemu-support with documentation on origin, etc
+ If you duplicated code, now is the time to make sure you resolve that OR at least
   make sure it is documented in the BSP Status that it needs addressing and why.

That should help the polishing part of it and leave the reviewers to focus on code.

--joel
________________________________________
From: rtems-devel-bounces at rtems.org [rtems-devel-bounces at rtems.org] On Behalf Of Claas Ziemke [der_stuttgarter_25 at hotmail.de]
Sent: Saturday, August 18, 2012 8:45 AM
To: rtems-devel at rtems.org
Subject: rtems on beagleboard on qemu howto 2.0

hi everybody,

i just filed a pull request for the work i did so far...

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
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 --prefix=PUT_YOUR_PREFIX_HERE
make
make install

3. clone my tools repository:

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

find the test.c file in the cloned repository and copy it to the examples hello/hello_world_c folder

4. build the hello_world example

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 script 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, 0x280000 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 magic lines, they are debug output for my ongoing efforts to make
the ticker and the rtc work...

so u are done... 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




More information about the devel mailing list