In TinyOS the tasks are run to completion. Within the network stack there is a number of tasks internally: computing the CRC, performing SEC_DED encoding, etc. None of these tasks will actually run until the current task is finished, and this is the behavior you're seeing. You can produce a delay by either - implementing a better CLOCk component which will allow you to schedule timeouts - creating a delay task, and repeatedly scheduling it for the desired time
Rob ----- Original Message ----- From: "sarah bergbreiter" <[EMAIL PROTECTED]> Date: Saturday, January 12, 2002 8:21 pm Subject: [tinyos-users@mm] sending messages from tasks > > Quick question here -- > > I'm sending a message from inside a task that looks like this > > TASK > -- blah > -- send message > -- delay > > However, it never sends the message until after the delay. I > thought that > it might put the send message command on a queue somewhere and > finish up the > current task first. If I make the delay another task, the same thing > happens though. I really don't have any idea what is going on > here. Please > help if you can, > > Sarah > >
