[Tinyos-help] sendDone() called before receive

Bibudh Lahiri bibudh at gmail.com
Mon Apr 2 08:52:34 PDT 2007


Hi Faisal,
   If u want to measure the transmission delay, how can u do it by noting
the time of transmission and reception from the sender and the receiver
respectively, until their clocks are synchronised to each other? Have u
already taken care of this synchronisation?

  One scheme I can suggest for measuring the end-to-end delay (round-trip)
is, once the message reaches the destination from the src by the multi-hop
path, send some kind of reply/ACK message all the way back to the sender,
following the same route. Notice the time when this reply/ACK reaches the
original src, and take the time difference with the time the message was
sent out from this sender, divide it by 2.

   My approach may sound too naive, let's see if someone else comes up with
some better idea.

        Bibudh

Bibudh Lahiri
Graduate Research Assistant
Department of Electrical and Computer Engineering
Iowa State University
http://www.ece.iastate.edu/~bibudh/



On 4/2/07, Faisal Karim <shaikh_fk at yahoo.com> wrote:
>
>  Thanks for replies.
> I got the idea, but still at one hop the behavior should be like once the
> source send one packet sendDone shd be called after that receiver's
> recieve() method.
>
> Actually im trying to calculate the delay between transmission and
> reception. I have put DBG statement in src's sendDone() and DBG statement in
> receiver's recieve() method. When i try simulation of two nodes always DBG
> of receiver invokes first than src's DBG. if someone knows some method to
> calculate delay than it will be more than good.
>
> Regards
> Shaikh, Faisal Karim
>
>
>
>
>  ------------------------------
>
> Message: 5
> Date: Sun, 1 Apr 2007 20:58:56 -0700
> From: Philip Levis <pal at cs.stanford.edu>
> Subject: Re: [Tinyos-help] sendDone() called before receive
> To: Thang Le <nt7272 at yahoo.com>
> Cc: tinyos-help at millennium.berkeley.edu
> Message-ID: <0A42FB18-EDC8-46C3-9CAD-FE83BCD4B65A at cs.stanford.edu>
> Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed
>
> On Apr 1, 2007, at 7:02 PM, Thang Le wrote:
>
> >   From my understanding, in TinyOS 1.1.15, SendDone is invoked when
> > the package is successfully queued at the sender. Even without any
> > receiver, SendDone is still called.
> >
>
> sendDone is signaled when the packet is transmitted. The error code
> denotes whether or not the transmission succeeded. Reasons for
> failure can include the radio being turned off mid-transmission,
> hardware failure, etc.
>
> You will never receive a sendDone before the packet is transmitted.
> That would release the packet buffer to the application, which is
> problematic.
>
> Note that since sendDone denotes a data-link (single-hop)
> transmission, it is signaled when the packet goes one hop, not the
> multihop frame within arrives at its destination.
>
> Phil
>
> ------------------------------
> Now that's room service! Choose from over 150,000 hotels
> in 45,000 destinations on Yahoo! Travel<http://travel.yahoo.com/hotelsearchpage;_ylc=X3oDMTFtaTIzNXVjBF9TAzk3NDA3NTg5BF9zAzI3MTk0ODEEcG9zAzIEc2VjA21haWx0YWdsaW5lBHNsawNxMS0wNw--%0A>to find your fit.
>
> _______________________________________________
> Tinyos-help mailing list
> Tinyos-help at Millennium.Berkeley.EDU
> https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.millennium.berkeley.edu/pipermail/tinyos-help/attachments/20070402/177bc06f/attachment.htm


More information about the Tinyos-help mailing list