All of lore.kernel.org
 help / color / mirror / Atom feed
* [Xenomai-help] Newbie Question  : Compile test programm
@ 2006-02-17 13:41 Roderik_Wildenburg
  2006-02-17 13:54 ` Philippe Gerum
  0 siblings, 1 reply; 2+ messages in thread
From: Roderik_Wildenburg @ 2006-02-17 13:41 UTC (permalink / raw)
  To: Xenomai-help

Dear Gurus,

I simply try to compile a straightforward Xenomai example for the vxWorks-skin like this :

--------------------------------------------------
#include <nucleus/thread.h>
#include <nucleus/xenomai.h>
#include <vxworks/vxworks.h>
#include <stdio.h>

int testtask (int a1, int a2,int a3,int a4,int a5,int a6,int a7,int a8,int a9,int a10)
{
   for(;;)
   {
      printf("Hello World\n");
      taskDelay(sysClkRateGet()*1);
   }
}

main(int argc, char **argv)
{
   int taskid;

   taskid=taskSpawn( "vxTestTask", 0, 0, 1000, testtask, 0,0,0,0,0,0,0,0,0,0);
   taskDelay(sysClkRateGet()*20);

}

--------------------------------------------------

Not very useful, but good enough as an example.

When I try to (cross-)compile (for PowerPC) this code with the following statement :

> ppc-linux-gcc -I ~/xenomai/_install/include test.c

(_install/include is the directory of the installed (make install) Xenomai header files.) I get the following errormessage (and much more):

In file included from ~/xenomai/_install/include/nucleus/xenomai.h:23,
                 from test.c:2:
~/xenomai/_install/include/xenomai/nucleus/pod.h:125: parse error before "xnthread_t"
~/xenomai/_install/include/xenomai/nucleus/pod.h:125: warning: no semicolon at end of struct or union
~/xenomai/_install/include/xenomai/nucleus/pod.h:127: warning: data definition has no type or storage class


I tried to find a simple example code for vxworks-skin, but I wasn´t succesfull (is there such a code at all and where ?). 
Could you please give me a hint, what I is wrong with my code, or where I can find some Xenomai examples (vxWorks-skin).

Thank you in advance 
Roderik



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Xenomai-help] Newbie Question  : Compile test programm
  2006-02-17 13:41 [Xenomai-help] Newbie Question : Compile test programm Roderik_Wildenburg
@ 2006-02-17 13:54 ` Philippe Gerum
  0 siblings, 0 replies; 2+ messages in thread
From: Philippe Gerum @ 2006-02-17 13:54 UTC (permalink / raw)
  To: Roderik_Wildenburg; +Cc: Xenomai-help

Roderik_Wildenburg@domain.hid wrote:
> Dear Gurus,
> 
> I simply try to compile a straightforward Xenomai example for the vxWorks-skin like this :
> 
> --------------------------------------------------
> #include <nucleus/thread.h>
> #include <nucleus/xenomai.h>
> #include <vxworks/vxworks.h>
> #include <stdio.h>
> 
> int testtask (int a1, int a2,int a3,int a4,int a5,int a6,int a7,int a8,int a9,int a10)
> {
>    for(;;)
>    {
>       printf("Hello World\n");
>       taskDelay(sysClkRateGet()*1);
>    }
> }
> 
> main(int argc, char **argv)
> {
>    int taskid;
> 
>    taskid=taskSpawn( "vxTestTask", 0, 0, 1000, testtask, 0,0,0,0,0,0,0,0,0,0);
>    taskDelay(sysClkRateGet()*20);
> 
> }
> 
> --------------------------------------------------
> 
> Not very useful, but good enough as an example.
> 
> When I try to (cross-)compile (for PowerPC) this code with the following statement :
> 
> 
>>ppc-linux-gcc -I ~/xenomai/_install/include test.c
> 
> 
> (_install/include is the directory of the installed (make install) Xenomai header files.) I get the following errormessage (and much more):
> 
> In file included from ~/xenomai/_install/include/nucleus/xenomai.h:23,
>                  from test.c:2:
> ~/xenomai/_install/include/xenomai/nucleus/pod.h:125: parse error before "xnthread_t"
> ~/xenomai/_install/include/xenomai/nucleus/pod.h:125: warning: no semicolon at end of struct or union
> ~/xenomai/_install/include/xenomai/nucleus/pod.h:127: warning: data definition has no type or storage class
> 
> 
> I tried to find a simple example code for vxworks-skin, but I wasn´t succesfull (is there such a code at all and where ?). 
> Could you please give me a hint, what I is wrong with my code, or where I can find some Xenomai examples (vxWorks-skin).
> 

Try ksrc/skins/vxworks/demos/

> Thank you in advance 
> Roderik
> 
> 
> _______________________________________________
> Xenomai-help mailing list
> Xenomai-help@domain.hid
> https://mail.gna.org/listinfo/xenomai-help
> 


-- 

Philippe.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-02-17 13:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-02-17 13:41 [Xenomai-help] Newbie Question : Compile test programm Roderik_Wildenburg
2006-02-17 13:54 ` Philippe Gerum

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.