[Tinyos-2-commits] CVS: tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME MLME_ASSOCIATE.nc, 1.1, 1.2 MLME_BEACON_NOTIFY.nc, 1.2, 1.3 MLME_COMM_STATUS.nc, 1.1, 1.2 MLME_DISASSOCIATE.nc, 1.1, 1.2 MLME_GET.nc, 1.2, 1.3 MLME_GTS.nc, 1.1, 1.2 MLME_ORPHAN.nc, 1.1, 1.2 MLME_POLL.nc, 1.1, 1.2 MLME_RESET.nc, 1.1, 1.2 MLME_RX_ENABLE.nc, 1.1, 1.2 MLME_SCAN.nc, 1.1, 1.2 MLME_SET.nc, 1.2, 1.3 MLME_START.nc, 1.1, 1.2 MLME_SYNC_LOSS.nc, 1.1, 1.2 MLME_SYNC.nc, 1.1, 1.2

Jan-Hinrich Hauer janhauer at users.sourceforge.net
Wed Mar 4 10:32:15 PST 2009


Update of /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME
In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv17605/tos/lib/mac/tkn154/interfaces/MLME

Modified Files:
	MLME_ASSOCIATE.nc MLME_BEACON_NOTIFY.nc MLME_COMM_STATUS.nc 
	MLME_DISASSOCIATE.nc MLME_GET.nc MLME_GTS.nc MLME_ORPHAN.nc 
	MLME_POLL.nc MLME_RESET.nc MLME_RX_ENABLE.nc MLME_SCAN.nc 
	MLME_SET.nc MLME_START.nc MLME_SYNC_LOSS.nc MLME_SYNC.nc 
Log Message:
- re-designed the radio driver interfaces, restructured/improved the CC2420 radio driver
- split the main MAC configuration (was TKN154P.nc) in two: one for beacon-enabled mode the other for nonbeacon-enabled mode (this decision has to be made at compile time now)
- added (serial) debugging functions (compile with "TKN154_DEBUG=1 make telosb" and use the java PrintfClient, see tinyos-2.x/apps/tests/TestPrintf/README.txt)
- improved readability, added comments 

Index: MLME_ASSOCIATE.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_ASSOCIATE.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_ASSOCIATE.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_ASSOCIATE.nc	4 Mar 2009 18:31:40 -0000	1.2
***************
*** 34,37 ****
--- 34,42 ----
   */
  
+ /** 
+  * MLME-SAP association primitives define how a device becomes
+  * associated with a PAN. (IEEE 802.15.4-2006, Sect. 7.1.3)
+  */
+ 
  #include "TKN154.h"
  
***************
*** 52,55 ****
--- 57,61 ----
     * @param security        The security options (NULL means security is 
     *                        disabled)
+    *
     * @return       IEEE154_SUCCESS if the request succeeded and a confirm event
     *               will be signalled, an appropriate error code otherwise 
***************
*** 68,72 ****
  
    /**
!    * Notification that a device has requested to associate with a PAN.
     *
     * @param DeviceAddress the 64-bit address of the requesting device
--- 74,78 ----
  
    /**
!    * Notification that a device has requested to associate with this PAN.
     *
     * @param DeviceAddress the 64-bit address of the requesting device
***************
*** 83,87 ****
  
    /**
!    * Send a response to a device's request to associate
     *
     * @param DeviceAddress     The 64-bit address of the device to respond to
--- 89,93 ----
  
    /**
!    * Sends a response to a device that requested to associate with this PAN.
     *
     * @param DeviceAddress     The 64-bit address of the device to respond to
***************
*** 91,97 ****
     * @param security        The security options (NULL means security is 
     *                        disabled)
     * @return IEEE154_SUCCESS if the request succeeded and an indication event
     *         will be signalled through the MLME_COMM_STATUS interface later,  
!    *         otherwise an appropriate error code (no MLME_COMM_STATUS.indication
     *         event will be signalled in this case)
     */
--- 97,104 ----
     * @param security        The security options (NULL means security is 
     *                        disabled)
+    *
     * @return IEEE154_SUCCESS if the request succeeded and an indication event
     *         will be signalled through the MLME_COMM_STATUS interface later,  
!    *         an appropriate error code otherwise (no MLME_COMM_STATUS.indication
     *         event will be signalled in this case)
     */
***************
*** 104,108 ****
  
    /**
!    * Confirmation of the association attempt.
     *
     * @param AssocShortAddress The short device address allocated by the
--- 111,115 ----
  
    /**
!    * Confirms an association attempt.
     *
     * @param AssocShortAddress The short device address allocated by the

Index: MLME_BEACON_NOTIFY.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_BEACON_NOTIFY.nc,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** MLME_BEACON_NOTIFY.nc	25 Nov 2008 09:35:09 -0000	1.2
--- MLME_BEACON_NOTIFY.nc	4 Mar 2009 18:31:40 -0000	1.3
***************
*** 34,52 ****
   */
  
  #include "TKN154.h"
  #include <message.h>
  interface MLME_BEACON_NOTIFY {
  
    /**
!    * A beacon frame has been received. This event is signalled only if 
!    * either the PIB attribute macAutoRequest is set to FALSE or the 
!    * beacon payload is not empty.
     *
!    * The beacon parameters can be accessed through the 
!    * <tt>IEEE154BeaconFrame<\tt> interface. The 
!    * <tt>IEEE154Frame<\tt> interface can be used to
!    * inspect the addressing fields in the MAC header.
     *
     * @param beacon The beacon frame
     * @return A frame buffer for the stack to use for the next received frame
     */
--- 34,60 ----
   */
  
+ /** 
+  * The MLME-SAP beacon notification primitive defines how a device may be
+  * notified when a beacon is received during normal operating conditions. 
+  * (IEEE 802.15.4-2006, Sect. 7.1.5)
+  */
+ 
  #include "TKN154.h"
  #include <message.h>
+ 
  interface MLME_BEACON_NOTIFY {
  
    /**
!    * A beacon frame has been received. This event is signalled only if
!    * either the PIB attribute <tt>macAutoRequest</tt> is set to FALSE
!    * or the beacon payload is not empty.
     *
!    * The beacon parameters can be accessed through the
!    * <tt>IEEE154BeaconFrame</tt> interface. The <tt>IEEE154Frame</tt>
!    * interface can be used to inspect the addressing fields in the MAC
!    * header.
     *
     * @param beacon The beacon frame
+    *
     * @return A frame buffer for the stack to use for the next received frame
     */

Index: MLME_COMM_STATUS.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_COMM_STATUS.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_COMM_STATUS.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_COMM_STATUS.nc	4 Mar 2009 18:31:40 -0000	1.2
***************
*** 34,37 ****
--- 34,45 ----
   */
  
+ /** 
+  * The MLME-SAP communication status primitive defines how the MLME
+  * communicates to the next higher layer about transmission status,
+  * when the transmission was instigated by a response primitive, and
+  * about security errors on incoming packets. (IEEE 802.15.4-2006,
+  * Sect. 7.1.12)
+  */
+ 
  #include "TKN154.h"
  interface MLME_COMM_STATUS {

Index: MLME_DISASSOCIATE.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_DISASSOCIATE.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_DISASSOCIATE.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_DISASSOCIATE.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 34,42 ****
   */
  
  #include "TKN154.h"
  interface MLME_DISASSOCIATE {
  
    /**
!    * Request disassociation from a PAN.
     * 
     * @param DeviceAddrMode The addressing mode of the device to which to send 
--- 34,47 ----
   */
  
+ /** 
+  * The MLME-SAP disassociation primitives define how a device can
+  * disassociate from a PAN. (IEEE 802.15.4-2006, Sect. 7.1.4)
+  */
+ 
  #include "TKN154.h"
  interface MLME_DISASSOCIATE {
  
    /**
!    * Requests disassociation from a PAN.
     * 
     * @param DeviceAddrMode The addressing mode of the device to which to send 
***************
*** 51,54 ****
--- 56,60 ----
     * @param security   The security options (NULL means security is 
     *                   disabled)
+    *
     * @return       IEEE154_SUCCESS if the request succeeded and a confirm event
     *               will be signalled, an appropriate error code otherwise 
***************
*** 66,70 ****
  
    /**
!    * Signals that a device has requested disassociation.
     *
     * @param DeviceAddress the 64-bit address of the requesting device
--- 72,76 ----
  
    /**
!    * Signals that a device has requested disassociation from this PAN.
     *
     * @param DeviceAddress the 64-bit address of the requesting device
***************
*** 80,84 ****
  
    /**
!    * Confirmation of the disassociation attempt.
     *
     * @param status The status of the disassociation attempt
--- 86,90 ----
  
    /**
!    * Confirmsn a disassociation attempt.
     *
     * @param status The status of the disassociation attempt

Index: MLME_GET.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_GET.nc,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** MLME_GET.nc	25 Nov 2008 09:35:09 -0000	1.2
--- MLME_GET.nc	4 Mar 2009 18:31:42 -0000	1.3
***************
*** 34,47 ****
   */
  
! /** 
!  * This interface can be used to read attribute values from the PHY/MAC PIB.
   * Instead of passing the PIB attribute identifier, there is a separate
   * command per attribute (and there are no confirm events). 
   *
!  * NOTE: for the attributes macBeaconPayload (0x45) and
!  * macBeaconPayloadLength (0x46) use the <tt>IEEE154TxBeaconPayload <\tt> 
!  * interface; for promiscuous mode there is a separate (SplitControl)
!  * interface. 
!  **/
  
  #include "TKN154.h" 
--- 34,47 ----
   */
  
! /**
!  * This interface allows to read attribute values from the PHY/MAC PIB.
   * Instead of passing the PIB attribute identifier, there is a separate
   * command per attribute (and there are no confirm events). 
   *
!  * NOTE: for the attributes <tt>macBeaconPayload</tt> (0x45) and
!  * <tt>macBeaconPayloadLength </tt>(0x46) use the
!  * <tt>IEEE154TxBeaconPayload</tt> interface; for promiscuous mode
!  * there is a separate (SplitControl) interface. 
!  */
  
  #include "TKN154.h" 
***************
*** 88,92 ****
  
    /* macBeaconPayload (0x45) and macBeaconPayloadLength (0x46) are read
!    * through the <tt>IEEE154TxBeaconPayload<\tt> interface. */
  
    /** @return PIB attribute macBeaconOrder (0x47) */
--- 88,92 ----
  
    /* macBeaconPayload (0x45) and macBeaconPayloadLength (0x46) are read
!    * through the <tt>IEEE154TxBeaconPayload</tt> interface. */
  
    /** @return PIB attribute macBeaconOrder (0x47) */
***************
*** 164,166 ****
--- 164,169 ----
    /** @return PIB attribute macMinSIFSPeriod */
    command ieee154_macMinSIFSPeriod_t macMinSIFSPeriod();
+ 
+   /** @return custom attribute macPanCoordinator */
+   command ieee154_macPanCoordinator_t macPanCoordinator();
  }

Index: MLME_GTS.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_GTS.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_GTS.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_GTS.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 34,37 ****
--- 34,44 ----
   */
  
+ /** 
+  * The MLME-SAP GTS management primitives define how GTSs are
+  * requested and maintained. A device wishing to use these primitives
+  * and GTSs in general will already be tracking the beacons of its PAN
+  * coordinator. (IEEE 802.15.4-2006, Sect. 7.1.7)
+  */
+ 
  #include "TKN154.h"
  interface MLME_GTS {

Index: MLME_ORPHAN.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_ORPHAN.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_ORPHAN.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_ORPHAN.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 34,37 ****
--- 34,43 ----
   */
  
+ /** 
+  * MLME-SAP orphan notification primitives define how a coordinator
+  * can issue a notification of an orphaned device. (IEEE 802.15.4-2006,
+  * Sect. 7.1.8)
+  */
+ 
  #include "TKN154.h" 
  interface MLME_ORPHAN {

Index: MLME_POLL.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_POLL.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_POLL.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_POLL.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 33,36 ****
--- 33,42 ----
   * ========================================================================
   */
+ 
+ /** 
+  * MLME-SAP polling primitives define how to request data from a
+  * coordinator. (IEEE 802.15.4-2006, Sect. 7.1.16)
+  */
+ 
  #include "TKN154.h"
  

Index: MLME_RESET.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_RESET.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_RESET.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_RESET.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 34,37 ****
--- 34,42 ----
   */
  
+ /** 
+  * MLME-SAP reset primitives specify how to reset the MAC sublayer to
+  * its default values. (IEEE 802.15.4-2006, Sect. 7.1.9)
+  */
+ 
  #include "TKN154.h"
  interface MLME_RESET {
***************
*** 39,47 ****
    /**
     * Allows the next higher layer to request that the MLME performs a
!    * reset operation. This command initializes the MAC and must be called 
!    * before calling any other MAC primitive. It extends the standard  
!    * interface definition by a parameter <tt>PANType</tt>, which defines 
!    * whether the device/coordinator will operate on a beacon-enabled PAN
!    * or on a nonbeacon-enabled PAN.
     *
     * Two things are important:
--- 44,49 ----
    /**
     * Allows the next higher layer to request that the MLME performs a
!    * reset operation. This command initializes the MAC and must be 
!    * called at least once before the MAC can be used.
     *
     * Two things are important:
***************
*** 59,64 ****
     *                      attributes retain their values prior to the
     *                      generation of the reset primitive.
-    * @param PANType       Either BEACON_ENABLED_PAN for beacon-enabled PANs
-    *                      or NONBEACON_ENABLED_PAN for nonbeacon-enabled PANs
     *
     * @return       IEEE154_SUCCESS if the request succeeded and a confirm event
--- 61,64 ----
***************
*** 68,73 ****
     */
    command ieee154_status_t request  (
!                           bool SetDefaultPIB,
!                           uint8_t PANType
                          );
  
--- 68,72 ----
     */
    command ieee154_status_t request  (
!                           bool SetDefaultPIB
                          );
  

Index: MLME_RX_ENABLE.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_RX_ENABLE.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_RX_ENABLE.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_RX_ENABLE.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 35,38 ****
--- 35,44 ----
   */
  
+ /** 
+  * MLME-SAP receiver state primitives define how a device can enable
+  * or disable the receiver at a given time. (IEEE 802.15.4-2006, Sect.
+  * 7.1.10)
+  */
+ 
  #include "TKN154.h"
  interface MLME_RX_ENABLE {

Index: MLME_SCAN.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_SCAN.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_SCAN.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_SCAN.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 34,37 ****
--- 34,43 ----
   */
  
+ /** 
+  * MLME-SAP scan primitives define how a device can determine the
+  * energy usage or the presence or absence of PANs in a communications
+  * channel. (IEEE 802.15.4-2006, Sect. 7.1.10)
+  */
+ 
  #include "TKN154.h"
  interface MLME_SCAN 

Index: MLME_SET.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_SET.nc,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** MLME_SET.nc	25 Nov 2008 09:35:09 -0000	1.2
--- MLME_SET.nc	4 Mar 2009 18:31:42 -0000	1.3
***************
*** 36,48 ****
  
  /** 
!  * This interface can be used to set attribute values in the PHY/MAC PIB.
   * Instead of passing the PIB attribute identifier, there is a separate
   * command per attribute (and there are no confirm events). 
   *
!  * NOTE: for the attributes macBeaconPayload (0x45) and
!  * macBeaconPayloadLength (0x46) use the <tt>IEEE154TxBeaconPayload <\tt> 
!  * interface; for promiscuous mode there is a separate (SplitControl)
!  * interface. 
!  **/
  
  #include "TKN154.h" 
--- 36,48 ----
  
  /** 
!  * This interface allows to set attribute values in the PHY/MAC PIB.
   * Instead of passing the PIB attribute identifier, there is a separate
   * command per attribute (and there are no confirm events). 
   *
!  * NOTE: for the attributes <tt>macBeaconPayload</tt> (0x45) and
!  * <tt>macBeaconPayloadLength</tt> (0x46) use the
!  * <tt>IEEE154TxBeaconPayload</tt> interface; for promiscuous mode
!  * there is a separate (SplitControl) interface. 
!  */
  
  #include "TKN154.h" 
***************
*** 91,95 ****
  
    /* macBeaconPayload (0x45) and macBeaconPayloadLength (0x46) are set
!    * through the <tt>IEEE154TxBeaconPayload<\tt> interface. */
  
    /** @param value new PIB attribute value for macBeaconOrder (0x47) 
--- 91,95 ----
  
    /* macBeaconPayload (0x45) and macBeaconPayloadLength (0x46) are set
!    * through the <tt>IEEE154TxBeaconPayload</tt> interface. */
  
    /** @param value new PIB attribute value for macBeaconOrder (0x47) 
***************
*** 139,143 ****
  
    /* macPromiscuousMode (0x51) is (re-)set through the 
!    * <tt>PromiscuousMode<\tt> (SplitControl) interface. */
  
    /** @param value new PIB attribute value for macRxOnWhenIdle (0x52) 
--- 139,143 ----
  
    /* macPromiscuousMode (0x51) is (re-)set through the 
!    * <tt>PromiscuousMode</tt> (SplitControl) interface. */
  
    /** @param value new PIB attribute value for macRxOnWhenIdle (0x52) 

Index: MLME_START.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_START.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_START.nc	16 Jun 2008 18:00:31 -0000	1.1
--- MLME_START.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 34,37 ****
--- 34,45 ----
   */
  
+ /** 
+  * MLME-SAP start primitives define how an FFD can request to start
+  * using a new superframe configuration in order to initiate a PAN,
+  * begin transmitting beacons on an already existing PAN, thus
+  * facilitating device discovery, or to stop transmitting beacons.
+  * (IEEE 802.15.4-2006, Sect. 7.1.14)
+  */
+ 
  #include "TKN154.h"
  interface MLME_START {

Index: MLME_SYNC_LOSS.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_SYNC_LOSS.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_SYNC_LOSS.nc	16 Jun 2008 18:00:32 -0000	1.1
--- MLME_SYNC_LOSS.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 34,37 ****
--- 34,44 ----
   */
  
+ /** 
+  * MLME-SAP synchronization primitives define how synchronization with
+  * a coordinator may be achieved and how a loss of synchronization is
+  * communicated to the next higher layer. (IEEE 802.15.4-2006, Sect.
+  * 7.1.15)
+  */
+ 
  #include "TKN154.h"
  interface MLME_SYNC_LOSS {

Index: MLME_SYNC.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/mac/tkn154/interfaces/MLME/MLME_SYNC.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MLME_SYNC.nc	16 Jun 2008 18:00:32 -0000	1.1
--- MLME_SYNC.nc	4 Mar 2009 18:31:42 -0000	1.2
***************
*** 33,36 ****
--- 33,44 ----
   * ========================================================================
   */
+ 
+ /** 
+  * MLME-SAP synchronization primitives define how synchronization with
+  * a coordinator may be achieved and how a loss of synchronization is
+  * communicated to the next higher layer. (IEEE 802.15.4-2006, Sect.
+  * 7.1.15)
+  */
+ 
  interface MLME_SYNC {
  



More information about the Tinyos-2-commits mailing list