Update the F1 messages and build scripts for proper generation of F1 messages
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
# vim swp
|
||||
*.swp
|
||||
|
||||
# log and exec file
|
||||
log/
|
||||
lte_build_oai/
|
||||
targets/bin/
|
||||
@@ -507,11 +507,13 @@ include_directories ("${X2AP_DIR}")
|
||||
# Same limitation as described in RRC/S1AP: unknown generated file list
|
||||
# so we generate it at cmake time
|
||||
##############
|
||||
add_list1_option(F1AP_VERSION R15 "F1AP Asn.1 grammar version" R15)
|
||||
add_list1_option(F1AP_RELEASE R15 "F1AP ASN.1 grammar version" R15)
|
||||
set(F1AP_DIR ${OPENAIR2_DIR}/F1AP)
|
||||
#if (${F1AP_VERSION} STREQUAL "R15")
|
||||
set (ASN1RELDIR R15)
|
||||
#endif(${F1AP_VERSION} STREQUAL "R15")
|
||||
if (${F1AP_RELEASE} STREQUAL "R15")
|
||||
make_version(F1AP_VERSION 15 1 1)
|
||||
set (ASN1RELDIR R15.1.1)
|
||||
endif(${F1AP_RELEASE} STREQUAL "R15")
|
||||
add_definitions(-DF1AP_VERSION=${F1AP_VERSION})
|
||||
set(F1AP_ASN_DIR ${F1AP_DIR}/MESSAGES/ASN1/${ASN1RELDIR})
|
||||
set(F1AP_ASN_FILES
|
||||
${F1AP_ASN_DIR}/F1AP-CommonDataTypes.asn
|
||||
@@ -522,22 +524,24 @@ set(F1AP_ASN_FILES
|
||||
${F1AP_ASN_DIR}/F1AP-Containers.asn
|
||||
)
|
||||
|
||||
set(F1AP_C_DIR ${asn1_generated_dir}/${ASN1RELDIR})
|
||||
set(F1AP_C_DIR ${asn1_generated_dir}/F1AP_${ASN1RELDIR})
|
||||
set(ENV{ASN1C_PREFIX} F1AP_)
|
||||
execute_process(COMMAND ${asn1c_call} ${F1AP_C_DIR} ${F1AP_ASN_FILES}
|
||||
RESULT_VARIABLE ret)
|
||||
RESULT_VARIABLE reti)
|
||||
unset(ENV{ASN1C_PREFIX})
|
||||
if (NOT ${ret} STREQUAL 0)
|
||||
message(FATAL_ERROR "${asn1c_call}: error")
|
||||
endif (NOT ${ret} STREQUAL 0)
|
||||
execute_process(COMMAND python ${F1AP_DIR}/MESSAGES/ASN1/asn1tostruct.py -f ${F1AP_ASN_DIR}/F1AP-PDU-Contents.asn -o ${F1AP_C_DIR}
|
||||
RESULT_VARIABLE ret)
|
||||
if (NOT ${ret} STREQUAL 0)
|
||||
message(FATAL_ERROR "asn1tostruct.py: error")
|
||||
endif (NOT ${ret} STREQUAL 0)
|
||||
execute_process(COMMAND ${fix_asn1c_call} ${F1AP_C_DIR} F1AP ${F1AP_VERSION}
|
||||
RESULT_VARIABLE ret)
|
||||
if (NOT ${ret} STREQUAL 0)
|
||||
message(FATAL_ERROR "${fix_asn1c_call}: error")
|
||||
endif (NOT ${ret} STREQUAL 0)
|
||||
#execute_process(COMMAND python ${F1AP_DIR}/MESSAGES/ASN1/asn1tostruct.py -f ${F1AP_ASN_DIR}/F1AP-PDU-Contents.asn -o ${F1AP_C_DIR}
|
||||
# RESULT_VARIABLE ret)
|
||||
#if (NOT ${ret} STREQUAL 0)
|
||||
# message(FATAL_ERROR "asn1tostruct.py: error")
|
||||
#endif (NOT ${ret} STREQUAL 0)
|
||||
#execute_process(COMMAND ${fix_asn1c_call} ${F1AP_C_DIR} F1AP ${F1AP_VERSION}
|
||||
# RESULT_VARIABLE ret)
|
||||
#if (NOT ${ret} STREQUAL 0)
|
||||
# message(FATAL_ERROR "${fix_asn1c_call}: error")
|
||||
#endif (NOT ${ret} STREQUAL 0)
|
||||
file(GLOB F1AP_source ${F1AP_C_DIR}/*.c)
|
||||
|
||||
#set(F1AP_OAI_generated
|
||||
@@ -907,8 +911,8 @@ set(FLPT_MSG_FILES
|
||||
${FLPT_MSG_DIR}/control_delegation.proto
|
||||
)
|
||||
|
||||
set(FLPT_C_DIR ${protobuf_generated_dir}/${FLPTDIR})
|
||||
message("calling protoc_call=${protoc_call} FLPT_C_DIR=${FLPT_C_DIR} FLPT_MSG_FILES=${FLPT_MSG_FILES}")
|
||||
set(FLPT_C_DIR ${protobuf_generated_dir}/FLPT_${FLPTDIR})
|
||||
#message("calling protoc_call=${protoc_call} FLPT_C_DIR=${FLPT_C_DIR} FLPT_MSG_FILES=${FLPT_MSG_FILES}")
|
||||
execute_process(COMMAND ${protoc_call} ${FLPT_C_DIR} ${FLPT_MSG_DIR} ${FLPT_MSG_FILES})
|
||||
file(GLOB FLPT_source ${FLPT_C_DIR}/*.c)
|
||||
set(FLPT_OAI_generated
|
||||
@@ -988,10 +992,10 @@ if (PDCP_SPLIT)
|
||||
${FSPT_MSG_DIR}/flexsplit.proto
|
||||
)
|
||||
|
||||
set(FSPT_C_DIR ${protobuf_generated_dir}/${FSPTDIR})
|
||||
message("calling protoc_call=${protoc_call} FSPT_C_DIR=${FSPT_C_DIR} FSPT_MSG_FILES=${FSPT_MSG_FILES}")
|
||||
set(FSPT_C_DIR ${protobuf_generated_dir}/FSPT_${FSPTDIR})
|
||||
message("calling protoc_call=${protoc_call} FSPT_C_DIR=${FSPT_C_DIR} FSPT_MSG_DIR=${FSPT_MSG_DIR} FSPT_MSG_FILES=${FSPT_MSG_FILES}")
|
||||
execute_process(COMMAND ${protoc_call} ${FSPT_C_DIR} ${FSPT_MSG_DIR} ${FSPT_MSG_FILES})
|
||||
file(GLOB FSPT_source ${FSPT_C_DIR}/*.c)
|
||||
file(GLOB FSPT_source ${FSPT_C_DIR}/*.c)
|
||||
set(FSPT_OAI_generated
|
||||
${FSPT_C_DIR}/flexsplit.pb-c.c
|
||||
)
|
||||
|
||||
@@ -105,6 +105,10 @@ Options
|
||||
Enables agent for software-defined control of the eNB
|
||||
--pdcp-split
|
||||
Enables PDCP-RLC U plane split
|
||||
--CU
|
||||
Build the CU entity
|
||||
--DU
|
||||
Build the CU entity
|
||||
-r | --3gpp-release
|
||||
default is Rel14,
|
||||
Rel8 limits the implementation to 3GPP Release 8 version
|
||||
@@ -214,9 +218,11 @@ function main() {
|
||||
-a | --agent)
|
||||
echo_info "FlexRAN support is always compiled into the eNB"
|
||||
shift;;
|
||||
--pdcp-split)
|
||||
--pdcp-split | --CU | --DU )
|
||||
PDCP_SPLIT=1
|
||||
echo_info "Will compile PDCP-RLC U plane split support"
|
||||
CU=1
|
||||
DU=1
|
||||
echo_info "Will compile for $1 with F1AP support "
|
||||
shift;;
|
||||
--UE)
|
||||
UE=1
|
||||
@@ -473,7 +479,7 @@ function main() {
|
||||
|
||||
if [ "$INSTALL_EXTERNAL" = "1" ] ; then
|
||||
echo_info "Installing packages"
|
||||
check_install_oai_software
|
||||
check_install_oai_software $PDCP_SPLIT
|
||||
if [ "$HW" == "OAI_USRP" ] ; then
|
||||
echo_info "installing packages for USRP support"
|
||||
check_install_usrp_uhd_driver
|
||||
|
||||
@@ -567,7 +567,8 @@ check_install_oai_software() {
|
||||
pydb \
|
||||
libyaml-dev \
|
||||
wget \
|
||||
libxpm-dev
|
||||
libxpm-dev \
|
||||
libboost-all-dev
|
||||
|
||||
$SUDO update-alternatives --set "$LAPACK_LIBNAME" "$LAPACK_TARGET"
|
||||
|
||||
@@ -653,7 +654,7 @@ check_install_oai_software() {
|
||||
libyaml-devel
|
||||
fi
|
||||
|
||||
install_asn1c_from_source
|
||||
install_asn1c_from_source $1
|
||||
$SUDO rm -fr /opt/ssh
|
||||
$SUDO git clone https://gist.github.com/2190472.git /opt/ssh
|
||||
}
|
||||
@@ -663,10 +664,14 @@ install_asn1c_from_source(){
|
||||
echo_info "\nInstalling ASN1. The log file for ASN1 installation is here: $asn1_install_log "
|
||||
(
|
||||
$SUDO rm -rf /tmp/asn1c
|
||||
GIT_SSL_NO_VERIFY=true git clone https://gitlab.eurecom.fr/oai/asn1c.git /tmp/asn1c
|
||||
if [ $1 -eq "1" ]; then
|
||||
echo "building ASN1C from https://github.com/brchiu/asn1c branch"
|
||||
GIT_SSL_NO_VERIFY=true git clone https://github.com/brchiu/asn1c.git --branch velichkov_s1ap_plus_option_group /tmp/asn1c
|
||||
else
|
||||
echo "building ASN1C from https://gitlab.eurecom.fr/oai/asn1c branch"
|
||||
GIT_SSL_NO_VERIFY=true git clone https://gitlab.eurecom.fr/oai/asn1c.git --branch master.aper /tmp/asn1c
|
||||
fi
|
||||
cd /tmp/asn1c
|
||||
git checkout master.aper
|
||||
git pull
|
||||
test -f configure || autoreconf -iv
|
||||
./configure
|
||||
make -j`nproc`
|
||||
|
||||
@@ -140,6 +140,22 @@ function patch_s1ap()
|
||||
esac
|
||||
}
|
||||
|
||||
function patch_f1ap()
|
||||
{
|
||||
local directory="$1"
|
||||
local version="$2"
|
||||
|
||||
case "$version" in
|
||||
R15 )
|
||||
#nothing to do anymore (fixes went to asn1c)
|
||||
;;
|
||||
* )
|
||||
error unknwon/unhandled F1AP version \'"$version"\'
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
|
||||
function main()
|
||||
{
|
||||
if [ $# -ne 3 ]
|
||||
@@ -167,6 +183,9 @@ function main()
|
||||
S1AP )
|
||||
patch_s1ap "$directory" "$version"
|
||||
;;
|
||||
F1AP )
|
||||
patch_f1ap "$directory" "$version"
|
||||
;;
|
||||
* )
|
||||
error unknown module "$module"
|
||||
;;
|
||||
|
||||
Executable → Regular
+1
-1
@@ -29,4 +29,4 @@ ProtocolIE-ID ::= INTEGER (0..65535)
|
||||
|
||||
TriggeringMessage ::= ENUMERATED { initiating-message, successful-outcome, unsuccessfull-outcome }
|
||||
|
||||
END
|
||||
END
|
||||
Executable → Regular
+2
-2
@@ -157,7 +157,7 @@ id-SRBs-ToBeSetup-Item ProtocolIE-ID ::= 73
|
||||
id-SRBs-ToBeSetup-List ProtocolIE-ID ::= 74
|
||||
id-SRBs-ToBeSetupMod-Item ProtocolIE-ID ::= 75
|
||||
id-SRBs-ToBeSetupMod-List ProtocolIE-ID ::= 76
|
||||
id-TimeToWait ProtocolIE-ID ::= 75
|
||||
id-TimeToWait ProtocolIE-ID ::= 77
|
||||
id-TransactionID ProtocolIE-ID ::= 78
|
||||
id-TransmissionStopIndicator ProtocolIE-ID ::= 79
|
||||
id-UE-associatedLogicalF1-ConnectionItem ProtocolIE-ID ::= 80
|
||||
@@ -176,4 +176,4 @@ id-Potential-SpCell-List ProtocolIE-ID ::= 92
|
||||
id-Potential-SpCell-Item ProtocolIE-ID ::= 93
|
||||
|
||||
|
||||
END
|
||||
END
|
||||
Executable → Regular
+1
-1
@@ -181,4 +181,4 @@ PrivateIE-Field {F1AP-PRIVATE-IES : IEsSetParam} ::= SEQUENCE {
|
||||
value F1AP-PRIVATE-IES.&Value ({IEsSetParam}{@id})
|
||||
}
|
||||
|
||||
END
|
||||
END
|
||||
Executable → Regular
+1
-1
@@ -867,4 +867,4 @@ ULTunnels-ToBeSetup-ItemExtIEs F1AP-PROTOCOL-EXTENSION ::= {
|
||||
|
||||
-- Z
|
||||
|
||||
END
|
||||
END
|
||||
Executable → Regular
Executable → Regular
@@ -132,7 +132,7 @@ for filename in filenames:
|
||||
for m in re.findall(r'([a-zA-Z0-9-]+)\s*::=\s+E-RAB-IE-ContainerList\s*\{\s*\{\s*([a-zA-Z0-9-]+)\s*\}\s*\}', lines, re.MULTILINE):
|
||||
ieofielist[m[0]] = m[1]
|
||||
|
||||
for i in re.findall(r'([a-zA-Z0-9-]+)\s+([A-Z0-9-]+)\s*::=\s*\{\s+([\,\|\{\}\t\n\.{3}\ \-a-zA-Z0-9]+)\s+}\n', lines, re.MULTILINE):
|
||||
for i in re.findall(r'([a-zA-Z0-9-]+)\s+([A-Z0-9-]+)\s*::=\s*\{\s+([\,\|\{\}\t\n\.{3}\ \-a-zA-Z0-9]+)\s+}\n?', lines, re.MULTILINE):
|
||||
ies = []
|
||||
maxLength = 0
|
||||
# TODO: handle extensions
|
||||
|
||||
Reference in New Issue
Block a user