Get RSRP (or SINR) value during a LENA simulation

508 views
Skip to first unread message

Marco Giordani

unread,
Jul 20, 2015, 10:05:54 AM7/20/15
to ns-3-...@googlegroups.com

Hi everybody, 

I am simulating a LENA scenario where, at a certain point, I need to access the RSRP (or the SINR) value of a particular user. 

This value is automatically saved in a .txt file, when enabling the DlPhyTraces, but I don't know how to save the value of RSRP into a variable, in the code, without parsing it from the text file.


Can somebody help me? How can I get this value?


Thank you.

Marco

Konstantinos

unread,
Jul 20, 2015, 10:14:59 AM7/20/15
to ns-3-...@googlegroups.com, m.gior...@gmail.com
Hi Marco,

Try looking at how these files are created.
In principle they use the tracing system and hook at trace sources on the PHY. 
You can connect to the same trace source and save the values to variables. 


Regards,
K.

Marco Giordani

unread,
Jul 20, 2015, 10:34:30 AM7/20/15
to ns-3-...@googlegroups.com, m.gior...@gmail.com
Thanks Konstantinos for your answer.

Anyway, when enabling the traces, it is called the method "ReportCurrentCellRsrpSinrCallback" which requires, among the others, also the RSRP value, that is actually what I need. 
I cannot even get the object m_phyStats (that is passed when enabling the DlPhyTraces), since it is a private element.

I also tried to look in the LENA documentation but all the objects that save, somewhere, the RSRP values (such as in the module LteUePhy) are private, so I cannot access them.
Any hint?

Konstantinos

unread,
Jul 20, 2015, 10:51:08 AM7/20/15
to ns-3-...@googlegroups.com, m.gior...@gmail.com
Hi,

What I was refering to is actually this part of the code in lte-helper.cc

1213 void
1215 {
1217  Config::Connect ("/NodeList/*/DeviceList/*/LteUePhy/ReportCurrentCellRsrpSinr",
1219 }

You can see that the ReportCurrrentRsrpSinrCallback is fired when the "/NodeList/*/DeviceList/*/LteUePhy/ReportCurrentCellRsrpSinr" trace source is fired.
Can have a similar 'Config::Connect ( ... )' method that instead of calling the ReportCurrentRsrpSinrCallback, it will call your own method that will add the information[1] that this trace source carries to variables.  

[1] the signature for that trace source
typedef void(* ns3::LteUePhy::RsrpSinrTracedCallback) (const uint16_t cellId, const uint16_t rnti, const double rsrp, const double sinr)

TracedCallback signature for cell RSRP and SINR report.

Parameters
[in]cellId
[in]rnti
[in]rsrp
[in]sinr

Definition at line 259 of file lte-ue-phy.h.

Marco Giordani

unread,
Jul 20, 2015, 4:48:09 PM7/20/15
to ns-3-...@googlegroups.com
Thank you.
Maybe this can be a little tricky for me but I will try to implement your valid advices.

Thank you for your time.
Marco

--
You received this message because you are subscribed to a topic in the Google Groups "ns-3-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/ns-3-users/askTrnmnGYU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to ns-3-users+...@googlegroups.com.
To post to this group, send email to ns-3-...@googlegroups.com.
Visit this group at http://groups.google.com/group/ns-3-users.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages