non periodic and blocking

Hi,

I'm working with Leopold in the networked application already mentioned, and I'd like to have a thing clarified. It's about the non periodic tasks and blocking functions (like the network related ones).

At first, I thought that I should implement the task so that it called recv (or recvfrom) and blocked waiting for anything that arrived, like we did with other unix applications. However some things I've read suggest that the updateHook() shouldn't block, by means of a timeout or whatever. Is this correct? And, in case it is, why is this suggested? Isn't the task going to expend more resources with an active poll like this? And what would happen if done the blocking way?

I think that my confusion comes because I don't really understand how non periodic tasks work. When is the updateHook of a non periodic task called? Which events do trigger it?

Thanks in advance.

Greetings,
Miguel.