[Tinyos-help] RE: [Tinyos-devel] CTP + LPL

David Moss dmm at rincon.com
Thu Feb 7 06:00:31 PST 2008


Matt and Phil - 

This is meant to serve only as a private interface within the CC2420 stack
right now, not an interface provided by the ActiveMessage façade.  After
all, once the interface is provided by ActiveMessage, it is no longer a
private CC2420-specific interface.

This is absolutely not a CTP or MultiHop protocol changing interface, since
that would make those libraries platform dependent, which is bad.  This is
also not an LPL interface. Rather, the point of this interface is to simply
signal an event at the top of the stack that says the radio is sending a
message. Your application can do what it wants with that event.
 
For developers who want CTP + LPL on a CC2420 platform, this single
notification event gives them the ability to make it happen *right now*
without modifying any libraries.  No modifications to CTP, no modifications
to LPL, no modifications to the radio stack, and nearly 0 cost. 

You're correct: we should document this interface in the CC2420 TEP, or add
this to some other TEP to standardize it across radio stacks.  A second
direction would be to continue adding onto the LowPowerListening interface
to make each outbound message use your local LPL settings, but I would be
hesitant to make those kinds of changes without a lot of backing.

-David




-----Original Message-----
From: Matt Welsh [mailto:mdwelsh231 at gmail.com] On Behalf Of Matt Welsh
Sent: Wednesday, February 06, 2008 3:10 PM
To: David Moss
Cc: 'TinyOS Development'; 'tinyos-help at Millennium.Berkeley.EDU list'
Subject: Re: [Tinyos-devel] CTP + LPL

While I like this idea, are we going through a TEP vetting process  
before adding new calls in the radio stack interface? I could think of  
a lot of things that one might want to add to the CC2420 radio stack  
but I thought the idea of the TEP process was to air these ideas  
through feature extension proposals before just adding things when  
they seem like a good idea. Then again maybe we need to draw a  
distinction between "public" interfaces and "private" ones; I suppose  
one could consider the internals of the CC2420 stack to be "private"  
-- that is until any upper level code starts relying on the existence  
of this interface and makes it impossible to port to other radio stacks.




On Feb 5, 2008, at 8:26 AM, David Moss wrote:

> I just added a hook to the CC2420 radio stack in CVS to configure an  
> outbound message. The interface is called SendNotifier, and has a  
> single event:
>
>   event void aboutToSend(am_addr_t addr, message_t *msg);
>
> This event is provided by CC2420ActiveMessageC, and is parameterized  
> by am_id_t.
>
> You can access this interface to configure packets sent by any  
> module in your application, modifying the outbound packet based on  
> AM type, destination, etc.  The main intention is CTP + LPL  
> integration (with examples attached – modify as necessary), but you  
> can use it to add all sorts of system-wide functionality to your  
> application.  Here’s a small example:
>
>   event void SendNotifier.aboutToSend[AM_CTP_DATA](am_addr_t addr,  
> message_t *msg) {
>     call LowPowerListening.setRxSleepInterval(msg, 512);
>   }
>
> Simply create a module that defines an LPL policy for your system,  
> and use the SendNotifier interface to enforce it.
>
> If this hook works out, we can extend this to other radio stacks as  
> necessary.
>
> -David
>
>
> <CtpLplC.nc><CtpLplP.nc>
> _______________________________________________
> Tinyos-devel mailing list
> Tinyos-devel at millennium.berkeley.edu
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-devel






More information about the Tinyos-help mailing list