addenda...In v1.x, if you have enableAck()ed, sendDone() will wait for
the ACK or timeout and set the msgptr->ack phantom-phield to TRUE or
FALSE as appropriate. I assume it's the same in 2.x...
MS

Philip Levis wrote:
On Jul 16, 2006, at 2:57 PM, Avinash Sridharan wrote:

Hi All,
I had a question on the return value of the send interface. The signal sendDone (called after the send command on the AMSend is called) returns an error value. The error value is SUCCESS when the packet is sent on the air. It returns a failure if the stack was not able to transmit the packet (even after multiple backoffs).

My question is that whenever a packet is sent the stack waits for the ACK before signalling a SUCCESS. If the ACK is not received received than does it return a FAILURE or since the packet has been successfully sent after a certain period of time it just returns SUCCESS ?


The error_t on sendDone denotes sending, not reception success. There are situations when a stack can accept a send but then not be able to service it (e.g., you turn off the radio before it can send). In these situations, it signals sendDone with a FAIL.

You can request and check for packet acknowledgments with the PacketAcknowledgments interface.

Phil

_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to