Commit 04d27b9c authored by Andrew Burger's avatar Andrew Burger

Finalized Raymond changes

parent 898d402a
...@@ -50,6 +50,9 @@ queue_t tx_req_pdu_queue; ...@@ -50,6 +50,9 @@ queue_t tx_req_pdu_queue;
queue_t ul_config_req_queue; queue_t ul_config_req_queue;
queue_t hi_dci0_req_queue; queue_t hi_dci0_req_queue;
int subframe_sf = 0;
int frame_sfn = 0;
void init_queue(queue_t *q) { void init_queue(queue_t *q) {
memset(q, 0, sizeof(*q)); memset(q, 0, sizeof(*q));
pthread_mutex_init(&q->mutex, NULL); pthread_mutex_init(&q->mutex, NULL);
...@@ -1152,14 +1155,11 @@ void *ue_standalone_pnf_task(void *context) ...@@ -1152,14 +1155,11 @@ void *ue_standalone_pnf_task(void *context)
continue; continue;
} }
if (len == 2 && len > 0) if (len == sizeof(uint16_t))
{ {
memcpy((void *)&sfn_sf, buffer, sizeof(sfn_sf)); memcpy((void *)&sfn_sf, buffer, sizeof(sfn_sf));
if (sfn_sf % 300 == 0) subframe_sf = NFAPI_SFNSF2SF(sfn_sf);
{ frame_sfn = NFAPI_SFNSF2SFN(sfn_sf);
LOG_I(MAC, "Unpacked sfn_sf sf: %u sfn: %u\n", NFAPI_SFNSF2SFN(sfn_sf),
NFAPI_SFNSF2SF(sfn_sf));
}
} }
else else
{ {
......
...@@ -156,4 +156,7 @@ extern queue_t hi_dci0_req_queue; ...@@ -156,4 +156,7 @@ extern queue_t hi_dci0_req_queue;
extern nfapi_ul_config_request_t* ul_config_req; extern nfapi_ul_config_request_t* ul_config_req;
extern nfapi_hi_dci0_request_t* hi_dci0_req; extern nfapi_hi_dci0_request_t* hi_dci0_req;
extern int subframe_sf;
extern int frame_sfn;
#endif /* PHY_STUB_UE_H_ */ #endif /* PHY_STUB_UE_H_ */
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment