smac.h File Reference

#include "mac.h"
#include "mac-802_11.h"
#include "cmu-trace.h"
#include "random.h"
#include "timer-handler.h"

Include dependency graph for smac.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  hdr_smac
struct  NeighbList
struct  SchedTable
class  SMAC
struct  smac_control_frame
struct  smac_sync_frame
class  SmacCounterTimer
class  SmacCsTimer
class  SmacGeneTimer
class  SmacNavTimer
class  SmacNeighNavTimer
class  SmacRecvTimer
class  SmacSendTimer
class  SmacTimer

Defines

#define ACK_PKT   3
#define BANDWIDTH   20
#define BCASTDATA   1
#define BCASTSYNC   0
#define CLKTICK2SEC(x)   ((x) * (CLOCKRES / 1.0e3))
#define CLOCKRES   1
#define CR_SENSE   2
#define CTS_PKT   2
#define DATA_CW   63
#define DATA_PKT   0
#define ENCODE_RATIO   2
#define IDLE   1
#define PRE_PKT_BYTES   5
#define PROC_DELAY   1
#define RADIO_IDLE   1
#define RADIO_RX   2
#define RADIO_SLP   0
#define RADIO_TX   3
#define RTS_PKT   1
#define SEC2CLKTICK(x)   ((x) / (CLOCKRES / 1.0e3))
#define SIZEOF_SMAC_CTRLPKT   10
#define SIZEOF_SMAC_DATAPKT   50
#define SIZEOF_SMAC_SYNCPKT   9
#define SLEEP   0
#define SMAC_DUTY_CYCLE   10
#define SMAC_EXTEND_LIMIT   5
#define SMAC_MAX_NUM_NEIGHBORS   20
#define SMAC_MAX_NUM_SCHEDULES   4
#define SMAC_RETRY_LIMIT   5
#define SRCH_CYCLES_LONG   22
#define SRCH_CYCLES_SHORT   3
#define SYNC_CW   31
#define SYNC_PKT   4
#define SYNCPERIOD   10
#define SYNCPKTTIME   3
#define UNICAST   2
#define WAIT_ACK   5
#define WAIT_CTS   3
#define WAIT_DATA   4
#define WAIT_NEXTFRAG   6


Define Documentation

#define ACK_PKT   3
 

Definition at line 219 of file smac.h.

Referenced by SMAC::handleSendTimer(), SMAC::sendACK(), and SMAC::txtime().

#define BANDWIDTH   20
 

Definition at line 171 of file smac.h.

Referenced by SMAC::SMAC().

#define BCASTDATA   1
 

Definition at line 208 of file smac.h.

Referenced by SMAC::checkToSend(), SMAC::handleCounterTimer(), SMAC::handleCsTimer(), and SMAC::sentDATA().

#define BCASTSYNC   0
 

Definition at line 207 of file smac.h.

Referenced by SMAC::handleCounterTimer(), and SMAC::handleCsTimer().

#define CLKTICK2SEC  )     ((x) * (CLOCKRES / 1.0e3))
 

Definition at line 181 of file smac.h.

Referenced by SMAC::capture(), SMAC::checkToSend(), SMAC::command(), SMAC::handleCounterTimer(), SMAC::handleRecvTimer(), SmacCounterTimer::sched(), SMAC::sendSYNC(), SMAC::setMySched(), SMAC::SMAC(), and SMAC::txtime().

#define CLOCKRES   1
 

Definition at line 170 of file smac.h.

Referenced by SMAC::SMAC().

#define CR_SENSE   2
 

Definition at line 189 of file smac.h.

Referenced by SMAC::checkToSend(), SMAC::handleACK(), SMAC::handleCounterTimer(), SMAC::handleCTS(), SMAC::handleDATA(), SMAC::handleRecvTimer(), and SMAC::handleRTS().

#define CTS_PKT   2
 

Definition at line 218 of file smac.h.

Referenced by SMAC::handleSendTimer(), SMAC::sendCTS(), and SMAC::txtime().

#define DATA_CW   63
 

Definition at line 150 of file smac.h.

Referenced by SMAC::checkToSend(), and SMAC::handleCounterTimer().

#define DATA_PKT   0
 

Definition at line 216 of file smac.h.

Referenced by SMAC::bcastMsg(), SMAC::handleSendTimer(), and SMAC::txtime().

#define ENCODE_RATIO   2
 

Definition at line 174 of file smac.h.

Referenced by SMAC::SMAC().

#define IDLE   1
 

Definition at line 187 of file smac.h.

#define PRE_PKT_BYTES   5
 

Definition at line 173 of file smac.h.

Referenced by SMAC::SMAC().

#define PROC_DELAY   1
 

Definition at line 175 of file smac.h.

Referenced by SMAC::SMAC().

#define RADIO_IDLE   1
 

Definition at line 225 of file smac.h.

Referenced by SMAC::checkToSend(), SMAC::chkRadio(), SMAC::handleCounterTimer(), SMAC::handleRecvTimer(), SMAC::handleSendTimer(), SMAC::SMAC(), and SMAC::wakeup().

#define RADIO_RX   2
 

Definition at line 226 of file smac.h.

Referenced by SMAC::handleCounterTimer().

#define RADIO_SLP   0
 

Definition at line 224 of file smac.h.

Referenced by SMAC::checkToSend(), SMAC::chkRadio(), SMAC::handleCounterTimer(), SMAC::handleRecvTimer(), SMAC::sleep(), and SMAC::wakeup().

#define RADIO_TX   3
 

Definition at line 227 of file smac.h.

Referenced by SMAC::handleRecvTimer(), and SMAC::transmit().

#define RTS_PKT   1
 

Definition at line 217 of file smac.h.

Referenced by SMAC::handleSendTimer(), SMAC::sendRTS(), and SMAC::txtime().

#define SEC2CLKTICK  )     ((x) / (CLOCKRES / 1.0e3))
 

Definition at line 182 of file smac.h.

#define SIZEOF_SMAC_CTRLPKT   10
 

Definition at line 270 of file smac.h.

Referenced by SMAC::sendACK(), SMAC::sendCTS(), SMAC::sendRTS(), and SMAC::SMAC().

#define SIZEOF_SMAC_DATAPKT   50
 

Definition at line 269 of file smac.h.

Referenced by SMAC::bcastMsg(), SMAC::sendMsg(), and SMAC::SMAC().

#define SIZEOF_SMAC_SYNCPKT   9
 

Definition at line 271 of file smac.h.

Referenced by SMAC::sendSYNC(), and SMAC::SMAC().

#define SLEEP   0
 

Definition at line 186 of file smac.h.

Referenced by SMAC::checkToSend(), SMAC::handleCounterTimer(), SMAC::handleNavTimer(), SMAC::handleRecvTimer(), and SMAC::sleep().

#define SMAC_DUTY_CYCLE   10
 

Definition at line 115 of file smac.h.

#define SMAC_EXTEND_LIMIT   5
 

Definition at line 123 of file smac.h.

Referenced by SMAC::handleGeneTimer().

#define SMAC_MAX_NUM_NEIGHBORS   20
 

Definition at line 107 of file smac.h.

Referenced by SMAC::SMAC().

#define SMAC_MAX_NUM_SCHEDULES   4
 

Definition at line 111 of file smac.h.

Referenced by SMAC::~SMAC().

#define SMAC_RETRY_LIMIT   5
 

Definition at line 119 of file smac.h.

Referenced by SMAC::handleGeneTimer().

#define SRCH_CYCLES_LONG   22
 

Definition at line 155 of file smac.h.

Referenced by SMAC::handleCounterTimer().

#define SRCH_CYCLES_SHORT   3
 

Definition at line 154 of file smac.h.

Referenced by SMAC::handleCounterTimer().

#define SYNC_CW   31
 

Definition at line 149 of file smac.h.

Referenced by SMAC::handleCounterTimer().

#define SYNC_PKT   4
 

Definition at line 220 of file smac.h.

Referenced by SMAC::handleSendTimer(), SMAC::sendSYNC(), and SMAC::txtime().

#define SYNCPERIOD   10
 

Definition at line 151 of file smac.h.

Referenced by SMAC::command(), and SMAC::sentSYNC().

#define SYNCPKTTIME   3
 

Definition at line 152 of file smac.h.

Referenced by SMAC::sendSYNC(), and SMAC::txtime().

#define UNICAST   2
 

Definition at line 209 of file smac.h.

Referenced by SMAC::checkToSend(), LandmarkAgent::command(), SMAC::handleCounterTimer(), SMAC::handleCsTimer(), and LandmarkAgent::periodic_callback().

#define WAIT_ACK   5
 

Definition at line 193 of file smac.h.

Referenced by SMAC::handleACK(), SMAC::handleCTS(), and SMAC::handleGeneTimer().

#define WAIT_CTS   3
 

Definition at line 191 of file smac.h.

Referenced by SMAC::handleCTS(), SMAC::handleGeneTimer(), and SMAC::startUcast().

#define WAIT_DATA   4
 

Definition at line 192 of file smac.h.

Referenced by SMAC::checkToSend(), SMAC::handleCounterTimer(), SMAC::handleDATA(), SMAC::handleNeighNavTimer(), and SMAC::handleRTS().

#define WAIT_NEXTFRAG   6
 

Definition at line 197 of file smac.h.


Generated on Tue Mar 6 17:00:45 2007 for ns2 Network Simulator 2.29 by  doxygen 1.4.6