Add RLC stats
This commit is contained in:
1 parent
bfb47526d8
commit
74ce29e35e
1 file changed
+14
@@ -330,6 +330,11 @@ LteRlcUm::DoNotifyTxOpportunity (uint32_t bytes)
|
||||
NS_LOG_LOGIC ("RLC header: " << rlcHeader);
|
||||
packet->AddHeader (rlcHeader);
|
||||
|
||||
// Sender timestamp
|
||||
RlcTag rlcTag (Simulator::Now ());
|
||||
packet->AddByteTag (rlcTag);
|
||||
m_txPdu (m_rnti, m_lcid, packet->GetSize ());
|
||||
|
||||
// Send RLC PDU to MAC layer
|
||||
LteMacSapProvider::TransmitPduParameters params;
|
||||
params.pdu = packet;
|
||||
@@ -350,6 +355,15 @@ LteRlcUm::DoReceivePdu (Ptr<Packet> p)
|
||||
{
|
||||
NS_LOG_FUNCTION (this);
|
||||
|
||||
// Receiver timestamp
|
||||
RlcTag rlcTag;
|
||||
Time delay;
|
||||
if (p->FindFirstMatchingByteTag (rlcTag))
|
||||
{
|
||||
delay = Simulator::Now() - rlcTag.GetSenderTimestamp ();
|
||||
}
|
||||
m_rxPdu(m_rnti, m_lcid, p->GetSize (), delay.GetNanoSeconds ());
|
||||
|
||||
// 5.1.2.2 Receive operations
|
||||
|
||||
// Get RLC header parameters
|
||||
|
||||
Reference in new issue
Block a user