OLD | NEW |
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ | 1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ |
2 /* | 2 /* |
3 * Copyright (c) 2009 The Boeing Company | 3 * Copyright (c) 2009 The Boeing Company |
4 * | 4 * |
5 * This program is free software; you can redistribute it and/or modify | 5 * This program is free software; you can redistribute it and/or modify |
6 * it under the terms of the GNU General Public License version 2 as | 6 * it under the terms of the GNU General Public License version 2 as |
7 * published by the Free Software Foundation; | 7 * published by the Free Software Foundation; |
8 * | 8 * |
9 * This program is distributed in the hope that it will be useful, | 9 * This program is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
160 Simulator::Destroy (); | 160 Simulator::Destroy (); |
161 | 161 |
162 return m_pktsTotal; | 162 return m_pktsTotal; |
163 } | 163 } |
164 | 164 |
165 int main (int argc, char *argv[]) | 165 int main (int argc, char *argv[]) |
166 { | 166 { |
167 std::ofstream outfile ("clear-channel.plt"); | 167 std::ofstream outfile ("clear-channel.plt"); |
168 std::vector <std::string> modes; | 168 std::vector <std::string> modes; |
169 | 169 |
170 modes.push_back ("wifib-1mbs"); | 170 modes.push_back ("DsssRate1Mbps"); |
171 modes.push_back ("wifib-2mbs"); | 171 modes.push_back ("DsssRate2Mbps"); |
172 modes.push_back ("wifib-5.5mbs"); | 172 modes.push_back ("DsssRate5_5Mbps"); |
173 modes.push_back ("wifib-11mbs"); | 173 modes.push_back ("DsssRate11Mbps"); |
174 // disable fragmentation | 174 // disable fragmentation |
175 Config::SetDefault ("ns3::WifiRemoteStationManager::FragmentationThreshold", S
tringValue ("2200")); | 175 Config::SetDefault ("ns3::WifiRemoteStationManager::FragmentationThreshold", S
tringValue ("2200")); |
176 Config::SetDefault ("ns3::WifiRemoteStationManager::RtsCtsThreshold", StringVa
lue ("2200")); | 176 Config::SetDefault ("ns3::WifiRemoteStationManager::RtsCtsThreshold", StringVa
lue ("2200")); |
177 | 177 |
178 CommandLine cmd; | 178 CommandLine cmd; |
179 cmd.Parse (argc, argv); | 179 cmd.Parse (argc, argv); |
180 | 180 |
181 Gnuplot gnuplot = Gnuplot ("clear-channel.eps"); | 181 Gnuplot gnuplot = Gnuplot ("clear-channel.eps"); |
182 ·· | 182 ·· |
183 for (uint32_t i = 0; i < modes.size(); i++) | 183 for (uint32_t i = 0; i < modes.size(); i++) |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
220 gnuplot.AddDataset (dataset); | 220 gnuplot.AddDataset (dataset); |
221 } | 221 } |
222 gnuplot.SetTerminal ("postscript eps color enh \"Times-BoldItalic\""); | 222 gnuplot.SetTerminal ("postscript eps color enh \"Times-BoldItalic\""); |
223 gnuplot.SetLegend ("RSS(dBm)", "Number of packets received"); | 223 gnuplot.SetLegend ("RSS(dBm)", "Number of packets received"); |
224 gnuplot.SetExtra ("set xrange [-102:-83]"); | 224 gnuplot.SetExtra ("set xrange [-102:-83]"); |
225 gnuplot.GenerateOutput (outfile); | 225 gnuplot.GenerateOutput (outfile); |
226 outfile.close (); | 226 outfile.close (); |
227 | 227 |
228 return 0; | 228 return 0; |
229 } | 229 } |
OLD | NEW |