LEFT | RIGHT |
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 * This program is free software; you can redistribute it and/or modify | 3 * This program is free software; you can redistribute it and/or modify |
4 * it under the terms of the GNU General Public License version 2 as | 4 * it under the terms of the GNU General Public License version 2 as |
5 * published by the Free Software Foundation; | 5 * published by the Free Software Foundation; |
6 * | 6 * |
7 * This program is distributed in the hope that it will be useful, | 7 * This program is distributed in the hope that it will be useful, |
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 8 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
10 * GNU General Public License for more details. | 10 * GNU General Public License for more details. |
11 * | 11 * |
12 * You should have received a copy of the GNU General Public License | 12 * You should have received a copy of the GNU General Public License |
13 * along with this program; if not, write to the Free Software | 13 * along with this program; if not, write to the Free Software |
14 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 14 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
15 * | 15 * |
16 * Authors: Lalith Suresh <suresh.lalith@gmail.com> | 16 * Authors: Lalith Suresh <suresh.lalith@gmail.com> |
17 */ | 17 */ |
18 | 18 |
19 // Scenario: | 19 // Scenario: |
20 // | 20 // |
21 // (Click) (non-Click) | 21 // (Click) CSMA (non-Click) |
22 // A ======== B | 22 // A ================ B |
23 // CSMA | 23 // (172.16.1.1) (172.16.1.2) |
| 24 // (eth0) |
| 25 // |
24 // | 26 // |
25 | 27 |
26 #include "ns3/core-module.h" | 28 #include "ns3/core-module.h" |
27 #include "ns3/common-module.h" | 29 #include "ns3/common-module.h" |
28 #include "ns3/node-module.h" | 30 #include "ns3/node-module.h" |
29 #include "ns3/helper-module.h" | 31 #include "ns3/helper-module.h" |
30 #include "ns3/log.h" | 32 #include "ns3/log.h" |
31 | 33 |
32 using namespace ns3; | 34 using namespace ns3; |
33 | 35 |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 // For tracing | 90 // For tracing |
89 csma.EnablePcap ("nsclick-simple-lan", csmaDevices, false); | 91 csma.EnablePcap ("nsclick-simple-lan", csmaDevices, false); |
90 | 92 |
91 Simulator::Stop (Seconds(20.0)); | 93 Simulator::Stop (Seconds(20.0)); |
92 Simulator::Run(); | 94 Simulator::Run(); |
93 return 0; | 95 return 0; |
94 #else | 96 #else |
95 NS_FATAL_ERROR ("Can't use ns-3-click without NSCLICK compiled in"); | 97 NS_FATAL_ERROR ("Can't use ns-3-click without NSCLICK compiled in"); |
96 #endif | 98 #endif |
97 } | 99 } |
LEFT | RIGHT |