diff --git a/examples/csma/csma-bridge.py b/examples/csma/csma-bridge.py index 9dd1330d7..31d654dcc 100644 --- a/examples/csma/csma-bridge.py +++ b/examples/csma/csma-bridge.py @@ -123,9 +123,8 @@ def main(argv): # Trace output will be sent to the file "csma-bridge.tr" # #print "Configure Tracing." - #std.ofstream ascii - #ascii.open("csma-bridge.tr") - #CsmaHelper.EnableAsciiAll(ascii) + #ascii = ns3.AsciiTraceHelper(); + #csma.EnableAsciiAll(ascii.CreateFileStream ("csma-bridge.tr")); # # Also configure some tcpdump traces; each interface will be traced. diff --git a/examples/routing/nms-p2p-nix.cc b/examples/routing/nms-p2p-nix.cc index 6bf8fb137..b23bd50b7 100644 --- a/examples/routing/nms-p2p-nix.cc +++ b/examples/routing/nms-p2p-nix.cc @@ -428,17 +428,6 @@ main (int argc, char *argv[]) TIMER_NOW (routingEnd); cout << "Routing tables population took " << TIMER_DIFF (routingEnd, routingStart) << endl; -#if 0 - std::ofstream ascii; - ascii.open("nms_p2p_nix.tr"); - PointToPointHelper::EnableAsciiAll(ascii); - CsmaHelper::EnableAsciiAll(ascii); -#endif - -#if 0 - PointToPointHelper::EnablePcapAll("nms_p2p"); - CsmaHelper::EnablePcapAll("nms_csma"); -#endif Simulator::ScheduleNow (Progress); cout << "Running simulator..." << endl; diff --git a/examples/wireless/mixed-wireless.py b/examples/wireless/mixed-wireless.py index eb7a63165..1b3edecca 100644 --- a/examples/wireless/mixed-wireless.py +++ b/examples/wireless/mixed-wireless.py @@ -316,9 +316,10 @@ def main(argv): # Let's set up some ns-2-like ascii traces, using another helper class # #std.ofstream ascii - #ascii.open("mixed-wireless.tr") - #WifiHelper.EnableAsciiAll(ascii) - #CsmaHelper.EnableAsciiAll(ascii) + #ascii = ns3.AsciiTraceHelper(); + #stream = ascii.CreateFileStream("mixed-wireless.tr"); + #wifiPhy.EnableAsciiAll(stream); + #csma.EnableAsciiAll(stream); print "(tracing not done for Python)" # Look at nodes 11, 13 only # WifiHelper.EnableAscii(ascii, 11, 0);