Files
openairinterface5g/openair2/RRC/LITE/MESSAGES
Bi-Ruei, Chiu 5c23af773a Compare version number using MAKE_VERSION macro to provide better SW configuration:
1. Previous SW configuration for different RRC version relies on whether macro Rel10,
   Rel14 defined or not by checking #ifdef Rel14 or #if defined(Rel10) || defined(R14).
   Whenever there is a newer RRC version, e.g. Rel15, it will be very a tedious and
   error-prone job to add defined(Rel15) in every place.

2. Some RRC messages are defined in release 13 instead of release 14, NB-IoT
   feature is one of such example. Our code shall reflect this fact instead of using
   an afterward version number in software configuration.

3. Some RRC messages or some fields of certain RRC messages are added in the middle
   a release, e.g. SystemInformationBlockType1_v1310_IEs_t defined in RRC 13.1.0
   and RRC 9.2.0 made some changes to SIB12 and SIB13 so we have sib12_v920 and
   sib13_v920 fields in SIB12 and SIB13's struct.
   We need a finer grain of control when using ASN1 from different RRC version.

4. S1AP also has this problem that it use UPDATE_RELEASE_9 and UPDATE_RELEASE_10 to
   differentiate between various S1AP version.

This commit propose using MAKE_VERSION(x,y,z) to designate the version number and
modify current conditional compilation accordingly.

Note: 2018/04/16, Modified based on Cedric's comment.
2018-04-16 12:32:29 +02:00
..
2017-10-27 16:13:41 +02:00
2013-11-25 16:20:19 +00:00

This directory contains the necessary scripts and Makefiles to generate all the LTE configuration data structures based on the ASN.1 RRC
source code from the 36.331 RRC specifications.  These structures are used by MAC and PHY for configuration purposes.

It contains the following files

README.txt                                              : This file
Makefile.inc                                            : Makefile to be included by OpenAir compilation scripts for LTE Data structures
asn1c                                                   : Directory to place asn1c package
asn1c/ASN1_files/36331-860.txt                          : Text file containing 36.331-860 specifications used to generate ASN1 source 
asn1c/ASN1_files/extract_asn1_from_spec.pl              : Pearl script to extract ASN.1 source from 36311-860.txt
asn1c/ASN1_files/EUTRA-RRC-Definitions.asn              : First ASN.1 source (generated from above .txt file)
asn1c/ASN1_files/EUTRA-InterNodeDefinitions.asn .asn    : Second ASN.1 source (generated from above .txt file)
asn1c/ASN1_files/EUTRA-UE-Variables.asn                 : Third ASN.1 source (generated from above .txt file)

Instructions to build data structures from ASN1 sources 

The three files have already been built using the extract_asn1_from_spec.pl Pearl script.  This should be used again if a newer version
of the RRC spec is used to synthesize the data structures and encoding/decoding routines.  To do this:
   1. use Microsoft WORD to generate a text version of the 3GPP 36.331 document
   2. run the script on the text file to generate the three files.

Now download the asn1c utility (version 0.9.22) from 

http://lionet.info/asn1c/blog/

or via svn from sourceforge (version 0.9.22)

For version 0.9.2:
svn co https://asn1c.svn.sourceforge.net/svnroot/asn1c/trunk asn1c
For the latest version:
svn co https://github.com/vlm/asn1c/trunk asn1c

and put it in the asn1c directory (you should have a second asn1c directory now). Compile it and install it locally 
(or make sure your $PATH can find the asn1c executable) according to the instructions given (see INSTALL file)
by the author. We have validated that 0.9.22 works on Linux and Cygwin. To generate the data structures do the following from the 
current directory

asn1c -gen-PER -fcompound-names -fnative-types -fskeletons-copy ./asn1c/ASN1_files/EUTRA-RRC-Definitions.asn

Note this only uses one of the three files from 36.331 (the core of the RRC).  After this step you should have many .c and .h files 
and one new Makefile, the latter of which is not used.

If you want to compile the ASN1 sources as a kernel module you need to apply the patch asn1_patch 

patch -p1 < asn1_patch