[ndnSIM] Waypoint Mobility Model

Anthony Dowling dowlinah at clarkson.edu
Wed May 31 10:32:11 PDT 2017


Hello All,

In my research, I am working with ndnSIM, and need to use the Waypoint
Mobility Model, and after reading the documentation, I believe my code is
close, because it compiles, however, when I run it, the node doesn't move
at all. How can I make the Waypoint Mobility Model work correctly? Code is
below.

//#############################################
  MobilityHelper walk;

// sets up the initial position of the walker
  walk.SetPositionAllocator ("ns3::GridPositionAllocator",
    "MinX", DoubleValue (50.0),
    "MinY", DoubleValue (20.0),
    "DeltaX", DoubleValue (20.0),
    "DeltaY", DoubleValue (20.0),
    "GridWidth", UintegerValue (3),
    "LayoutType", StringValue ("RowFirst"));

  ns3::WaypointMobilityModel path1;
  path1.AddWaypoint( Waypoint( Seconds(5.0) , Vector3D( 0.0, 0.0, 0.0) ));
  path1.AddWaypoint( Waypoint( Seconds(10.0) , Vector3D( 40.0, 20.0, 0.0)
));

  walk.SetMobilityModel("ns3::WaypointMobilityModel");
  walk.Install(walker);

//###################################################################

Thanks for your time,
Anthony Dowling
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/ndnsim/attachments/20170531/f368b8d7/attachment.html>


More information about the ndnSIM mailing list