MiXiM  2.3
Consts80211.h
00001 #ifndef CONSTANTS_802_11
00002 #define CONSTANTS_802_11
00003 
00005 const double BITRATES_80211[] = {
00006     1000000,
00007     2000000,
00008     5500000,
00009     11000000
00010 };
00011 
00013 const double CENTER_FREQUENCIES[] = {
00014   -1,     //channel 0 does not exist
00015         2.412e9, // 1
00016         2.417e9, // 2
00017         2.422e9, // 3
00018         2.427e9, // 4
00019         2.432e9, // 5
00020         2.437e9, // 6
00021         2.442e9, // 7
00022         2.447e9, // 8
00023         2.452e9, // 9
00024         2.457e9, // 10
00025         2.462e9, // 11
00026         2.467e9, // 12
00027         2.472e9, // 13
00028         2.484e9, // 14
00029         };
00030 
00038 const double RED_PHY_HEADER_DURATION = 0.000020;
00039 
00041 const double PHY_HEADER_LENGTH = 192;
00043 const double HEADER_WITHOUT_PREAMBLE = 48;
00045 const double BITRATE_HEADER = 1E+6;
00047 const double BANDWIDTH = 20E+6;
00048 
00049 const int MAC_GENERATOR = 5;
00050 
00053 const double LENGTH_RTS = 160;
00054 const double LENGTH_CTS = 112;
00055 const double LENGTH_ACK = 112;
00057 const int MAC80211_HEADER_LENGTH = 272;
00058 
00059 //time slot ST, short interframe space SIFS, distributed interframe
00060 //space DIFS, and extended interframe space EIFS
00064 const const_simtime_t ST = 20E-6;
00068 const const_simtime_t SIFS = 10E-6;
00072 const const_simtime_t DIFS = 2 * ST + SIFS;
00076 const const_simtime_t EIFS = SIFS + DIFS + (PHY_HEADER_LENGTH + LENGTH_ACK) / BITRATE_HEADER;
00077 
00082 const unsigned LONG_RETRY_LIMIT = 4;
00083 
00088 const unsigned SHORT_RETRY_LIMIT = 7;
00089 
00093 const unsigned CW_MIN = 31;
00094 
00096 const unsigned CW_MAX = 1023;
00097 
00098 #endif
00099