Changeset 201


Ignore:
Timestamp:
10/08/09 10:35:08 (4 years ago)
Author:
thomas
Message:

temp

Location:
apps/TSCH
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • apps/TSCH/TODO.txt

    r181 r201  
    11- CellUsageC: TXRES cells will always be reserved, regardless of the previous state. This can cause trouble. Enquire. 
    22- based on gathered statistics, trigger garbage collection of cells/neighbors 
     3 
     4 
     5TSCHP: 
     6message_t queuedPkt[QUEUELENGTH]; 
     7bool queuedPktUsed[QUEUELENGTH]; 
     8 
     9------------------------------------------- 
     10 
     11AdvertiseP: 
     12uint8_t myHeight; 
     13 
     14Total: 1B 
     15 
     16------------------------------------------- 
     17 
     18CellUsageP: 
     19cellUsageInformation cellTable[LENGTHCELLFRAME]; 
     20 
     21Total: 9*11=99B 
     22 
     23------------------------------------------- 
     24 
     25NeighborsP: 
     26neighborEntry_t neighbors[MAXNUMNEIGHBORS]; 
     27 
     28Total: 18*10=180B 
     29 
     30------------------------------------------- 
     31 
     32ReservationP: 
     33ongoingRes_t ongoingRes[NUMONGOINGRES]; 
     34 
     35Total: (16+110?)*3=48B/358B 
     36 
     37------------------------------------------- 
     38 
     39SerialIOP: 
     40uint16_t output_buffer_index_write; 
     41uint16_t output_buffer_index_read; 
     42 
     43Total: 4B 
     44 
     45------------------------------------------- 
     46 
     47TSCHQueueP: 
     48TSCHQueueEntry_t queue[QUEUELENGTH]; 
     49 
     50Total: 110*5=550B 
     51 
     52=========================================== 
     53 
     54Total: 924B 
     55 
  • apps/TSCH/TSCH.h

    r197 r201  
    55enum { 
    66   LOOSING_SYNC_DELAY = 15, //in seconds 
    7    LOST_SYNC_DELAY = 30,     //in seconds 
     7   LOST_SYNC_DELAY = 30,    //in seconds 
    88   LENGTHCELLFRAME = 5,     //prime number better 
    99   QUEUELENGTH = 5, 
     
    1515   ADVRESCHANNELOFFSET=0, 
    1616   DELAY_REMOVE_FROZEN_RESERVATIONS=30000,//in ms 
    17    SERIAL_BUFFER_SIZE=200 
     17   SERIAL_OUTPUT_BUFFER_SIZE=200, 
     18   SERIAL_INPUT_BUFFER_SIZE=200 
    1819}; 
    1920 
     
    157158   ERR_NOT_IN_SLEEP_STATE                        =29,  //was not in S_SLEEP state at beginning of slot             [SlotEngineP]  arg1=state 
    158159   ERR_TURN_OFF_RADIO_FAILED                     =30,  //could not turn off radio                                  [SlotEngineP] 
    159    ERR_NOT_IN_SLEEP_SYNCHRONIZING_AT_NEWSLOT     =31,  //wrong state (not SLEEP/SYNCHRONIZING) in newSlot          [SlotEngineP]  arg1=state 
     160   ERR_WRONG_STATE_IN_NEWSLOT                    =31,  //wrong state in newSlot                                    [SlotEngineP]  arg1=state 
    160161   ERR_NO_TIME_TO_SET_CHANNEL                    =32,  //no time to set channel and start radio                    [SlotEngineP] 
    161162   ERR_NO_TIME_TO_SEND_DATA                      =33,  //no time to send DATA                                      [SlotEngineP] 
    162163   ERR_NO_TIME_TO_SEND_ACK                       =34,  //no time to send ACK                                       [SlotEngineP] 
    163    ERR_WRONG_STATE_IN_FASTTIMER_FIRED            =35,  //wrong state in FastTimer.fired                            [SlotEngineP]  arg1=state 
    164    ERR_WRONG_STATE_IN_SUBCONTROL_STARTDONE       =36,  //wrong state in SubControl.startDone                       [SlotEngineP]  arg1=state 
    165    ERR_WRONG_STATE_IN_SUBCONTROL_STOPDONE        =37,  //wrong state in SubControl.stopDone                        [SlotEngineP]  arg1=state 
     164   ERR_WRONG_STATE_IN_FASTTIMER_FIRED            =35,  //wrong state in FastTimer.fired                            [SlotEngineP]  arg1=state arg2=slotOffset 
     165   ERR_WRONG_STATE_IN_SUBCONTROL_STARTDONE       =36,  //wrong state in SubControl.startDone                       [SlotEngineP]  arg1=state arg2=slotOffset 
     166   ERR_WRONG_STATE_IN_SUBCONTROL_STOPDONE        =37,  //wrong state in SubControl.stopDone                        [SlotEngineP]  arg1=state arg2=slotOffset 
    166167   ERR_START_RADIO_FOR_SYNCHRONIZER_FAILED       =38,  //could not start radio for synchronizer                    [SlotEngineP] 
    167168   ERR_START_RADIO_AT_START_SLOT_FAILED          =39,  //could not start radio at beginning of slot                [SlotEngineP] 
    168    ERR_WRONG_STATE_IN_CC2420CONFIG_SYNCDONE      =40,  //wrong state in CC2420Config.syncDone                      [SlotEngineP]  arg1=state 
    169    ERR_WRONG_STATE_IN_SUBSEND_SENDDONE           =41,  //wrong state in SubSend.sendDone                           [SlotEngineP]  arg1=state 
     169   ERR_WRONG_STATE_IN_CC2420CONFIG_SYNCDONE      =40,  //wrong state in CC2420Config.syncDone                      [SlotEngineP]  arg1=state arg2=slotOffset 
     170   ERR_WRONG_STATE_IN_SUBSEND_SENDDONE           =41,  //wrong state in SubSend.sendDone                           [SlotEngineP]  arg1=state arg2=slotOffset 
    170171   ERR_UNDEFINED_TYPE                            =42,  //undefined type                                            [TSCHQueueC]   arg1=type 
    171172   ERR_NOT_DATA_MSG_THROUGH_SENDDATA             =43,  //should receive only DATA through SendDATA                 [TSCHQueueC]   arg1=message_type 
  • apps/TSCH/TSCHAppC.nc

    r197 r201  
    22} 
    33implementation { 
    4    //general 
    54   components MainC; 
    6    //stack 
    75   components TSCHC; 
    86   components ForwardingC; 
     
    2422 
    2523   TSCHC.Boot->MainC; 
    26    //stack 
    2724   TSCHC.IDManager->IDManagerC; 
    2825   TSCHC.Advertise->AdvertiseC; 
  • apps/TSCH/TSCHP.nc

    r200 r201  
    3131} 
    3232implementation { 
     33   /*-------------------------------- variables -----------------------------------------*/ 
     34 
    3335   message_t queuedPkt[QUEUELENGTH]; 
    3436   bool queuedPktUsed[QUEUELENGTH]; 
     37 
    3538   heightNeighbor_t nextHop; 
    3639   uint8_t datavaluecounter=0; 
    3740   uint8_t numreservations; 
    3841 
    39    /***************************** helper functions ***************************************/ 
     42   /*-------------------------------- prototypes ----------------------------------------*/ 
    4043 
    4144   task void getNextHop(); 
    4245   task void checkReservedCells(); 
    43    task void sendDATAMessage(); 
    4446   task void addReservation(); 
    4547   task void removeReservation(); 
     48   task void sendDATAMessage(); 
    4649   task void printDebug(); 
     50 
     51   /*-------------------------------- helper functions ----------------------------------*/ 
    4752 
    4853   task void getNextHop() { 
     
    109114   } 
    110115 
    111    /***************************** interfaces ***************************************/ 
    112  
     116   /*-------------------------------- interfaces ----------------------------------------*/ 
     117 
     118   //SoftwareInit 
     119   command error_t SoftwareInit.init() { 
     120      uint8_t i; 
     121      for (i=0;i<QUEUELENGTH;i++){ 
     122         queuedPktUsed[i]=FALSE; 
     123      } 
     124      return SUCCESS; 
     125   } 
     126    
    113127   //Boot 
    114128   event void Boot.booted() { 
     
    118132   } 
    119133 
    120    //SoftwareInit 
    121    command error_t SoftwareInit.init() { 
    122       uint8_t i; 
    123       for (i=0;i<QUEUELENGTH;i++){ 
    124          queuedPktUsed[i]=FALSE; 
    125       } 
    126       return SUCCESS; 
    127    } 
    128  
    129134   //SplitControl 
    130135   event void SplitControl.startDone(error_t error) { 
    131136      switch (call IDManager.getMyID()) { 
    132137         case 2: 
     138         case 3: 
    133139            numreservations = 1; 
    134             break; 
    135          case 4: 
    136             numreservations = 6; 
    137             break; 
    138          case 5: 
    139             numreservations = 9; 
    140140            break; 
    141141         default: 
  • apps/TSCH/advertise/AdvertiseP.nc

    r200 r201  
    1616   /*-------------------------------- variables -----------------------------------------*/ 
    1717 
     18   uint8_t myHeight; 
     19 
    1820   message_t pkt; 
    1921   bool busy; 
    20    uint8_t myHeight; 
    2122   uint32_t advPeriod = 1000; 
    2223 
  • apps/TSCH/cellusage/CellUsageP.nc

    r200 r201  
    1717 
    1818   cellUsageInformation cellTable[LENGTHCELLFRAME]; 
     19 
    1920   bool cellStatsBusy; 
    2021   slotOffset_t cellStatsSlotOffset; 
  • apps/TSCH/debugwsn.py

    r199 r201  
    1515   sys.exit() 
    1616 
     17def getSlotState(slotStateNumber): 
     18   if   (slotStateNumber==0):  return "S_SETTING_CHAN" 
     19   elif (slotStateNumber==1):  return "S_STARTING" 
     20   elif (slotStateNumber==2):  return "S_STARTED" 
     21   elif (slotStateNumber==3):  return "S_SYNCHRONIZING" 
     22   elif (slotStateNumber==4):  return "S_TXDATA" 
     23   elif (slotStateNumber==5):  return "S_WAIT_RXACK" 
     24   elif (slotStateNumber==6):  return "S_ACK" 
     25   elif (slotStateNumber==7):  return "S_RXDATA" 
     26   elif (slotStateNumber==8):  return "S_WAIT_TXACK" 
     27   elif (slotStateNumber==9):  return "S_TXACK" 
     28   elif (slotStateNumber==10): return "S_STOPPING" 
     29   elif (slotStateNumber==11): return "S_SLEEP" 
     30   else: return "!!unknow state ("+str(slotStateNumber)+")!!" 
     31 
     32def getComponentName(componentNameNumber): 
     33   if   (componentNameNumber==0):  return "[TSCHP]" 
     34   elif (componentNameNumber==1):  return "[ForwardingP]" 
     35   elif (componentNameNumber==2):  return "[ReservationP]" 
     36   elif (componentNameNumber==3):  return "[NeighborsP]" 
     37   elif (componentNameNumber==4):  return "[CellUsageP]" 
     38   elif (componentNameNumber==5):  return "[AdvertiseP]" 
     39   elif (componentNameNumber==6):  return "[TSCHQueueP]" 
     40   elif (componentNameNumber==7):  return "[KeepAliveP]" 
     41   elif (componentNameNumber==8):  return "[MultiplexP]" 
     42   elif (componentNameNumber==9):  return "[SlotEngineP]" 
     43   elif (componentNameNumber==10): return "[GlobalTimeP]" 
     44   elif (componentNameNumber==11): return "[SerialIOP]" 
     45   elif (componentNameNumber==12): return "[TestLowerTSCHP]" 
     46   else : displayline = displayline + "[!!unknow component("+str(ord(command[3]))+")!!] " 
     47 
    1748def parseAndDisplay(text_tag,command): 
    1849   displayline="" 
     
    2354      displayline = displayline + "node "+str(moteID)+": " 
    2455      #byte 3 is the calling component 
    25       if   (ord(command[3])==0):  displayline = displayline + "[TSCHP] " 
    26       elif (ord(command[3])==1):  displayline = displayline + "[ForwardingP] " 
    27       elif (ord(command[3])==2):  displayline = displayline + "[ReservationP] " 
    28       elif (ord(command[3])==3):  displayline = displayline + "[NeighborsP] " 
    29       elif (ord(command[3])==4):  displayline = displayline + "[CellUsageP] " 
    30       elif (ord(command[3])==5):  displayline = displayline + "[AdvertiseP] " 
    31       elif (ord(command[3])==6):  displayline = displayline + "[TSCHQueueP] " 
    32       elif (ord(command[3])==7):  displayline = displayline + "[KeepAliveP] " 
    33       elif (ord(command[3])==8):  displayline = displayline + "[MultiplexP] " 
    34       elif (ord(command[3])==9):  displayline = displayline + "[SlotEngineP] " 
    35       elif (ord(command[3])==10): displayline = displayline + "[GlobalTimeP] " 
    36       elif (ord(command[3])==11): displayline = displayline + "[SerialIOP] " 
     56      displayline = displayline + getComponentName(ord(command[3])) + " " 
    3757      #byte 4 is the command 
    3858      #bytes 5 and 6 are arg1 
    3959      #bytes 7 and 8 are arg2 
    40       if (ord(command[4])==0):    displayline = displayline + "main program booted" 
    41       elif (ord(command[4])==0):  displayline = displayline + "main program booted" 
     60      if   (ord(command[4])==0):  displayline = displayline + "main program booted" 
    4261      elif (ord(command[4])==1):  displayline = displayline + "reservation is ready" 
    4362      elif (ord(command[4])==2):  displayline = displayline + "send.sendDone for packet I did not send" 
     
    5170      elif (ord(command[4])==10): displayline = displayline + "CellUsageSet.setUsage does not set RXRES and ADV slots (slotOffset="+str(ord(command[5])*256+ord(command[6]))+", channelOffset="+str(ord(command[7])*256+ord(command[8]))+")" 
    5271      elif (ord(command[4])==11): displayline = displayline + "ForwardingP is busy" 
    53       elif (ord(command[4])==12): displayline = displayline + "lost synchronization" 
     72      elif (ord(command[4])==12): displayline = displayline + "Lost Synchronization" 
    5473      elif (ord(command[4])==13): displayline = displayline + "SimpleSend.sendDone while busy==FALSE" 
    5574      elif (ord(command[4])==14): displayline = displayline + "received message of unknown type="+str(ord(command[5])*256+ord(command[6])) 
     
    6887      elif (ord(command[4])==27): displayline = displayline + "SimpleSend.sendDone with todo!=WAIT_FOR_SENT" 
    6988      elif (ord(command[4])==28): displayline = displayline + "unsupported ACK response" 
    70       elif (ord(command[4])==29): displayline = displayline + "was in state="+str(ord(command[5])*256+ord(command[6]))+" at beginning of slot, not in S_SLEEP" 
     89      elif (ord(command[4])==29): displayline = displayline + "was in state="+getSlotState(str(ord(command[5])*256+ord(command[6])))+" at beginning of slot, not in S_SLEEP" 
    7190      elif (ord(command[4])==30): displayline = displayline + "could not turn off radio" 
    72       elif (ord(command[4])==31): displayline = displayline + "wrong state="+str(ord(command[5])*256+ord(command[6]))+" (not SLEEP/SYNCHRONIZING) in newSlot" 
     91      elif (ord(command[4])==31): displayline = displayline + "wrong state="+getSlotState(ord(command[5])*256+ord(command[6]))+" in newSlot, should be S_SLEEP or S_SYNCHRONIZING (slotOffset="+str(ord(command[7])*256+ord(command[8]))+")" 
    7392      elif (ord(command[4])==32): displayline = displayline + "no time to set channel and start radio" 
    7493      elif (ord(command[4])==33): displayline = displayline + "no time to send DATA" 
    7594      elif (ord(command[4])==34): displayline = displayline + "no time to send ACK" 
    76       elif (ord(command[4])==35): displayline = displayline + "wrong state="+str(ord(command[5])*256+ord(command[6]))+" in FastTimer.fired" 
    77       elif (ord(command[4])==36): displayline = displayline + "wrong state="+str(ord(command[5])*256+ord(command[6]))+" in SubControl.startDone" 
    78       elif (ord(command[4])==37): displayline = displayline + "wrong state="+str(ord(command[5])*256+ord(command[6]))+" in SubControl.stopDone" 
     95      elif (ord(command[4])==35): displayline = displayline + "wrong state="+getSlotState(ord(command[5])*256+ord(command[6]))+" in FastTimer.fired (slotOffset="+str(ord(command[7])*256+ord(command[8]))+")" 
     96      elif (ord(command[4])==36): displayline = displayline + "wrong state="+getSlotState(ord(command[5])*256+ord(command[6]))+" in SubControl.startDone (slotOffset="+str(ord(command[7])*256+ord(command[8]))+")" 
     97      elif (ord(command[4])==37): displayline = displayline + "wrong state="+getSlotState(ord(command[5])*256+ord(command[6]))+" in SubControl.stopDone (slotOffset="+str(ord(command[7])*256+ord(command[8]))+")" 
    7998      elif (ord(command[4])==38): displayline = displayline + "could not start radio for synchronizer" 
    8099      elif (ord(command[4])==39): displayline = displayline + "could not start radio at beginning of slot" 
    81       elif (ord(command[4])==40): displayline = displayline + "wrong state="+str(ord(command[5])*256+ord(command[6]))+" in CC2420Config.syncDone" 
    82       elif (ord(command[4])==41): displayline = displayline + "wrong state="+str(ord(command[5])*256+ord(command[6]))+" in SubSend.sendDone" 
     100      elif (ord(command[4])==40): displayline = displayline + "wrong state="+getSlotState(ord(command[5])*256+ord(command[6]))+" in CC2420Config.syncDone (slotOffset="+str(ord(command[7])*256+ord(command[8]))+")" 
     101      elif (ord(command[4])==41): displayline = displayline + "wrong state="+getSlotState(ord(command[5])*256+ord(command[6]))+" in SubSend.sendDone (slotOffset="+str(ord(command[7])*256+ord(command[8]))+")" 
    83102      elif (ord(command[4])==42): displayline = displayline + "undefined type="+str(ord(command[5])*256+ord(command[6])) 
    84103      elif (ord(command[4])==43): displayline = displayline + "should receive only DATA through SendDATA (now type="+str(ord(command[5])*256+ord(command[6]))+")" 
     
    89108      elif (ord(command[4])==48): displayline = displayline + "Dequeue.done while busy==TRUE" 
    90109      elif (ord(command[4])==49): displayline = displayline + "DeQueue.done for packet I didn't send" 
    91       elif (ord(command[4])==50): displayline = displayline + "Acquired Sync" 
    92       elif (ord(command[4])==51): displayline = displayline + "Loosing Sync" 
     110      elif (ord(command[4])==50): displayline = displayline + "Acquired Synchronization" 
     111      elif (ord(command[4])==51): displayline = displayline + "Loosing Synchronization" 
    93112      else: displayline = displayline + "unknown command code" 
    94113      displayline = displayline + "\n" 
  • apps/TSCH/globaltime/GlobalTimeP.nc

    r200 r201  
    2525   /*-------------------------------- variables -----------------------------------------*/ 
    2626    
     27   bool sync; 
    2728   uint32_t asn; 
    28    bool sync; 
    2929   uint32_t myReceptionLocalTime; 
    3030   uint32_t hisTranmissionGlobalSlotOffset; 
  • apps/TSCH/serialio/SerialIOP.nc

    r199 r201  
    1818   /*------------------- variables ----------------------------------*/ 
    1919 
    20    msp430_uart_union_config_t msp430_uart_telos_config = {{ubr: UBR_1MHZ_115200, umctl: UMCTL_1MHZ_115200, ssel: 0x02, pena: 0, pev: 0, spb: 0, clen: 1, listen: 0, mm: 0, ckpl: 0, urxse: 0, urxeie: 1, urxwie: 0, utxe : 1, urxe : 1}}; 
    21    uint8_t output_buffer[SERIAL_BUFFER_SIZE]; 
    2220   uint16_t output_buffer_index_write; 
    2321   uint16_t output_buffer_index_read; 
     22 
     23   msp430_uart_union_config_t msp430_uart_telos_config = {{ubr: UBR_1MHZ_115200, umctl: UMCTL_1MHZ_115200, ssel: 0x02, pena: 0, pev: 0, spb: 0, clen: 1, listen: 0, mm: 0, ckpl: 0, urxse: 0, urxeie: 1, urxwie: 0, utxe : 1, urxe : 1}}; 
     24   uint8_t output_buffer[SERIAL_OUTPUT_BUFFER_SIZE]; 
    2425   bool somethingInOutputBuffer; 
    25    uint8_t input_buffer[SERIAL_BUFFER_SIZE]; 
     26   uint8_t input_buffer[SERIAL_INPUT_BUFFER_SIZE]; 
    2627   uint16_t input_buffer_index_write; 
    2728   bool allowedToUse; 
     
    3637 
    3738   uint16_t output_buffer_index_write_increment() { 
    38       atomic output_buffer_index_write=(output_buffer_index_write+1)%SERIAL_BUFFER_SIZE; 
     39      atomic output_buffer_index_write=(output_buffer_index_write+1)%SERIAL_OUTPUT_BUFFER_SIZE; 
    3940      return output_buffer_index_write;  
    4041   } 
    4142 
    4243   uint16_t output_buffer_index_read_increment() { 
    43       atomic output_buffer_index_read=(output_buffer_index_read+1)%SERIAL_BUFFER_SIZE; 
     44      atomic output_buffer_index_read=(output_buffer_index_read+1)%SERIAL_INPUT_BUFFER_SIZE; 
    4445      atomic return output_buffer_index_read; 
    4546   } 
  • apps/TSCH/slotengine/SlotEngineP.nc

    r200 r201  
    211211         default: 
    212212            post endSlotTask(); 
    213             call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_NOT_IN_SLEEP_SYNCHRONIZING_AT_NEWSLOT,(uint16_t)state,0); 
     213            call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_NEWSLOT,(uint16_t)state,(uint16_t)newASN%LENGTHCELLFRAME); 
    214214            break; 
    215215      } 
     
    286286         default: 
    287287            post endSlotTask(); 
    288             call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_FASTTIMER_FIRED,(uint16_t)state,0); 
     288            call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_FASTTIMER_FIRED,(uint16_t)state,(uint16_t)slotOffset); 
    289289            break; 
    290290      } 
     
    397397         default: 
    398398            post endSlotTask(); 
    399             call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_SUBCONTROL_STARTDONE,(uint16_t)state,0); 
     399            call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_SUBCONTROL_STARTDONE,(uint16_t)state,(uint16_t)slotOffset); 
    400400            break; 
    401401      } 
     
    409409         default: 
    410410            post endSlotTask(); 
    411             call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_SUBCONTROL_STOPDONE,(uint16_t)state,0); 
     411            call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_SUBCONTROL_STOPDONE,(uint16_t)state,(uint16_t)slotOffset); 
    412412            break; 
    413413      } 
     
    436436         default: 
    437437            post endSlotTask(); 
    438             call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_CC2420CONFIG_SYNCDONE,(uint16_t)state,0); 
     438            call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_CC2420CONFIG_SYNCDONE,(uint16_t)state,(uint16_t)slotOffset); 
    439439            break; 
    440440      } 
     
    455455         default: 
    456456            post endSlotTask(); 
    457             call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_SUBSEND_SENDDONE,(uint16_t)state,0); 
     457            call SerialIO.printError(COMPONENT_SLOTENGINE,ERR_WRONG_STATE_IN_SUBSEND_SENDDONE,(uint16_t)state,(uint16_t)slotOffset); 
    458458            break; 
    459459      } 
  • apps/TSCH/testlowertsch/TestLowerTSCHC.nc

    r199 r201  
    6363      if (slotoffset==0) {                                 //adv 
    6464         return CELLTYPE_ADV; 
     65      } else if (slotoffset==1 || slotoffset==2) {         //off (for serial communication) 
     66         return CELLTYPE_OFF; 
    6567      } else { 
    6668         if (TOS_NODE_ID%2==0) { 
     
    221223   async event void GlobalTime.newSlot(uint32_t newASN) { 
    222224   } 
    223  
    224    //DebugPrintSlotEngine 
    225    event void DebugPrintSlotEngine.done() { 
    226    } 
    227  
    228    //DebugPrintGlobalTime 
    229    event void DebugPrintGlobalTime.done() { 
    230    } 
    231225} 
Note: See TracChangeset for help on using the changeset viewer.