[ndnSIM] How to get the position of non-mobile nodes?
DJEMAA Adel
a_djemaa at esi.dz
Mon Nov 16 01:09:12 PST 2020
Hi,
Try to use constant mobility model for your static nodes, as follows:
* Ptr<ConstantPositionMobilityModel> Mobility0 =
CreateObject<ConstantPositionMobilityModel> (); Mobility0->SetPosition
(Vector (0, 0, 0)); dev0->GetPhy ()->SetMobility (Mobility0);*
Then, you can retrieve the position of these nodes.
Hope this helps,
Sincerely
Le lun. 16 nov. 2020 à 03:16, zhenliu0603--- via ndnSIM <
ndnsim at lists.cs.ucla.edu> a écrit :
> Hi, everyone,
> I want to get the position of nodes. I got the positon of mobile
> node using *node->GetObject<ns3::MobilityModel> ()->GetPosition() . *But
> I found that it can't be used for the position of the non-mobile nodes. So
> if I use *NodeContainer nodes; nodes.Create(3); *instead of topology map,
> how do I get the position of these nodes?
>
> Thanks,
> LiuZhen
> ------------------------------
> zhenliu0603 at 163.com
> _______________________________________________
> ndnSIM mailing list
> ndnSIM at lists.cs.ucla.edu
> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim
>
--
Mr DJAMA Adel
Phd student
Ecole Militaire Polytechnique
Algiers 16046, ALGERIA
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/ndnsim/attachments/20201116/730d9f6d/attachment-0001.html>
More information about the ndnSIM
mailing list