Bug 2314 - "vanet-routing-compare" example cannot support multi-channel switch
"vanet-routing-compare" example cannot support multi-channel switch
Status: PATCH PENDING
Product: ns-3
Classification: Unclassified
Component: wave module
unspecified
PC Linux
: P5 enhancement
Assigned To: ns-bugs
:
: 2489 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2016-02-29 03:37 EST by Junling Bu
Modified: 2016-09-23 11:25 EDT (History)
3 users (show)

See Also:


Attachments
The patch for "vanet-routing-compare" example cannot support multi-channel switch (5.02 KB, patch)
2016-02-29 03:37 EST, Junling Bu
Details | Diff
The patch for vanet-routing-comare.cc (3.25 KB, patch)
2016-09-23 07:51 EDT, Junling Bu
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Junling Bu 2016-02-29 03:37:45 EST
Created attachment 2310 [details]
The patch for "vanet-routing-compare" example cannot support multi-channel switch

Odongo Steven, who is the user of ns3 wave module, reported that the example "vanet-routing-compare" cannot support multi-channel switch well.
I created the patch and sented to him. Finally he confirmed that he can get what he wants currently.

This patch will affect the wifi module a littile. But I think it is OK since wifi "IsBusy" function should consider CCA busy.

diff -r ff532caf9e15 src/wifi/model/dcf-manager.cc
--- a/src/wifi/model/dcf-manager.cc	Sun Feb 28 22:50:25 2016 +0100
+++ b/src/wifi/model/dcf-manager.cc	Mon Feb 29 16:21:43 2016 +0800
@@ -474,6 +474,12 @@
     {
       return true;
     }
+  // CCA busy
+  Time lastBusyEnd = m_lastBusyStart + m_lastBusyDuration;
+  if (lastBusyEnd >= Simulator::Now ())
+    {
+      return true;
+    }

Moreover, this patch has been tested by using the newest ns-3-dev 11941:ff532caf9e15. So it should be ready for merging.

Junling.
Comment 1 sebastien.deronne 2016-02-29 04:01:42 EST
A similar fix for DCF is proposed in bug 2306.

I still need to verify this one, and we agreed to postpone its delivery after ns-3.25 release.
Comment 2 Junling Bu 2016-02-29 04:46:36 EST
(In reply to sebastien.deronne from comment #1)
> A similar fix for DCF is proposed in bug 2306.
> 
> I still need to verify this one, and we agreed to postpone its delivery
> after ns-3.25 release.

Hi,

Ok, I also find this modification will make two test cases crashed.

340 of 354 tests passed (340 passed, 10 skipped, 2 failed, 2 crashed, 0 valgrind errors)
List of SKIPped tests:
    examples/routing/simple-routing-ping6.py
    examples/tutorial/first.py
    examples/wireless/mixed-wireless.py
    examples/wireless/wifi-ap.py
    ns3-tcp-cwnd
    ns3-tcp-interoperability
    nsc-tcp-loss
    src/bridge/examples/csma-bridge.py
    src/core/examples/sample-simulator.py
    src/flow-monitor/examples/wifi-olsr-flowmon.py
List of FAILed tests:
    devices-mesh-dot11s-regression
    routing-aodv-regression
List of CRASHed tests:
    devices-wifi-dcf
    power-rate-adaptation-wifi

Moreover, my modification requires "if (lastBusyEnd >= Simulator::Now ())" instead of "if (lastBusyEnd >= Simulator::Now ())".
Because the current WAVE module is heavily based on " >= " rather than " > ".

Ok, I will be interested in any information about "IsBusy".

Thanks.
Comment 3 Adarsh Patel 2016-09-08 06:00:12 EDT
*** Bug 2489 has been marked as a duplicate of this bug. ***
Comment 4 Adarsh Patel 2016-09-08 06:04:28 EDT
I applied patch provided by Junling for this (2314) bug, but it is failing for simulation time 100 and different number of nodes.
Comment 5 Junling Bu 2016-09-23 07:51:22 EDT
Created attachment 2597 [details]
The patch for vanet-routing-comare.cc
Comment 6 Junling Bu 2016-09-23 07:55:01 EDT
Now this patch has a similar part with the patch for bug 2306.
So I'd like to wait for the result of bug 2306.
Comment 7 Tom Henderson 2016-09-23 11:25:05 EDT
I am working on a revised patch for 2306.  Once that is committed, we can evaluate whether the rest of this patch is still compatible or needs further work.