Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
oai
openairinterface5G
Commits
b9130280
Commit
b9130280
authored
Jan 10, 2014
by
winckel
Browse files
Test LTE dongle.
git-svn-id:
http://svn.eurecom.fr/openair4G/trunk@4842
818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent
ca98864c
Changes
3
Hide whitespace changes
Inline
Side-by-side
openair2/LAYER2/RLC/AM_v9.3.0/rlc_am_receiver.c
View file @
b9130280
...
...
@@ -42,6 +42,7 @@ Address : Eurecom, 2229, route des crêtes, 06560 Valbonne Sophia Antipolis
//#define DEBUG_RLC_AM_DISPLAY_TB_DATA
//#define RLC_AM_GENERATE_ERRORS
#define DEBUG_DISPLAY_NVIDIA
#define RLC_ENABLE_PDU_CONCATENATION
//-----------------------------------------------------------------------------
signed
int
rlc_am_get_data_pdu_infos
(
u32_t
frame
,
rlc_am_pdu_sn_10_t
*
headerP
,
s16_t
total_sizeP
,
rlc_am_pdu_info_t
*
pdu_infoP
)
//-----------------------------------------------------------------------------
...
...
@@ -219,7 +220,7 @@ rlc_am_receive_routing (rlc_am_entity_t *rlcP, u32_t frame, u8_t eNB_flag, struc
}
else
{
rlcP
->
stat_rx_control_bytes
+=
tb_size_in_bytes
;
rlcP
->
stat_rx_control_pdu
+=
1
;
rlc_am_receive_process_control_pdu
(
rlcP
,
frame
,
tb
,
first_byte
,
&
tb_size_in_bytes
);
rlc_am_receive_process_control_pdu
(
rlcP
,
frame
,
tb
,
&
first_byte
,
&
tb_size_in_bytes
);
// if data pdu concatenated with control PDU (seen with real hardware LTE dongle integration)
if
(
tb_size_in_bytes
>
0
)
{
#if defined(RLC_ENABLE_PDU_CONCATENATION)
...
...
openair2/LAYER2/RLC/AM_v9.3.0/rlc_am_status_report.c
View file @
b9130280
...
...
@@ -125,7 +125,7 @@ signed int rlc_am_get_control_pdu_infos(rlc_am_pdu_sn_10_t* headerP, s16_t *tota
if
(
pdu_infoP
->
cpt
!=
0x00
)
return
-
3
;
pdu_infoP
->
ack_sn
=
((
headerP
->
b2
>>
2
)
&
0x3F
)
|
(((
u16_t
)(
headerP
->
b1
&
0x0F
))
<<
6
);
pdu_infoP
->
e1
=
(
headerP
->
b2
>>
1
)
&
0x01
;
*
total_size_pP
-=
1
;
//
*total_size_pP -= 1;
if
(
pdu_infoP
->
e1
)
{
unsigned
int
nack_to_read
=
1
;
...
...
@@ -192,11 +192,12 @@ void rlc_am_display_control_pdu_infos(rlc_am_control_pdu_info_t* pdu_infoP)
}
}
//-----------------------------------------------------------------------------
void
rlc_am_receive_process_control_pdu
(
rlc_am_entity_t
*
rlcP
,
u32_t
frame
,
mem_block_t
*
tbP
,
u8_t
*
first_byteP
,
s16_t
*
tb_size_in_bytes_pP
)
void
rlc_am_receive_process_control_pdu
(
rlc_am_entity_t
*
rlcP
,
u32_t
frame
,
mem_block_t
*
tbP
,
u8_t
*
*
first_byteP
,
s16_t
*
tb_size_in_bytes_pP
)
//-----------------------------------------------------------------------------
{
//rlc_am_control_pdu_info_t* pdu_info = ((rlc_am_control_pdu_info_t*)(tbP->data));
rlc_am_pdu_sn_10_t
*
rlc_am_pdu_sn_10
=
(
rlc_am_pdu_sn_10_t
*
)
first_byteP
;
rlc_am_pdu_sn_10_t
*
rlc_am_pdu_sn_10
=
(
rlc_am_pdu_sn_10_t
*
)
*
first_byteP
;
s16_t
initial_pdu_size
=
*
tb_size_in_bytes_pP
;
if
(
rlc_am_get_control_pdu_infos
(
rlc_am_pdu_sn_10
,
tb_size_in_bytes_pP
,
&
g_rlc_am_control_pdu_info
)
>=
0
)
{
...
...
@@ -282,6 +283,8 @@ void rlc_am_receive_process_control_pdu(rlc_am_entity_t* rlcP, u32_t frame, mem_
}
else
{
LOG_W
(
RLC
,
"[FRAME %05d][RLC_AM][MOD %02d][RB %02d] ERROR IN DECODING CONTROL PDU
\n
"
,
frame
,
rlcP
->
module_id
,
rlcP
->
rb_id
);
}
*
first_byteP
=
(
u8_t
*
)((
uint64_t
)
*
first_byteP
+
initial_pdu_size
-
*
tb_size_in_bytes_pP
);
free_mem_block
(
tbP
);
rlc_am_tx_buffer_display
(
rlcP
,
frame
,
NULL
);
}
...
...
openair2/LAYER2/RLC/AM_v9.3.0/rlc_am_status_report.h
View file @
b9130280
...
...
@@ -114,7 +114,7 @@ protected_rlc_am_status_report( void rlc_am_display_control_pdu_infos(rlc_am_con
* \param[in] first_byte Pointer on first byte of control PDU.
* \param[in] tb_size_in_bytes Pointer on size of serialized control PDU in bytes.
*/
protected_rlc_am_status_report
(
void
rlc_am_receive_process_control_pdu
(
rlc_am_entity_t
*
rlcP
,
u32_t
frame
,
mem_block_t
*
tbP
,
u8_t
*
first_byte
,
s16_t
*
tb_size_in_bytes
);)
protected_rlc_am_status_report
(
void
rlc_am_receive_process_control_pdu
(
rlc_am_entity_t
*
rlcP
,
u32_t
frame
,
mem_block_t
*
tbP
,
u8_t
*
*
first_byte
,
s16_t
*
tb_size_in_bytes
);)
/*! \fn int rlc_am_write_status_pdu(u32_t frame,rlc_am_pdu_sn_10_t* rlc_am_pdu_sn_10P, rlc_am_control_pdu_info_t* pdu_infoP)
* \brief Remove all marked holes for PDU with sequence number "snP".
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment