Closed joahannes closed 1 year ago
You can set the eNB cell id by
*.enb1.masterId = 1
*.enb2.masterId = 2
note that you can change the enb* name based on your configuration in the NED file
and connect the UE's NIC to the corresponding serving eNB via
*.ue[*].masterId = 1
the connection from the server to the enB can be define in the ned file such:
server.pppg++ <--> Eth10G <--> router.pppg++;
router.pppg++ <--> Eth10G <--> upf.filterGate;
upf.pppg++ <--> Eth10G <--> eNB.ppp;
Hope this helps.
Thanks for the answer.
In my case, I want to collect this information at simulation time (on the fly). If a handover happens and eNodeB changes, I need to know the ID of the new eNodeB serving this UE.
Is it possible?
Hello @SawadaSyahmi,
I managed to get this information using a snippet of code present in apps/d2dMultihop/MultihopD2D.cc
:
// get references to LTE entities
ltePhy_ = check_and_cast<LtePhyBase*>(getParentModule()->getSubmodule("cellularNic")->getSubmodule("phy"));
LteMacBase* mac = check_and_cast<LteMacBase*>(getParentModule()->getSubmodule("cellularNic")->getSubmodule("mac"));
lteNodeId_ = mac->getMacNodeId();
lteCellId_ = mac->getMacCellId();
In this way, I can obtain the ID of the eNodeB that is serving the UE.
Hi all,
How can a UE know the id of the eNodeB it is connected to? Also, can a server know which eNodeB a packet was sent from?
Which way should I go to get the id of the eNodeB both by the UE and by a Server?
Thanks.