[Tinyos-2-commits] CVS: tinyos-2.x/apps/tests/tkn154/TestIndirect/device TestDeviceReceiverC.nc, 1.1, 1.2 TestIndirectAppC.nc, 1.1, 1.2

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


Update of /cvsroot/tinyos/tinyos-2.x/apps/tests/tkn154/TestIndirect/device
In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv17605/apps/tests/tkn154/TestIndirect/device

Modified Files:
	TestDeviceReceiverC.nc TestIndirectAppC.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: TestDeviceReceiverC.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/apps/tests/tkn154/TestIndirect/device/TestDeviceReceiverC.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** TestDeviceReceiverC.nc	21 Jul 2008 15:18:16 -0000	1.1
--- TestDeviceReceiverC.nc	4 Mar 2009 18:31:00 -0000	1.2
***************
*** 60,64 ****
  
    event void Boot.booted() {
!     call MLME_RESET.request(TRUE, BEACON_ENABLED_PAN);
    }
    
--- 60,64 ----
  
    event void Boot.booted() {
!     call MLME_RESET.request(TRUE);
    }
    
***************
*** 100,103 ****
--- 100,109 ----
      // received a beacon frame during SCAN
      ieee154_phyCurrentPage_t page = call MLME_GET.phyCurrentPage();
+     ieee154_macBSN_t beaconSequenceNumber = call BeaconFrame.getBSN(frame);
+ 
+     if (beaconSequenceNumber & 1)
+       call Leds.led2On();
+     else
+       call Leds.led2Off();   
  
      if (!m_isPANDescriptorValid && call BeaconFrame.parsePANDescriptor(

Index: TestIndirectAppC.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/apps/tests/tkn154/TestIndirect/device/TestIndirectAppC.nc,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** TestIndirectAppC.nc	21 Jul 2008 15:18:16 -0000	1.1
--- TestIndirectAppC.nc	4 Mar 2009 18:31:00 -0000	1.2
***************
*** 37,53 ****
  {
  } implementation {
!   components MainC, LedsC, Ieee802154MacC;
    components TestDeviceReceiverC as App;
  
    MainC.Boot <- App;
    App.Leds -> LedsC;
!   App.MLME_RESET -> Ieee802154MacC;
!   App.MLME_SET -> Ieee802154MacC;
!   App.MLME_GET -> Ieee802154MacC;
!   App.MLME_SCAN -> Ieee802154MacC;
!   App.MLME_SYNC -> Ieee802154MacC;
!   App.MLME_BEACON_NOTIFY -> Ieee802154MacC;
!   App.MLME_SYNC_LOSS -> Ieee802154MacC;
!   App.MCPS_DATA -> Ieee802154MacC;
!   App.BeaconFrame -> Ieee802154MacC;
  }
--- 37,53 ----
  {
  } implementation {
!   components MainC, LedsC, Ieee802154BeaconEnabledC as MAC;
    components TestDeviceReceiverC as App;
  
    MainC.Boot <- App;
    App.Leds -> LedsC;
!   App.MLME_RESET -> MAC;
!   App.MLME_SET -> MAC;
!   App.MLME_GET -> MAC;
!   App.MLME_SCAN -> MAC;
!   App.MLME_SYNC -> MAC;
!   App.MLME_BEACON_NOTIFY -> MAC;
!   App.MLME_SYNC_LOSS -> MAC;
!   App.MCPS_DATA -> MAC;
!   App.BeaconFrame -> MAC;
  }



More information about the Tinyos-2-commits mailing list