mesh: immediate channel access leads to collisions when forwarding frames.
It looks like the issue that we had once did come back. The relevant past issues were:
- https://www.nsnam.org/bugzilla/show_bug.cgi?id=1465
- https://www.nsnam.org/bugzilla/show_bug.cgi?id=555
The problem came back, and the results are the ones in #472 (closed).
I'm attaching an example script by @esoares.pt that shows the problem.
According to @stavallo comments, this is the correct behaviour for WiFi. From what I can read, MCCA could have helped, but as far as I know MCCA is not supported in the current model.
The "solution" is to:
- Add a random delay when forwarding a packet, and
- Write a regression test based on @esoares.pt example to ensure that future code changes don't break the module (again).
About point 1, we should dig into the mesh standard to find out if there are recommended strategies (beside MCCA) and recommended values for delays. I would be mildly surprised if there was no mention of this in the standard.
Edited by Tommaso Pecorella