Fixed pdcch compilation

master
ismagom 11 years ago
parent e41fee4a7d
commit 04172989e7

@ -102,12 +102,12 @@ int dci_format0_add(dci_t *q, dci_format0_t *msg, int L, int nCCE, unsigned shor
int dci_format0_sizeof(int nof_prb);
int dci_format1_add(dci_t *q, dci_format1_t *msg, int L, int nCCE, unsigned short rnti);
int dci_format1_sizeof(int nof_prb);
int dci_format1_sizeof(int nof_prb, int P);
int dci_format1A_add(dci_t *q, dci_format1_t *msg, int L, int nCCE, unsigned short rnti);
int dci_format1A_sizeof(int nof_prb);
int dci_format1A_add(dci_t *q, dci_format1_t *msg);
int dci_format1A_sizeof(int nof_prb, bool random_access_initiated);
int dci_format1C_add(dci_t *q, dci_format1_t *msg, int L, int nCCE, unsigned short rnti);
int dci_format1C_sizeof(int nof_prb);
int dci_format1C_add(dci_t *q, dci_format1_t *msg);
int dci_format1C_sizeof();
#endif

@ -63,7 +63,7 @@ void dci_candidate_fprint(FILE *f, dci_candidate_t *q) {
q->L, q->ncce, q->rnti, q->nof_bits);
}
int dci_format1_add(dci_t *q, dci_format1_t *msg) {
int dci_format1_add(dci_t *q, dci_format1_t *msg, int L, int nCCE, unsigned short rnti) {
int i, j;
i=0;
while(i<q->nof_dcis && q->msg[i].location.nof_bits)
@ -72,10 +72,10 @@ int dci_format1_add(dci_t *q, dci_format1_t *msg) {
fprintf(stderr, "No more space in DCI container\n");
return -1;
}
q->msg[i].location.L = 0;
q->msg[i].location.ncce = 0;
q->msg[i].location.nof_bits = dci_format1_sizeof();
q->msg[i].location.rnti = 1234;
q->msg[i].location.L = L;
q->msg[i].location.ncce = nCCE;
q->msg[i].location.nof_bits = dci_format1_sizeof(6, 1);
q->msg[i].location.rnti = rnti;
for (j=0;j<q->msg[i].location.nof_bits;j++) {
q->msg[i].data[j] = rand()%2;
}

@ -117,7 +117,7 @@ void pdcch_init_common(pdcch_t *q, pdcch_search_t *s, unsigned short rnti) {
// Format 1A and 1C L=4 and L=8, 4 and 2 candidates, only if nof_cce > 16
k = 0;
k += gen_common_search(&c[k], q->nof_cce,
dci_format1A_sizeof(q->nof_prb), SIRNTI);
dci_format1A_sizeof(q->nof_prb, true), SIRNTI);
k += gen_common_search(&c[k], q->nof_cce,
dci_format1C_sizeof(q->nof_prb), SIRNTI);
}
@ -155,9 +155,9 @@ void pdcch_init_search_ue(pdcch_t *q, unsigned short c_rnti) {
k += gen_ue_search(&c[k], q->nof_cce,
dci_format0_sizeof(q->nof_prb), c_rnti, n);
k += gen_ue_search(&c[k], q->nof_cce,
dci_format1_sizeof(q->nof_prb), c_rnti, n);
dci_format1_sizeof(q->nof_prb, 1), c_rnti, n);
k += gen_ue_search(&c[k], q->nof_cce,
dci_format1A_sizeof(q->nof_prb), c_rnti, n);
dci_format1A_sizeof(q->nof_prb, true), c_rnti, n);
}
}
}

@ -112,7 +112,7 @@ int main(int argc, char **argv) {
}
dci_init(&dci_tx, 1);
dci_format1_add(&dci_tx, &dci_msg);
dci_format1_add(&dci_tx, &dci_msg, 1, 0, 1234);
pdcch_encode(&pdcch, &dci_tx, slot1_symbols, 0);

Loading…
Cancel
Save