Rtems Socket Options

Eric Norum eric at cls.usask.ca
Thu Jun 22 17:22:25 UTC 2000


gene at smith.as wrote:
> 
> What restrictions does being "in the context of the network" task impose?
> According to the networking manual, you just can't call networking functions
> but you can make other rtems calls such as sending an event to a task. Can you
> access your global or static variables from within the callback function?

Yes, the big restriction is that you can't call the `application-level'
networking functions (e.g. send, recv, read, write, etc.).  Also, the
callback function is called from a context which holds the network
semaphore, so no other network-related tasks can run while the callback
function is active -- don't do any really long/slow operations within
the callback.  Sending an event to a task, releasing a semaphore,
sending a non-blocking message are all fine.  All global and file-static
variables are accessable.  Variables which have been added to a tasks
private set (rtems_task_variable_add) will *not* be accessable.

-- 
Eric Norum                                 eric at cls.usask.ca
Canadian Light Source                      Phone: (306) 966-6308
University of Saskatchewan                 FAX:   (306) 966-6058
Saskatoon, Canada.



More information about the users mailing list