A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
lte-rlc-um.h
Go to the documentation of this file.
1
/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC)
4
*
5
* This program is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License version 2 as
7
* published by the Free Software Foundation;
8
*
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17
*
18
* Author: Manuel Requena <manuel.requena@cttc.es>
19
*/
20
21
#ifndef LTE_RLC_UM_H
22
#define LTE_RLC_UM_H
23
24
#include "ns3/lte-rlc-sequence-number.h"
25
26
#include "ns3/lte-rlc.h"
27
28
#include <map>
29
30
namespace
ns3 {
31
35
class
LteRlcUm
:
public
LteRlc
36
{
37
public
:
38
LteRlcUm
();
39
virtual
~LteRlcUm
();
40
static
TypeId
GetTypeId
(
void
);
41
45
virtual
void
DoTransmitPdcpPdu
(
Ptr<Packet>
p);
46
50
virtual
void
DoNotifyTxOpportunity
(uint32_t bytes, uint8_t layer);
51
virtual
void
DoNotifyHarqDeliveryFailure
();
52
virtual
void
DoReceivePdu
(
Ptr<Packet>
p);
53
54
void
Start
();
55
56
private
:
57
void
ExpireReorderingTimer
(
void
);
58
void
ExpireRbsTimer
(
void
);
59
60
bool
IsInsideReorderingWindow
(
SequenceNumber10
seqNumber);
61
62
void
ReassembleOutsideWindow
(
void
);
63
void
ReassembleSnInterval
(
SequenceNumber10
lowSeqNumber,
SequenceNumber10
highSeqNumber);
64
65
void
ReassembleAndDeliver
(
Ptr<Packet>
packet);
66
67
void
DoReportBufferStatus
();
68
69
private
:
70
uint32_t
m_maxTxBufferSize
;
71
uint32_t
m_txBufferSize
;
72
std::vector < Ptr<Packet> >
m_txBuffer
;
// Transmission buffer
73
std::map <uint16_t, Ptr<Packet> >
m_rxBuffer
;
// Reception buffer
74
std::vector < Ptr<Packet> >
m_reasBuffer
;
// Reassembling buffer
75
76
std::list < Ptr<Packet> >
m_sdusBuffer
;
// List of SDUs in a packet
77
81
SequenceNumber10
m_sequenceNumber
;
// VT(US)
82
83
SequenceNumber10
m_vrUr
;
// VR(UR)
84
SequenceNumber10
m_vrUx
;
// VR(UX)
85
SequenceNumber10
m_vrUh
;
// VR(UH)
86
90
uint16_t
m_windowSize
;
91
95
EventId
m_reorderingTimer
;
96
EventId
m_rbsTimer
;
97
101
typedef
enum
{
NONE
= 0,
102
WAITING_S0_FULL
= 1,
103
WAITING_SI_SF
= 2 }
ReassemblingState_t
;
104
ReassemblingState_t
m_reassemblingState
;
105
Ptr<Packet>
m_keepS0
;
106
110
SequenceNumber10
m_expectedSeqNumber
;
111
112
};
113
114
115
}
// namespace ns3
116
117
#endif // LTE_RLC_UM_H
src
lte
model
lte-rlc-um.h
Generated on Fri Dec 21 2012 19:00:39 for ns-3 by
1.8.1.2