Commit 1df958f5 authored by Florian Kaltenberger's avatar Florian Kaltenberger

fixing small bugs in rrc_ue.c

lte-softmodem option -O for UE now requires ue capabilites to be provided in raw format
parent 0cf74dd3
...@@ -2608,7 +2608,7 @@ OAI_UECapability_t *fill_ue_capability(char *UE_EUTRA_Capability_xer_fname) ...@@ -2608,7 +2608,7 @@ OAI_UECapability_t *fill_ue_capability(char *UE_EUTRA_Capability_xer_fname)
int i; int i;
UE_EUTRA_Capability_t *UE_EUTRA_Capability; UE_EUTRA_Capability_t *UE_EUTRA_Capability;
char UE_EUTRA_Capability_xer[8192]; char UE_EUTRA_Capability_xer[102400];
size_t size; size_t size;
LOG_I(RRC,"Allocating %u bytes for UE_EUTRA_Capability\n",sizeof(*UE_EUTRA_Capability)); LOG_I(RRC,"Allocating %u bytes for UE_EUTRA_Capability\n",sizeof(*UE_EUTRA_Capability));
...@@ -2726,7 +2726,10 @@ OAI_UECapability_t *fill_ue_capability(char *UE_EUTRA_Capability_xer_fname) ...@@ -2726,7 +2726,10 @@ OAI_UECapability_t *fill_ue_capability(char *UE_EUTRA_Capability_xer_fname)
return(NULL); return(NULL);
} }
dec_rval = xer_decode(0, &asn_DEF_UE_EUTRA_Capability, (void*)UE_EUTRA_Capability, UE_EUTRA_Capability_xer, size); // use this line if UE capabilites was stored in a xml file (does not seem to work)
// dec_rval = xer_decode(0, &asn_DEF_UE_EUTRA_Capability, (void*)UE_EUTRA_Capability, UE_EUTRA_Capability_xer, size);
// use this line if UE capabilites was stored as a raw file
dec_rval = uper_decode(NULL, &asn_DEF_UE_EUTRA_Capability, (void**)&UE_EUTRA_Capability, UE_EUTRA_Capability_xer, size, 0, 0);
assert(dec_rval.code == RC_OK); assert(dec_rval.code == RC_OK);
} }
......
...@@ -1765,7 +1765,7 @@ rrc_ue_process_ueCapabilityEnquiry( ...@@ -1765,7 +1765,7 @@ rrc_ue_process_ueCapabilityEnquiry(
UE_CapabilityRAT_Container_t ue_CapabilityRAT_Container; UE_CapabilityRAT_Container_t ue_CapabilityRAT_Container;
uint8_t buffer[200]; uint8_t buffer[256];
int i; int i;
LOG_I(RRC,"[UE %d] Frame %d: Receiving from SRB1 (DL-DCCH), Processing UECapabilityEnquiry (eNB %d)\n", LOG_I(RRC,"[UE %d] Frame %d: Receiving from SRB1 (DL-DCCH), Processing UECapabilityEnquiry (eNB %d)\n",
...@@ -1804,8 +1804,10 @@ rrc_ue_process_ueCapabilityEnquiry( ...@@ -1804,8 +1804,10 @@ rrc_ue_process_ueCapabilityEnquiry(
ASN_SEQUENCE_ADD( ASN_SEQUENCE_ADD(
&ul_dcch_msg.message.choice.c1.choice.ueCapabilityInformation.criticalExtensions.choice.c1.choice.ueCapabilityInformation_r8.ue_CapabilityRAT_ContainerList.list, &ul_dcch_msg.message.choice.c1.choice.ueCapabilityInformation.criticalExtensions.choice.c1.choice.ueCapabilityInformation_r8.ue_CapabilityRAT_ContainerList.list,
&ue_CapabilityRAT_Container); &ue_CapabilityRAT_Container);
}
}
enc_rval = uper_encode_to_buffer(&asn_DEF_UL_DCCH_Message, (void*) &ul_dcch_msg, buffer, 100); enc_rval = uper_encode_to_buffer(&asn_DEF_UL_DCCH_Message, (void*) &ul_dcch_msg, buffer, 256);
AssertFatal (enc_rval.encoded > 0, "ASN1 message encoding failed (%s, %jd)!\n", AssertFatal (enc_rval.encoded > 0, "ASN1 message encoding failed (%s, %jd)!\n",
enc_rval.failed_type->name, enc_rval.encoded); enc_rval.failed_type->name, enc_rval.encoded);
...@@ -1851,8 +1853,6 @@ rrc_ue_process_ueCapabilityEnquiry( ...@@ -1851,8 +1853,6 @@ rrc_ue_process_ueCapabilityEnquiry(
PDCP_TRANSMISSION_MODE_CONTROL); PDCP_TRANSMISSION_MODE_CONTROL);
} }
} }
}
}
} }
......
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