| Makefile.in | Add
mobile/mod_codedppm.o mobile/propagation-tarokh.o mac/mac-ifcontrol.o mac/interference-phy.o \ to OBJ_CC |
| common/packet.h |
Add the MAC_IFControl packet header
line 59: #define HDR_MAC_IFControl(p) (hdr_mac_ifcontrol::access(p))
line 122: PT_MAC_IFControl,
line 209: name_[PT_MAC_IFControl]= "MACIFControl";
|
| tcl/lan/ns-mac.tcl |
Add the MAC/IFControl default values
# MAC IFControl settings
if [TclObject is-class Mac/IFControl] {
Mac/IFControl set delay_ 64us
Mac/IFControl set ifs_ 16us
Mac/IFControl set slotTime_ 16us
Mac/IFControl set cwmin_ 16
Mac/IFControl set cwmax_ 1024
Mac/IFControl set rtxLimit_ 16
Mac/IFControl set bssId_ -1
Mac/IFControl set sifs_ 8us
Mac/IFControl set pifs_ 12us
Mac/IFControl set difs_ 16us
Mac/IFControl set rtxAckLimit_ 1
Mac/IFControl set rtxRtsLimit_ 3
Mac/IFControl set RTSThreshold 0
Mac/IFControl set fixed_code -1 ; # dynamic coding
}
|
tcl/lib/ns-default.tcl
tcl/lib/ns-lib.tcl tcl/lib/ns-mobilenode.tcl tcl/lib/ns-packet.tcl |
These require changes in many places in the files:
- Add default values for the physical layer and the propagation model to ns-default.tcl
- Make the modulation module part of the node object ns-lib.tcl and ns-mobilenode.tcl
- Add the MAC IFControl packet header to ns-packet.tcl
We therefore provide a patch. Download patch.tcl.lib to the main ns-2 directory
(ns-2.26) and call patch -Np0 < patch.tcl.lib.
|
mobile/modulation.h
mobile/modulation.cc |
replace the old modulation.{h,cc} (which didn't provide any
functionality and were not used)
|
mobile/mod_codedppm.h
mobile/mod_codedppm.cc
mobile/ppm.cc |
add mobile/mod_codedppm.{h,cc} which provide the calculation
of the bit error rate given PPM modulation and a channel code and
the BER function table mobile/ppm.cc
|
mobile/propagation-tarokh.h
mobile/propagation-tarokh.cc |
add the UWB propagation model
|
mac/interference-phy.h
mac/interference-phy.cc |
add the new UWB physical layer
|
mac/mac-ifcontrol.h
mac/mac-ifcontrol.cc |
add the new UWB MAC layer
|
| mac/phy.h |
replace void recv(Packet* p, Handler* h); by virtual void recv(Packet* p, Handler* h);
|
| mac/wireless-phy.h |
replace
void sendDown(Packet *p);
int sendUp(Packet *p);
by
virtual void sendDown(Packet *p);
virtual int sendUp(Packet *p);
and move
EnergyModel* em() { return node()->energy_model(); }
inline int initialized() {
return (node_ && uptarget_ && downtarget_ && propagation_);
}
from the private to the protected section.
|