⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 csl_tcp2.h

📁 Dm6455 driver,magbe useful to you!
💻 H
📖 第 1 页 / 共 2 页
字号:
        configBase.frameLen     = frameLen;
        configBase.inputSign    = TCP2_INPUT_SIGN_POSITIVE;
        configBase.intFlag      = 1;
        configBase.maxIter      = 8;
        configBase.maxStarEn    = TRUE;
        configBase.standard     = TCP2_STANDARD_3GPP;
        configBase.crcLen       = 0;
        configBase.crcPoly      = 0;
        configBase.minIter      = 1;
        configBase.numCrcPass   = 1;
        configBase.outParmFlag  = 0;
        configBase.outputOrder  = TCP2_OUT_ORDER_0_31;
        configBase.prologRedEn  = FALSE;
        configBase.prologSize   = 24;
        configBase.rate         = TCP2_RATE_1_3;
        configBase.snr          = 0;

        for (cnt = 0; cnt < 16; cnt++)
            configBase.extrScaling [cnt] = 32;

        // setup the TCP configuration registers parmeters 
        TCP2_genParams (&configBase, &configParams);

     @endverbatim
 * ===========================================================================
 */
Uint32 TCP2_genParams (
    TCP2_BaseParams  *restrict configBase,
    TCP2_Params      *restrict configParams
);


/* ============================================================================
 *   @n@b TCP2_calcSubBlocksSA 
 *
 *   @b Description
 *   @n This function calculates the number of sub blocks for the TCP 
 *      standalone processing. The reliability length is also calculated and the 
 *      configParms structure is populated.
 *
 *   @b Arguments
     @verbatim
            configParms     Pointer to the structure holding the TCP 
                            configuration parameters.

     @endverbatim
 *
 *   <b> Return Value </b>  
 *   @n  None
 *
 *   <b> Pre Condition </b>
 *   @n  None
 *
 *   <b> Post Condition </b>
 *   @n  None 
 *
 *   @b Modifies
 *   @n The configParms argument passed.   
 *
 *   @b Example
 *   @verbatim
        extern TCP2_Params *configParms;
        ...
        TCP2_calcSubBlocksSA (configParms);
     @endverbatim
 * ===========================================================================
 */
void TCP2_calcSubBlocksSA (
    TCP2_Params *configParms 
);
/* ============================================================================
 *   @n@b TCP2_calcSubBlocksSP 
 *
 *   @b Description
 *   @n This function calculates the number of sub blocks for the TCP 
 *      shared processing. The reliability length is also calculated and the 
 *      configParms structure is populated.
 *
 *   @b Arguments
     @verbatim
            configParms     Pointer to the structure holding the TCP 
                            configuration parameters.

     @endverbatim
 *
 *   <b> Return Value </b>  Uint32
 *   @n                     Number of sub frames the frame is divided into
 *
 *   <b> Pre Condition </b>
 *   @n  None
 *
 *   <b> Post Condition </b>
 *   @n  None 
 *
 *   @b Modifies
 *   @n The configParms argument passed.   
 *
 *   @b Example
 *   @verbatim
        extern TCP2_Params *configParms;
        ...
        TCP2_calcSubBlocksSP (configParms);
     @endverbatim
 * ===========================================================================
 */
Uint32 TCP2_calcSubBlocksSP (
    TCP2_Params *configParms 
);

/* ============================================================================
 *   @n@b TCP2_tailConfig3GPP 
 *
 *   @b Description
 *   @n This function generates the input control values IC6-IC11 for 3GPP
 *      channels. These values consist of the tail data following the 
 *      systematics and parities data. This function is called from the generic 
 *      TCP2_tailConfig function.
 *
 *   @b Arguments
     @verbatim
            mode        TCP processing mode (SA or SP)

            map         TCP shared processing MAP 

            rate        TCP data code rate

            tailData    Pointer to the tail data

            configIc    Pointer to the IC values structure

     @endverbatim
 *
 *   <b> Return Value </b>  
 *   @n  None 
 *
 *   <b> Pre Condition </b>
 *   @n  None
 *
 *   <b> Post Condition </b>
 *   @n  The configIc structure is assigned the tail configuration values 
 *       based on the tailData. 
 *
 *   @b Modifies
 *   @n The configIc argument passed.   
 *
 *   @b Example
 *   @verbatim

     @endverbatim
 * ===========================================================================
 */
void TCP2_tailConfig3GPP (
        TCP2_Mode       mode,
        TCP2_Map        map,
        TCP2_Rate       rate,
        TCP2_TailData   *restrict tailData,
        TCP2_ConfigIc   *restrict configIc
); 

/* ============================================================================
 *   @n@b TCP2_tailConfigIs2000 
 *
 *   @b Description
 *   @n This function generates the input control values IC6-IC11 for IS2000
 *      channels. These values consist of the tail data following the 
 *      systematics and parities data. This function is called from the generic 
 *      TCP2_tailConfig function.
 *
 *   @b Arguments
     @verbatim
            mode        TCP processing mode (SA or SP)

            map         TCP shared processing MAP 

            rate        TCP data code rate

            tailData    Pointer to the tail data

            configIc    Pointer to the IC values structure

     @endverbatim
 *
 *   <b> Return Value </b>  
 *   @n  None 
 *
 *   <b> Pre Condition </b>
 *   @n  None
 *
 *   <b> Post Condition </b>
 *   @n  The configIc structure is assigned the tail configuration values 
 *       based on the taildata. 
 *
 *   @b Modifies
 *   @n The configIc argument passed.   
 *
 *   @b Example
 *   @verbatim

     @endverbatim
 * ===========================================================================
 */
void TCP2_tailConfigIs2000 (
        TCP2_Mode       mode,
        TCP2_Map        map,
        TCP2_Rate       rate,
        TCP2_TailData   *restrict tailData,
        TCP2_ConfigIc   *restrict configIc
); 

/* ============================================================================
 *   @n@b TCP2_deinterleaveExt 
 *
 *   @b Description
 *   @n This function de-interleaves the MAP2 extrinsics data to generate 
 *      apriori data for the MAP1 decode. This function is for use in 
 *      performing shared processing.
 *
 *   @b Arguments
     @verbatim
            aprioriMap1         Apriori data for MAP1 decode

            extrinsicsMap2      Extrinsics data 

            interleaverTable    Interleaver data table

            numExt              Number of Extrinsics
     @endverbatim
 *
 *   <b> Return Value </b>  
 *   @n  None 
 *
 *   <b> Pre Condition </b>
 *   @n  None
 *
 *   <b> Post Condition </b>
 *   @n  The aprioriMap1 will contain the deinterleaved data. 
 *
 *   @b Modifies
 *   @n None   
 *
 *   @b Example
 *   @verbatim
            <...MAP 2 decode...>

            TCP2_deinterleaveExt(aprioriMap1, extrinsicsMap2,

                      interleaverTable, numExt);

            <...MAP 1 decode...>
     @endverbatim
 * ===========================================================================
 */
void TCP2_deinterleaveExt (
    TCP2_ExtrinsicData          *aprioriMap1,
    const TCP2_ExtrinsicData    *extrinsicsMap2,
    const Uint16                *interleaverTable,
    Uint32                      numExt
);


/* ============================================================================
 *   @n@b TCP2_interleaveExt 
 *
 *   @b Description
 *   @n This function interleaves the MAP1 extrinsics data to generate 
 *      apriori data for the MAP2 decode. This function is for used in 
 *      performing shared processing.
 *
 *   @b Arguments
     @verbatim
            aprioriMap2          Apriori data for MAP2 decode

            extrinsicsMap1       Extrinsics data 

            interleaverTable     Interleaver data table

            numExt               Number of Extrinsics
     @endverbatim
 *
 *   <b> Return Value </b>  
 *   @n  None 
 *
 *   <b> Pre Condition </b>
 *   @n  None
 *
 *   <b> Post Condition </b>
 *   @n  The aprioriMap2 will contain the interleaved data. 
 *
 *   @b Modifies
 *   @n None   
 *
 *   @b Example
 *   @verbatim
            <...MAP 1 decode...>

            TCP2_interleaveExt(aprioriMap2, extrinsicsMap1,

                         interleaverTable, numExt);

            <...MAP 2 decode...>
     @endverbatim
 * ===========================================================================
 */
void TCP2_interleaveExt (
    TCP2_ExtrinsicData          *aprioriMap2,
    const TCP2_ExtrinsicData    *extrinsicsMap1,
    const Uint16                *interleaverTable,
    Uint32                      numExt
);

/* ============================================================================
 *   @n@b TCP2_depunctInputs
 *
 *   @b Description
 *   @n This function scales and sorts input data into a code rate 1/5 format.
 *
 *   @b Arguments
     @verbatim
            frameLen            Input data length in bytes
            
            inputData           Input data
            
            rate                Input data code rate

            scalingFact         Scaling factor

            depunctData         Depunctured data
            
      @endverbatim
 *
 *   <b> Return Value </b>  Uint32
 *   @n  Length of output data in 32 bit words  
 *
 *   <b> Pre Condition </b>
 *   @n  None
 *
 *   <b> Post Condition </b>
 *   @n  The depunctData will contain the data depunctured to rate 1/5. 
 *
 *   @b Modifies
 *   @n None   
 *
 *   @b Example
 *   @verbatim

            TCP2_depunctInputs (length, inputData, rate

                      scalingFact, depunctData);

     @endverbatim
 * ===========================================================================
 */
void TCP2_depunctInputs (
    Uint32              frameLen,
    TCP2_UserData*      inputData,
    TCP2_Rate           rate,
    Uint32              scalingFact,
    TCP2_InputData*     depunctData       
);

/* ============================================================================
 *   @n@b TCP2_calculateHd
 *
 *   @b Description
 *   @n This function calculates the hard decisions following multiple MAP 
 *      decodings in shared processing mode.
 *
 *   @b Arguments
     @verbatim
            extrinsicsMap1      Extrinsics data following MAP1 decode

            apriori             Apriori data following MAP2 decode

            channel_data        Input channel data

            hardDecisions       Hard decisions

            numExt              Number of extrinsics

     @endverbatim
 *
 *   <b> Return Value </b>  
 *   @n  None 
 *
 *   <b> Pre Condition </b>
 *   @n  None
 *
 *   <b> Post Condition </b>
 *   @n  The hardDecisions will contain the calculated hard decisions. 
 *
 *   @b Modifies
 *   @n None   
 *
 *   @b Example
 *   @verbatim
            void TCP2_calculateHd(extrinsicsMap1, apriori,
                      channel_data, hardDecisions, numExt);
     @endverbatim
 * ===========================================================================
 */
void TCP2_calculateHd (
    const TCP2_ExtrinsicData    *extrinsicsMap1,
    const TCP2_ExtrinsicData    *apriori,
    const TCP2_UserData         *channelData,
    Uint32                      *hardDecisions,
    Uint16                      numExt
);


/* ============================================================================
 *   @n@b TCP2_demuxInput 
 *
 *   @b Description
 *   @n This function splits the input data into two working sets. One set 
 *      contains the non-interleaved input data and is used with the MAP 1 
 *      decoding. The other contains the interleaved input data and is used 
 *      with the MAP2 decoding. This function is used in shared processing mode.
 *
 *   @b Arguments
     @verbatim
            rate                TCP data code rate

            frameLen            Frame length

            input               Input channel data

            interleaver         Interleaver data table

            nonInterleaved      Non Interleaved data for SP MAP0

            interleaved         Interleaved data for SP MAP1
     @endverbatim
 *
 *   <b> Return Value </b>  
 *   @n  None 
 *
 *   <b> Pre Condition </b>
 *   @n  None
 *
 *   <b> Post Condition </b>
 *   @n The nonInterleaved will contain the non-interleaved 
 *      data and the interleaved will contain the interleaved data. 
 *
 *   @b Modifies
 *   @n None   
 *
 *   @b Example
 *   @verbatim
             TCP2_demuxInput (frameLen, input,
                       interleaver, interleaved, nonInterleaved);
     @endverbatim
 * ===========================================================================
 */
void TCP2_demuxInput (
    Uint32                  rate,
    Uint32                  frameLen,
    const TCP2_UserData     *input,
    const Uint16            *interleaver,
    TCP2_ExtrinsicData      *nonInterleaved,
    TCP2_ExtrinsicData      *interleaved
);

#ifdef __cplusplus
}
#endif

#endif  /* _CSL_TCP2_H_ */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -