author | Budiarto Herman <budiarto.herman@magister.fi> |
Mon, 29 Jul 2013 11:38:13 +0300 | |
changeset 10301 | d527fc67106d |
parent 10300 | 792cecb6cf2d |
child 10312 | d37b9d88c6f1 |
permissions | -rw-r--r-- |
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
1 |
/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
2 |
/* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
3 |
* Copyright (c) 2012 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC) |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
4 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
5 |
* This program is free software; you can redistribute it and/or modify |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
6 |
* it under the terms of the GNU General Public License version 2 as |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
7 |
* published by the Free Software Foundation; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
8 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
9 |
* This program is distributed in the hope that it will be useful, |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
10 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
11 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
12 |
* GNU General Public License for more details. |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
13 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
14 |
* You should have received a copy of the GNU General Public License |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
15 |
* along with this program; if not, write to the Free Software |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
16 |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
17 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
18 |
* Author: Nicola Baldo <nbaldo@cttc.es> |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
19 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
20 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
21 |
#ifndef EPC_UE_NAS_H |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
22 |
#define EPC_UE_NAS_H |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
23 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
24 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
25 |
#include <ns3/object.h> |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
26 |
#include <ns3/lte-as-sap.h> |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
27 |
#include <ns3/epc-tft-classifier.h> |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
28 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
29 |
namespace ns3 { |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
30 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
31 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
32 |
class EpcHelper; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
33 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
34 |
class EpcUeNas : public Object |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
35 |
{ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
36 |
friend class MemberLteAsSapUser<EpcUeNas>; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
37 |
public: |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
38 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
39 |
/** |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
40 |
* Constructor |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
41 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
42 |
EpcUeNas (); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
43 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
44 |
/** |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
45 |
* Destructor |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
46 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
47 |
virtual ~EpcUeNas (); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
48 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
49 |
// inherited from Object |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
50 |
virtual void DoDispose (void); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
51 |
static TypeId GetTypeId (void); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
52 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
53 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
54 |
/** |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
55 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
56 |
* \param dev the UE NetDevice |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
57 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
58 |
void SetDevice (Ptr<NetDevice> dev); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
59 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
60 |
/** |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
61 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
62 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
63 |
* \param imsi the unique UE identifier |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
64 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
65 |
void SetImsi (uint64_t imsi); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
66 |
|
10300
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
67 |
/** |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
68 |
* |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
69 |
* \param csgId Closed Subscriber Group identity |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
70 |
*/ |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
71 |
void SetCsgId (uint32_t csgId); |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
72 |
|
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
73 |
/** |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
74 |
* |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
75 |
* \return csgId Closed Subscriber Group identity |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
76 |
*/ |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
77 |
uint32_t GetCsgId () const; |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
78 |
|
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
79 |
/** |
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
80 |
* Set the AS SAP provider to interact with the NAS entity |
10300
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
81 |
* |
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
82 |
* \param s the AS SAP provider |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
83 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
84 |
void SetAsSapProvider (LteAsSapProvider* s); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
85 |
|
10300
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
86 |
/** |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
87 |
* |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
88 |
* |
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
89 |
* \return the AS SAP user exported by this RRC |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
90 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
91 |
LteAsSapUser* GetAsSapUser (); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
92 |
|
10300
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
93 |
/** |
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
94 |
* set the callback used to forward data packets up the stack |
10300
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
95 |
* |
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
96 |
* \param cb the callback |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
97 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
98 |
void SetForwardUpCallback (Callback <void, Ptr<Packet> > cb); |
10300
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
99 |
|
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
100 |
/** |
10296
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
101 |
* \brief Instruct the NAS to go to ACTIVE state |
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
102 |
* |
10296
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
103 |
* The end result is equivalent with EMM Registered + ECM Connected states. |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
104 |
* If this function is called when the UE is in a situation where connecting |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
105 |
* is not possible (e.g. before the simulation begin), then the UE will |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
106 |
* attempt to connect at the earliest possible time (e.g. after it camps to a |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
107 |
* suitable cell). |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
108 |
*/ |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
109 |
void Connect (); |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
110 |
|
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
111 |
/** |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
112 |
* \brief Instruct the NAS to camp to a specific cell and go to ACTIVE state. |
9430
e8b87593ee5b
added MME with simulated S1AP and S11 interfaces
Nicola Baldo <nbaldo@cttc.es>
parents:
9406
diff
changeset
|
113 |
* \param cellId the id of the eNB to camp on |
e8b87593ee5b
added MME with simulated S1AP and S11 interfaces
Nicola Baldo <nbaldo@cttc.es>
parents:
9406
diff
changeset
|
114 |
* \param earfcn the DL frequency of the eNB |
10296
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
115 |
* |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
116 |
* The end result is equivalent with EMM Registered + ECM Connected states. |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
117 |
* Since RRC Idle Mode cell selection is not supported yet, we force the UE |
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
118 |
* RRC to be camped on a specific eNB. |
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
119 |
*/ |
9430
e8b87593ee5b
added MME with simulated S1AP and S11 interfaces
Nicola Baldo <nbaldo@cttc.es>
parents:
9406
diff
changeset
|
120 |
void Connect (uint16_t cellId, uint16_t earfcn); |
9406 | 121 |
|
122 |
/** |
|
123 |
* instruct the NAS to disconnect |
|
124 |
* |
|
125 |
*/ |
|
126 |
void Disconnect (); |
|
127 |
||
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
128 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
129 |
/** |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
130 |
* Activate an EPS bearer |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
131 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
132 |
* \param bearer the characteristics of the bearer to be created |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
133 |
* \param tft the TFT identifying the traffic that will go on this bearer |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
134 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
135 |
void ActivateEpsBearer (EpsBearer bearer, Ptr<EpcTft> tft); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
136 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
137 |
/** |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
138 |
* Enqueue an IP packet on the proper bearer for uplink transmission |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
139 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
140 |
* \param p the packet |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
141 |
* |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
142 |
* \return true if successful, false if an error occurred |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
143 |
*/ |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
144 |
bool Send (Ptr<Packet> p); |
9406 | 145 |
|
146 |
||
147 |
/** |
|
148 |
* Definition of NAS states as per "LTE - From theory to practice", |
|
149 |
* Section 3.2.3.2 "Connection Establishment and Release" |
|
150 |
* |
|
151 |
*/ |
|
152 |
enum State |
|
10301
d527fc67106d
Removed PLMN from LTE cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10300
diff
changeset
|
153 |
{ |
d527fc67106d
Removed PLMN from LTE cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10300
diff
changeset
|
154 |
OFF = 0, |
d527fc67106d
Removed PLMN from LTE cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10300
diff
changeset
|
155 |
ATTACHING, |
d527fc67106d
Removed PLMN from LTE cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10300
diff
changeset
|
156 |
IDLE_REGISTERED, |
d527fc67106d
Removed PLMN from LTE cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10300
diff
changeset
|
157 |
CONNECTING_TO_EPC, |
d527fc67106d
Removed PLMN from LTE cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10300
diff
changeset
|
158 |
ACTIVE, |
d527fc67106d
Removed PLMN from LTE cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10300
diff
changeset
|
159 |
NUM_STATES |
d527fc67106d
Removed PLMN from LTE cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10300
diff
changeset
|
160 |
}; |
9406 | 161 |
|
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
162 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
163 |
private: |
10296
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
164 |
|
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
165 |
// LTE AS SAP methods |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
166 |
void DoNotifyConnectionSuccessful (); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
167 |
void DoNotifyConnectionFailed (); |
9406 | 168 |
void DoNotifyConnectionReleased (); |
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
169 |
void DoRecvData (Ptr<Packet> packet); |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
170 |
|
9406 | 171 |
// internal methods |
172 |
void DoActivateEpsBearer (EpsBearer bearer, Ptr<EpcTft> tft); |
|
173 |
void SwitchToState (State s); |
|
174 |
||
175 |
State m_state; |
|
176 |
||
177 |
TracedCallback<State, State> m_stateTransitionCallback; |
|
178 |
||
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
179 |
Ptr<NetDevice> m_device; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
180 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
181 |
uint64_t m_imsi; |
10296
13ff285523bf
Generic (not eNodeB-specific) helper functions Attach and Connect
Budiarto Herman <budiarto.herman@magister.fi>
parents:
9430
diff
changeset
|
182 |
|
10300
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
183 |
uint32_t m_csgId; |
792cecb6cf2d
Evaluation of cell selection criteria
Budiarto Herman <budiarto.herman@magister.fi>
parents:
10296
diff
changeset
|
184 |
|
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
185 |
LteAsSapProvider* m_asSapProvider; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
186 |
LteAsSapUser* m_asSapUser; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
187 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
188 |
uint8_t m_bidCounter; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
189 |
EpcTftClassifier m_tftClassifier; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
190 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
191 |
Callback <void, Ptr<Packet> > m_forwardUpCallback; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
192 |
|
9406 | 193 |
struct BearerToBeActivated |
194 |
{ |
|
195 |
EpsBearer bearer; |
|
196 |
Ptr<EpcTft> tft; |
|
197 |
}; |
|
198 |
||
199 |
std::list<BearerToBeActivated> m_bearersToBeActivatedList; |
|
200 |
||
9337
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
201 |
}; |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
202 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
203 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
204 |
} // namespace ns3 |
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
205 |
|
ae7126b266ce
revised LTE protocol stack for new RRC model
Nicola Baldo <nbaldo@cttc.es>
parents:
diff
changeset
|
206 |
#endif // EPC_UE_NAS_H |