mantegazza at aero.polimi.it
Mon Nov 18 14:46:18 CET 2002
Jan Kiszka wrote:
> Alexander Eisenhuth schrieb:
> > Jan Kiszka wrote:
> >> Alexander Eisenhuth schrieb:
> >> > ...
> >>> RTNet
> >>> =====
> >>> I've read in the archive about RTNet. It sound exactly what I need,
> >>> but unfortunatly the chipset I'm using is not supported.
> >>> * Can anyone say something about the dependencies to the chipset ? At
> >>> a first look there seems to be no abstract approach to "soften" the
> >>> support of new Cards.
> >> If you only want soft real-time networking with a RTAI kernel API, you
> >> could use the RTnet-wrapper for net_rpc. It comes with current RTAI
> >> versions.
> > What priorities are raised in that case ? Can you loose a few words on
> > net_rpc ?
> I would say (without knowing everything in details) that no priorities
> are raised. All incoming and outgoing udp data is treated as any other
> linux tcp/udp/ip packets. That means everything happening in the
> RT-domain has higher priority than your udp packets - even if the
> rt-priority of that tasks are lower than you sender or receiver. And in
> linux, there is no change of priorities at all.
> About net_rpc: we haven't tried it for months here at the RTS (at the
> moment we do need it). If it already works with RTnet, you get a remote
> procedure call mechanism for most RTAI functions over ethernet. Maybe
> Paolo has already made some experiments with current RTnet and net_rpc...
Not yet, but will soon when we have finished a general tool we'll make
available. I assume no difficulty in that as I saw that RTNet supports
the following, and only functions used by net_rpc:
int rt_socket(int domain, int type, int protocol);
int rt_close(int sock);
int rt_bind(int sock, struct sockaddr *addr, int addrlen);
int rt_socket_callback(int sock, int (*func)(int sock, void *arg), void
int rt_sendto(int sock, const void *msg, int len, unsigned int sflags,
struct sockaddr *to, int tolen);
int rt_recvfrom(int sock, void *msg, int len, unsigned int flags, struct
sockaddr *from, int *fromlen);
with the following:
extern int rt_socket (int family, int type, int protocol);
extern int rt_socket_close (int fd);
extern int rt_socket_bind (int fd, struct sockaddr *my_addr, int
extern int rt_socket_callback (int fd, int (*func)(int,void *), void
extern int rt_socket_sendto (int fd, void *buf, int len, unsigned
int flags, struct sockaddr *to, int tolen);
extern int rt_socket_recvfrom (int fd, void *buf, int len, unsigned
int flags, struct sockaddr *from, int *fromlen);
through the following defines:
#define rt_bind rt_socket_bind
#define rt_close rt_socket_close
#define rt_sendto rt_socket_sendto
#define rt_recvfrom rt_socket_recvfrom.
Under a separate email I'm about to send a small tarball that shows
net_rpc at work with Dominic's code generator.
More information about the Rtai