Commit e01a3c06 authored by Nick Ho's avatar Nick Ho

Complete the UL_INDICATION, and the Sched_Rsp structure

parent 4e93618b
...@@ -35,6 +35,16 @@ ...@@ -35,6 +35,16 @@
#include <stdint.h> #include <stdint.h>
#endif #endif
typedef enum DCI_format_NB
{
DCIFormatN0 = 0,
DCIFormatN1,
DCIFormatN1_RA,
DCIFormatN1_RAR,
DCIFormatN2_Ind,
DCIFormatN2_Pag,
}e_DCI_format_NB;
/// DCI Format Type 0 (180 kHz, 23 bits) /// DCI Format Type 0 (180 kHz, 23 bits)
typedef struct DCIFormatN0{ typedef struct DCIFormatN0{
/// type = 0 => DCI Format N0, type = 1 => DCI Format N1, 1 bits /// type = 0 => DCI Format N0, type = 1 => DCI Format N1, 1 bits
...@@ -127,7 +137,7 @@ typedef struct DCIFormatN1_RAR DCIFormatN1_RAR_t; ...@@ -127,7 +137,7 @@ typedef struct DCIFormatN1_RAR DCIFormatN1_RAR_t;
#define sizeof_DCIFormatN1_RAR_t 23 #define sizeof_DCIFormatN1_RAR_t 23
// DCI Format Type N2 for direct indication, 15 bits // DCI Format Type N2 for direct indication, 15 bits
struct DCIFormat2_Ind{ struct DCIFormatN2_Ind{
//Flag for paging(1)/direct indication(0), set to 0,1 bits //Flag for paging(1)/direct indication(0), set to 0,1 bits
uint8_t type; uint8_t type;
//Direct indication information, 8 bits //Direct indication information, 8 bits
...@@ -136,11 +146,11 @@ struct DCIFormat2_Ind{ ...@@ -136,11 +146,11 @@ struct DCIFormat2_Ind{
uint8_t resInfoBits; uint8_t resInfoBits;
}; };
typedef struct DCIFormat2_Ind DCIFormat2_Ind_t; typedef struct DCIFormatN2_Ind DCIFormatN2_Ind_t;
#define sizeof_DCIFormat2_Ind_t 15 #define sizeof_DCIFormatN2_Ind_t 15
// DCI Format Type N2 for Paging, 15 bits // DCI Format Type N2 for Paging, 15 bits
struct DCIFormat2_Pag{ struct DCIFormatN2_Pag{
//Flag for paging(1)/direct indication(0), set to 1,1 bits //Flag for paging(1)/direct indication(0), set to 1,1 bits
uint8_t type; uint8_t type;
// Resourse Assignment (RU Assignment), 3 bits // Resourse Assignment (RU Assignment), 3 bits
...@@ -153,8 +163,8 @@ struct DCIFormat2_Pag{ ...@@ -153,8 +163,8 @@ struct DCIFormat2_Pag{
uint8_t DCIRep; uint8_t DCIRep;
}; };
typedef struct DCIFormat2_Pag DCIFormat2_Pagt; typedef struct DCIFormatN2_Pag DCIFormatN2_Pag_t;
#define sizeof_DCIFormat2_Pag_t 15 #define sizeof_DCIFormatN2_Pag_t 15
// struct DCI0_5MHz_TDD0 { // struct DCI0_5MHz_TDD0 {
// /// type = 0 => DCI Format 0, type = 1 => DCI Format 1A // /// type = 0 => DCI Format 0, type = 1 => DCI Format 1A
......
...@@ -7,72 +7,102 @@ ...@@ -7,72 +7,102 @@
*/ */
#include "platform_types.h" #include "platform_types.h"
#include "openair1/PHY/LTE_TRANSPORT/dci_nb_iot.h"
#define NUMBER_OF_UE_MAX 20 #define NUMBER_OF_UE_MAX 20
typedef struct{ typedef struct{
//flag to show which message is //flag to show which message is
uint8_t UL_MSG_flag; uint8_t UL_MSG_flag;
//preamble part //rnti
//index of the preamble rnti_t rntiP;
uint16_t preamble_index; //Pointer to sdu
//timing offset by PHY uint8_t *sdu;
int16_t timing_offset; //Pointer to sdu length
uint16_t sdu_lenP;
//ULSCH SDU part //HARQ ID
int harq_pidP;
//rnti //MSG3 flag
rnti_t rntiP; uint8_t *msg3_flagP;
//Pointer to sdu //ACK/NAK
uint8_t *sdu; boolean_t NAK;
//Pointer to sdu length
uint16_t sdu_lenP;
//HARQ ID
int harq_pidP;
//MSG3 flag
uint8_t *msg3_flagP;
//ACK/NAK
boolean_t NAK;
}UL_SPEC_t; }UL_SPEC_t;
//UL_IND //UL_IND
typedef struct{ typedef struct{
/*Start at the common part*/
int test; /*Start at the common part*/
int test;
//Module ID
module_id_t module_id;
//CC ID
int CC_id;
//frame
frame_t frame;
//subframe
sub_frame_t subframe;
//Number of availble UE
int UE_NUM;
//Module ID /*preamble part*/
module_id_t module_id; //index of the preamble
//CC ID uint16_t preamble_index;
int CC_id; //timing offset by PHY
//frame int16_t timing_offset;
frame_t frame;
//subframe
sub_frame_t subframe;
//Number of availble UE
int UE_NUM;
/*UE specific part*/ /*UE specific part*/
UL_SPEC_t UL_SPEC_Info[NUMBER_OF_UE_MAX];
UL_SPEC_t UL_SPEC_Info[NUMBER_OF_UE_MAX]; }UL_IND_t;
}UL_IND_t; typedef struct{
/*Interface for uplink, transmitting the Preamble(list), ULSCH SDU, ACK/NACK, Tick (trigger scheduler) /*Common part*/
*Parameters: module_id_t module_idP;
*Parameters: int CC_id;
frame_t frameP;
sub_frame_t subframeP;
rnti_t rntiP;
/*Downlink data*/
//TB size for Downlink data
uint8_t TBindex;
//PDU for MIB,SIBs
uint8_t *BCCH_pdu_payload;
//PDU for DL-SCH
uint8_t *DLSCH_pdu_payload;
/*DCI start*/
// Format of DCI
uint8_t DCI_Format;
//
DCIFormatN0_t DCIN0;
//
DCIFormatN1_t DCIN1;
//
DCIFormatN1_RA_t DCIN1_RA;
//
DCIFormatN1_RAR_t DCIN1_RAR;
//
DCIFormatN2_Ind_t DCIN2_Ind;
//
DCIFormatN2_Pag_t DCIN2_Pag;
}Sched_Rsp_t;
/*Interface for uplink, transmitting the Preamble(list), ULSCH SDU, NAK, Tick (trigger scheduler)
*/ */
void UL_indication(UL_IND_t UL_INFO, frame_t frame, sub_frame_t subframe, module_id_t module_id); void UL_indication(UL_IND_t UL_INFO, frame_t frame, sub_frame_t subframe, module_id_t module_id);
/*Interface for Downlink, transmitting the DLSCH SDU, DCI SDU*/ /*Interface for Downlink, transmitting the DLSCH SDU, DCI SDU*/
void Schedule_Response(); void Schedule_Response(Sched_Rsp_t Sched_INFO);
/*Interface for Configuration*/ /*Interface for Configuration*/
void Config_Request(); //void Config_Request();
...@@ -31,7 +31,7 @@ Functions: NB_initiate_ra_proc() ...@@ -31,7 +31,7 @@ Functions: NB_initiate_ra_proc()
5/15 5/15
modified: openair1/PHY/LTE_TRANSPORT/dci_nb_iot.h modified: openair1/PHY/LTE_TRANSPORT/dci_nb_iot.h
modified: openair1/PHY/LTE_TRANSPORT/defs.h modified: openair1/PHY/LTE_TRANSPORT/defs.hod
modified: openair2/LAYER2/MAC/eNB_scheduler_RA_nb_iot.c modified: openair2/LAYER2/MAC/eNB_scheduler_RA_nb_iot.c
modified: openair2/LAYER2/MAC/proto_nb_iot.h modified: openair2/LAYER2/MAC/proto_nb_iot.h
...@@ -41,7 +41,7 @@ Parameters: Add DCI unpacked format ...@@ -41,7 +41,7 @@ Parameters: Add DCI unpacked format
5/16 5/16
Add: openair2/LAYER2/MAC/IF_Module_nb_iot.c Add: openair2/LAYER2/MAC/IF_Module_nb_iot.c
Add: openair2/PHY_Interface/IF_Module_nb_iot.h Add: openair2/PHY_INTERFACE/IF_Module_nb_iot.h
Add: openair1/PHY/sched/phy_procedures_lte_eNB_nb_iot.c Add: openair1/PHY/sched/phy_procedures_lte_eNB_nb_iot.c
Comment: Modify NB_phy_procedures_uespec_RX, change the way using primitive, use UL_IND data structure to store the needed parameters. Comment: Modify NB_phy_procedures_uespec_RX, change the way using primitive, use UL_IND data structure to store the needed parameters.
...@@ -49,4 +49,12 @@ Comment: Modify NB_phy_procedures_uespec_RX, change the way using primitive, use ...@@ -49,4 +49,12 @@ Comment: Modify NB_phy_procedures_uespec_RX, change the way using primitive, use
Functions: NB_phy_procedures_uespec_RX(), UL_INDICATION() Functions: NB_phy_procedures_uespec_RX(), UL_INDICATION()
Parameters: UL_IND for Interface Module Parameters: UL_IND for Interface Module
5/18
Modified: openair1/PHY/LTE_TRANSPORT/dci_nb_iot.h
Modified: openair2/PHY_INTERFACE/IF_Module_nb_iot.h
Modified: openair2/LAYER2/MAC/IF_Module_nb_iot.c
Comment: Complete the UL_INDICATION
Functions: UL_INDICATION()
Parameters: Sched_Rsp for Interface Module
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