UDP From RTAI

PL Fnhng pinklo223 at gmail.com
Tue Aug 1 04:02:32 CEST 2006


Hi Paolo,

Would you mind explain how to set up a proxy to support usage of Linux
sockets & data exchange using RTAI in details?

I used RTNet on Linux 2.4.32 with RTAI to develop UDP streamer,
which succeeds to send the UDP packets with 500 microseconds period.

In this project, two programs are developed and executed simultaneously.

(1)  Using while-loop to write the data, which reads from file, to RTAI scb
(shared circular buffer),

(2)  UDP streamer reads the data from the scb and then send out the UDP
packet via RTnet API in hard real-time

After executing few times of these two programs, the whole system hangs.

Any suggest to fix this problem?

Thanks
pinklo



On 7/31/06, Paolo Mantegazza <mantegazza at aero.polimi.it> wrote:
>
> Kate Alhola wrote:
> > I need to send and receive UDP datagrams from RTAI, not
> > so hard RT, 1ms period is enough and no other remarkable traffic in
> > network in same time.
> >
> > I first checked RTnet but my interest ended when i read
> > that it is depending about HW specific drivers. I anyhow
> > need to be able run with any network card.
> >
> > So, at the moment one viable alternative looks a like
> > to just ssend IP/UDP packets using normal Linux kernel
> > internal API.
> >
> > Anyhow, i just dont like to re-invent wheel and i think that
> > i am not first one that likes to send UDP from RTAI with
> > standard network card and without need so hard realtime
> > that RTnet provides but still much more realtime than
> > usermode provides.
> >
> > Using the RTnet is possibe if there is some way to use
> > it without card specific HW driver but i did not find
> > such a way. May be loob-back RT-net driver and RT-mac
> > routing packets tolinux stack would work but i did not
> > quickly find mention about loopback driver.
> >
>
> You can use standard Linux sockets but, if the task is hard real time
> for RTA, that will send the task to soft mode, recovering hard real time
> at the return from the Linux service. SO for that you shoul set up a
> proxy to support Linux sockets usage, exchanging data with it by using
> any RTAI communication API.
>
> Paolo.
>
>
> _______________________________________________
> RTAI mailing list
> RTAI at rtai.org
> https://mail.rtai.org/cgi-bin/mailman/listinfo/rtai
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.rtai.org/pipermail/rtai/attachments/20060801/8ef237f5/attachment.htm 


More information about the Rtai mailing list