Hi!

On Mon, 12 Jan 2009, lei lu wrote:

> Hi there,
>
> I am a little confused about sending or receiving a packet by using
> component DefaultLpl. My question is can this component be used to send and
> receive a packet?

The DefaultLplC/P (and also PowerCycleC/P) are involved in implementing 
the LPL but you don't have to wire directly to them in order to use the 
LPL.

> Because when I try to understand example TestLpl in /apps/tests/TestLpl, 
> it seems that it uses ActiveMessageC to send or receive packet.

The DefaultLplC is wired to the SplitControl in CC2420ActiveMessageC from 
lib/cc2420 and then the ActiveMessageC is equated to CC2420ActiveMessageC 
in platforms/telosa.

> In that example, interface LowPowerListening is just responsible for
> starting and stopping Radio periodically.

This is a little incorrect. The starting and stopping of the duty-cycling is 
done using the SplitInterface from the ActiveMessageC. What the 
LowPowerListening interface allows is adjusting the sleep intervals (or 
duty-cycle) for probing and sending. The probing is a global setting while 
the sending is per-packet.

> But when I read the source code of DefaultLpl and PowerCycle, I found 
> that it does provide send and receive interface and implement these two 
> interface. So will it be possible to use these functions be used? Anyone 
> tried that before?

The Send and Receive you see there are stacked together with the other 
components from the cc2420. Here is a diagram of how the send path looks 
like:

        CC2420ActiveMessageC
          |
        CC2420ActiveMessageP
          |
        UniqueSendC
          |
        PacketLinkC
          |
        DefaultLplC/DummyLplC
          |
        CC2420TinyOSNetwork
          |
        CsmaC
          |
        CsmaP

And the receive path looks like this:

        CC2420ActiveMessageC
          |
        CC2420ActiveMessageP
          |
        DefaultLplC/DummyLplC
          |
        UniqueReceiveC
          |
        CC2420TinyOSNetwork
          |
        CsmaC
          |
        CsmaP

> Please enlighten me. I will really appreciate your help.

Let me know if what I said above doesn't clarify the things.

All the best!
Razvan ME
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to