GP32 Rtems For Gp32


loki666

rtems gp32 bsp maintainer
Joined
Dec 27, 2003
Messages
288
Age
44
Location
Belgium
Website
loki666-gp32.blogspot.com
Hi all,

i've been working for a time now on gp32 bsp for rtems... and it's running great :)
so, first things first, what's rtems?
rtems is a very small (<70ko) executive RTOS, which means each rtems-application is linked with the rtems-os. which means rtems is not a multi-process OS, but still a full multi-tasking OS (you can't run 2 program, but the running program can run multiple threads).
and finally, rtems is a full arm toolchain ready to build .gxb.
for a complete description of features go check RTEMS web site.

What are the benefits:
- a full os with s/w timers, semaphore, threads, events, etc...
- easy port from linux to rtems (there is some ready-to-build library like zlib,tcl,readline,ncurses,...)
- you can control ISR with rtems
- c/cpp toolchain

the withdraws:
- still no smc write support (you can read files on smc... but cant write back yet)

So how to start:
1) go grab arm-rtems rpm...
ftp://ftp.rtems.com/pub/rtems/linux/redha...13.0-2.i686.rpm
ftp://ftp.rtems.com/pub/rtems/linux/redha...13.0-2.i686.rpm
ftp://ftp.rtems.com/pub/rtems/linux/redha...2.16-1.i686.rpm
ftp://ftp.rtems.com/pub/rtems/linux/redha...59-3.noarch.rpm
ftp://ftp.rtems.com/pub/rtems/linux/redha....5-2.noarch.rpm
install all of them... (will be installed in /opt/rtems-4.7)
2) grab rtems cvs
Code:
#cvs -d :pserver:anoncvs@www.rtems.com:/usr1/CVS login
(type enter)
#cvs -d :pserver:anoncvs@www.rtems.com:/usr1/CVS -z 9 co -P rtems
3) configure, compile and install rtems
Code:
#su
#export PATH=/opt/rtems-4.7/bin:$PATH
#cd /path/to/rtems
#./bootstrap -c
#./bootstrap
#cd /tmp
#mkdir b-rtems
#cd b-rtems
#/path/to/rtems/configure --target=arm-rtems4.7 --enable-posix \
--disable-networking --enable-cxx --disable-itron \
--enable-rtemsbsp=gp32 --prefix=/opt/rtems-4.7
#make all install

and you are done.
there should be some .gxb in b-rtems tree (use #find -name ".gxb") that you can test on you gp32.
If you need some samples, you can check testsuite directory, and there is some Makefile templates in /path/to/rtems/make/Templates

If you are intersted with this, you can ask questions here.
 
Hi all,

i've been working for a time now on gp32 bsp for rtems... and it's running great :)
so, first things first, what's rtems?
rtems is a very small (<70ko) executive RTOS, which means each rtems-application is linked with the rtems-os. which means rtems is not a multi-process OS, but still a full multi-tasking OS (you can't run 2 program, but the running program can run multiple threads).
and finally, rtems is a full arm toolchain ready to build .gxb.
for a complete description of features go check RTEMS web site.

What are the benefits:
- a full os with s/w timers, semaphore, threads, events, etc...
- easy port from linux to rtems (there is some ready-to-build library like zlib,tcl,readline,ncurses,...)
- you can control ISR with rtems
- c/cpp toolchain

the withdraws:
- still no smc support (you cant read files on smc... there is a way to mount an in-memory fs thought)

So how to start:
1) go grab arm-rtems rpm...
ftp://ftp.rtems.com/pub/rtems/linux/redha...13.0-2.i686.rpm
ftp://ftp.rtems.com/pub/rtems/linux/redha...13.0-2.i686.rpm
ftp://ftp.rtems.com/pub/rtems/linux/redha...2.16-1.i686.rpm
ftp://ftp.rtems.com/pub/rtems/linux/redha...59-3.noarch.rpm
ftp://ftp.rtems.com/pub/rtems/linux/redha....5-2.noarch.rpm
install all of them... (will be installed in /opt/rtems-4.7)
2) grab rtems cvs
Code:
#cvs -d :pserver:anoncvs@www.rtems.com:/usr1/CVS login
(type enter)
#cvs -d :pserver:anoncvs@www.rtems.com:/usr1/CVS -z 9 co -P rtems
3) configure, compile and install rtems
Code:
#su
#export PATH=/opt/rtems-4.7/bin:$PATH
#cd /path/to/rtems
#./bootstrap -c
#./bootstrap
#cd /tmp
#mkdir b-rtems
#cd b-rtems
#/path/to/rtems/configure --target=arm-rtems4.7 --enable-posix \
--disable-networking --enable-cxx --disable-itron \
--enable-rtemsbsp=gp32 --prefix=/opt/rtems-4.7
#make all install

and you are done.
there should be some .gxb in b-rtems tree (use #find -name ".gxb") that you can test on you gp32.
If you need some samples, you can check testsuite directory, and there is some Makefile templates in /path/to/rtems/make/Templates

If you are intersted with this, you can ask questions here.

Diddent you miss some headers ?
lcd.c looks like copy&paste, but the header is missing. Please c&p the complete file in the future.
Thanx...
 
Last edited by a moderator:
Is somebody able to get a compressed snapshot of everything that is needed, and make it available for download (hopefully evildragon can add it to gp32x.de) -

I don't have an RPM manager, CVS or linux :(
 
hmm not sure if that is possible.... if you don't have linux you could try cygwin, there are packages on the rtems FTP for that. Cygwin also has CVS although you could use any CVS tool for windows. If you're interested here is a link to my build of rtems for gp32 - containing the example gxbs built following this guide...

http://l33t.spod.org/ratx/gp32/mirrors/rtems-gp32.tar.gz
 
no,no i didnt forget headers...

prototype for lcd.c are in bsp.h

No, i mean something different ...

The functions you are using in this file lcd.c, look very common to me, couse you copy & paste them from my mirko SDK. But you removed the GPL header, and the Name of the author(me).

Diddent you think, if you use 3rd party code, the smallest thing you can do, is to credit the orginal author ?
Free software can only work, if everyone is respecting others work.
 
Last edited by a moderator:
no,no i didnt forget headers...

prototype for lcd.c are in bsp.h

No, i mean something different ...

The functions you are using in this file lcd.c, look very common to me, couse you copy & paste them from my mirko SDK. But you removed the GPL header, and the Name of the author(me).

Diddent you think, if you use 3rd party code, the smallest thing you can do, is to credit the orginal author ?
Free software can only work, if everyone is respecting others work.

i'll fix this
 
Last edited by a moderator:
no,no i didnt forget headers...

prototype for lcd.c are in bsp.h

No, i mean something different ...

The functions you are using in this file lcd.c, look very common to me, couse you copy & paste them from my mirko SDK. But you removed the GPL header, and the Name of the author(me).

Diddent you think, if you use 3rd party code, the smallest thing you can do, is to credit the orginal author ?
Free software can only work, if everyone is respecting others work.

i'll fix this

nice, :) thanx ...
 
Last edited by a moderator:
That is absolutely awesome! I looked at doing this some time ago, but it was beyond me.

This goes a long way to make GPDesktop what I want it to be :) (www.gp32.co.nz/gpdesktop.php). I'm trying it soon!

Is it possible to get a precompiled version that I can use?
mmmh... I'm not sure rtems is what you are looking for... (in fact what you are trying to do allready exists... linux+x11, but its too much for a gp32)
as I said, rtems doesnt allow to run more than one program at the same time. rtems allows a program to have multiple threads, which is different. I know... in a way, each program could be seen as one or more related threads.
But, even if I do know that dynamic link is possible with rtems, I never had the opportunity to test it, because a program can't read data (or programs/lib) from the smc.
I'm working on this, but it's not as small work because rtems miss some api to handle block devices... so don't expect result soon
 
Last edited by a moderator:
no,no i didnt forget headers...

prototype for lcd.c are in bsp.h

No, i mean something different ...

The functions you are using in this file lcd.c, look very common to me, couse you copy & paste them from my mirko SDK. But you removed the GPL header, and the Name of the author(me).

Diddent you think, if you use 3rd party code, the smallest thing you can do, is to credit the orginal author ?
Free software can only work, if everyone is respecting others work.

i'll fix this

Nothing happens in the last week...
Checked cvs branch this day ... :(
 
Last edited by a moderator:
no,no i didnt forget headers...

prototype for lcd.c are in bsp.h

No, i mean something different ...

The functions you are using in this file lcd.c, look very common to me, couse you copy & paste them from my mirko SDK. But you removed the GPL header, and the Name of the author(me).

Diddent you think, if you use 3rd party code, the smallest thing you can do, is to credit the orginal author ?
Free software can only work, if everyone is respecting others work.

i'll fix this

Nothing happens in the last week...
Checked cvs branch this day ... :(
I said "I'll fix this"... I dont have write access to cvs, so I send patch by emails...
I'm working on the bsp src, your file is allready fixed in my tree, but I still dont have submited the patch...
com'on I said "I'll fix" ... "I'll fix", I swear I'm not going to steal your work and take credits of it.
 
Last edited by a moderator:
pea posted on Jul 26 2005 at 10:05 PM said:
Has anyone got any instructions on using it in a windows based environment yet :D :)

It can be done but it's a pig to build (under CygWin), I'll see if I can edit up one of my old build scripts to show how it's done.

Switched to using the RTEMS targeted GCC on my SuSE box now as that was a doddle to setup.
 
Last edited by a moderator:
Back
Top