Bugzilla – Bug 178
Randow Walk Sample Incorrect
Last modified: 2008-07-01 13:32:30 UTC
As far as I can tell, there are three things wrong with samples/main-random-walk.cc currently: - The Bounds attribute was changed to a Rectangle, and does not work with the strings used in the sample. - The given default bounds fail as the nodes are positioned outside of it. - The course change trace source has been removed. I'll attach a patch which fixes the sample in a second, though I'm somewhat surprised at the apparent loss of the course change trace. Thx
Created attachment 132 [details] Changes defaults, removes course change.
So, yes, there were some issues: - Somewhere along the line the syntax for rectangle strings changed from colons to pipes. - The bounds did have to change, nodes were being created outside of them and an assert was failing. - The callback signature was outdated, still using TraceContext instead of std::string. These lead to a couple of changes. In [1] the first two simple issues have been fixed. More importantly though, it also: - Removes some remaining references to TraceContext and TraceResolver throughout the codebase. - Removes MobilityModelNotifier. The CourseChange trace source has now been moved into MobilityModel. The latter may break some people's simulation code, so it has not been pushed directly. In particular, mobility notifications are now done entirely via traces rather than aggregating a notifier object that gets called. Previously you could in theory handle them either way. For most people though, this will hopefully simply involve changing the trace source used and eliminating calls like MobilityHelper::EnableNotifier(). Comments welcome. Thx [1] http://code.nsnam.org/tjkopena/ns-3-dev-nonotifier/
ok for me.
OK with me; do you want ack on the list?
Since Gustavo's on board, seems good to go. I did update [2] to use a more descriptive member name as he asked. If one of you could merge back into main that'd be great (I can't write to ns-3-dev---probably wise---and will be offline most of the day). Merging doesn't seem to cause any problems. Thx [2] http://code.nsnam.org/tjkopena/ns-3-dev-nonotifier/
merged in ns-3-dev.