From 315f1769b096f0db0bc4f99e89b9f153297b1ff5 Mon Sep 17 00:00:00 2001 From: scipio Date: Thu, 1 May 2008 20:18:50 +0000 Subject: [PATCH] Incorporate net2 comments. --- doc/html/tep119.html | 47 ++++++++++++++++++++++++++++++++--------- doc/txt/tep119.txt | 50 +++++++++++++++++++++++++++++++++++--------- 2 files changed, 77 insertions(+), 20 deletions(-) diff --git a/doc/html/tep119.html b/doc/html/tep119.html index 18106574..caa09e70 100644 --- a/doc/html/tep119.html +++ b/doc/html/tep119.html @@ -374,12 +374,11 @@ there is only one collection infrastructure, i.e., all roots in this set active at the same time are part of the same infrastructure.

A node is configured to become a root by using the RootControl interface. RootControl.setRoot() MUST make the current node a root of -the the collection infrastructure. RootControl.unsetRoot() MUST -make the current root no longer a root in the collection infrastructure. -Both calls are idempotent. -RootControl.setRoot() MAY be called on a node that is already a root, to -no effect. RootControl.unsetRoot() MAY be called on a node that is -not a root:

+the collection infrastructure. RootControl.unsetRoot() MUST make +the current root no longer a root in the collection infrastructure. +Both calls are idempotent. RootControl.setRoot() MAY be called on a +node that is already a root, to no effect. RootControl.unsetRoot() MAY +be called on a node that is not a root:

 interface RootControl {
   command error_t setRoot();
@@ -387,6 +386,10 @@ interface RootControl {
   command bool isRoot();
 }
 
+

Both commands MUST return SUCCESS if the node is now in the specified +state, and FAIL otherwise. For example, if a node is already a root +and an application calls RootControl.setRoot(), the call will +return SUCCESS.

The collection infrastructure can be multiplexed among independent applications, by means of a collection identifier. It is important to note that the data traffic in the protocol is multiplexed, @@ -404,9 +407,22 @@ snoopers use the Receive interface [1] to r message. The collection identifier is specified as a parameter to Receive during instantiation.

The nodes can process a packet that are in transit. These in-network -processors use the Intercept interface [1] to receive and update -a packet. The collection identifier is specified as a parameter -to Intercept during instantiation.

+processors use the Intercept interface to receive +and update a packet. The collection identifier is specified as a parameter +to Intercept during instantiation. The Intercept interface has this +signature:

+
+interface Intercept {
+  event bool forward(message_t* msg, void* payload, uint8_t len);
+}
+
+

Intercept has a single event, Intercept.forward(). A collection +service SHOULD signal this event when it receives a packet to forward. +If the return value of the event is FALSE, then the collection layer +MUST NOT forward the packet. This interface allows a higher layer +to inspect the internals of a packet and possibly suppress it if +it is unnecessary or if its contents can be aggregated into an +existing packet.

3 Collection Services

@@ -480,7 +496,7 @@ based on its collection ID and contents.

4 Implementation

An implementation of this TEP can be found in -tinyos-2.x/tos/lib/net/ctp and tinyos-2.x/tos/lib/net/le, in +tinyos-2.x/tos/lib/net/ctp and tinyos-2.x/tos/lib/net/4bitle, in the CTP protocol. It is beyond the scope of this document to fully describe CTP, but we outline its main components. CTP will be described in an upcoming TEP [2]. This implementation is a @@ -659,6 +675,17 @@ QEntryPool

+

4.4 MultihopLqi

+

There is another implementation of collection in tos/lib/net/lqi. +Its software structure is similar, with the exception that it does +not have a separate link estimator. MultihopLqi only works on +platforms that have a CC2420 radio, as it uses a special piece +of physical layer data the radio provides (the LQI value). +The three major components of the MultihopLqi implementation +are the modules LqiForwardingEngineP and LqiRoutingEngineP, as +well as the configuration MultihopLqiP.

+
+

5. Author Addresses

Rodrigo Fonseca
diff --git a/doc/txt/tep119.txt b/doc/txt/tep119.txt index 1fda21c1..9c3262f6 100644 --- a/doc/txt/tep119.txt +++ b/doc/txt/tep119.txt @@ -93,12 +93,11 @@ set active at the same time are part of the same infrastructure. A node is configured to become a root by using the RootControl interface. RootControl.setRoot() MUST make the current node a root of -the the collection infrastructure. RootControl.unsetRoot() MUST -make the current root no longer a root in the collection infrastructure. -Both calls are idempotent. -RootControl.setRoot() MAY be called on a node that is already a root, to -no effect. RootControl.unsetRoot() MAY be called on a node that is -not a root:: +the collection infrastructure. RootControl.unsetRoot() MUST make +the current root no longer a root in the collection infrastructure. +Both calls are idempotent. RootControl.setRoot() MAY be called on a +node that is already a root, to no effect. RootControl.unsetRoot() MAY +be called on a node that is not a root:: interface RootControl { command error_t setRoot(); @@ -106,6 +105,11 @@ not a root:: command bool isRoot(); } +Both commands MUST return SUCCESS if the node is now in the specified +state, and FAIL otherwise. For example, if a node is already a root +and an application calls RootControl.setRoot(), the call will +return SUCCESS. + The collection infrastructure can be multiplexed among independent applications, by means of a *collection identifier*. It is important to note that the *data* traffic in the protocol is multiplexed, @@ -127,9 +131,23 @@ message. The collection identifier is specified as a parameter to Receive during instantiation. The nodes can process a packet that are in transit. These in-network -*processors* use the Intercept interface [1_] to receive and update -a packet. The collection identifier is specified as a parameter -to Intercept during instantiation. +*processors* use the Intercept interface to receive +and update a packet. The collection identifier is specified as a parameter +to Intercept during instantiation. The Intercept interface has this +signature:: + + interface Intercept { + event bool forward(message_t* msg, void* payload, uint8_t len); + } + +Intercept has a single event, Intercept.forward(). A collection +service SHOULD signal this event when it receives a packet to forward. +If the return value of the event is FALSE, then the collection layer +MUST NOT forward the packet. This interface allows a higher layer +to inspect the internals of a packet and possibly suppress it if +it is unnecessary or if its contents can be aggregated into an +existing packet. + 3 Collection Services ==================================================================== @@ -214,7 +232,7 @@ based on its collection ID and contents. ==================================================================== An implementation of this TEP can be found in -``tinyos-2.x/tos/lib/net/ctp`` and ``tinyos-2.x/tos/lib/net/le``, in +``tinyos-2.x/tos/lib/net/ctp`` and ``tinyos-2.x/tos/lib/net/4bitle``, in the CTP protocol. It is beyond the scope of this document to fully describe CTP, but we outline its main components. CTP will be described in an upcoming TEP [2_]. This implementation is a @@ -401,6 +419,18 @@ broken up into a few groups of functionality: QEntryPool * Packet timing: Random, RetxmitTimer +4.4 MultihopLqi +==================================================================== + +There is another implementation of collection in ``tos/lib/net/lqi``. +Its software structure is similar, with the exception that it does +not have a separate link estimator. MultihopLqi only works on +platforms that have a CC2420 radio, as it uses a special piece +of physical layer data the radio provides (the LQI value). +The three major components of the MultihopLqi implementation +are the modules LqiForwardingEngineP and LqiRoutingEngineP, as +well as the configuration MultihopLqiP. + 5. Author Addresses ==================================================================== -- 2.39.2