2014-05-13 08:03:39 -07:00
|
|
|
/**
|
|
|
|
*
|
|
|
|
* \section COPYRIGHT
|
|
|
|
*
|
2015-03-18 05:31:13 -07:00
|
|
|
* Copyright 2013-2014 The srsLTE Developers. See the
|
2014-05-13 08:03:39 -07:00
|
|
|
* COPYRIGHT file at the top-level directory of this distribution.
|
|
|
|
*
|
|
|
|
* \section LICENSE
|
|
|
|
*
|
2015-03-18 05:31:13 -07:00
|
|
|
* This file is part of the srsLTE library.
|
2014-05-13 08:03:39 -07:00
|
|
|
*
|
2015-03-18 05:31:13 -07:00
|
|
|
* srsLTE is free software: you can redistribute it and/or modify
|
2014-05-13 08:03:39 -07:00
|
|
|
* it under the terms of the GNU Lesser General Public License as
|
|
|
|
* published by the Free Software Foundation, either version 3 of
|
|
|
|
* the License, or (at your option) any later version.
|
|
|
|
*
|
2015-03-18 05:31:13 -07:00
|
|
|
* srsLTE is distributed in the hope that it will be useful,
|
2014-05-13 08:03:39 -07:00
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU Lesser General Public License for more details.
|
|
|
|
*
|
|
|
|
* A copy of the GNU Lesser General Public License can be found in
|
|
|
|
* the LICENSE file in the top-level directory of this distribution
|
|
|
|
* and at http://www.gnu.org/licenses/.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2014-06-17 03:44:42 -07:00
|
|
|
#ifndef TURBOCODER_
|
|
|
|
#define TURBOCODER_
|
|
|
|
|
2015-03-18 05:16:28 -07:00
|
|
|
#include "srslte/config.h"
|
2015-03-18 05:31:13 -07:00
|
|
|
#include "srslte/fec/tc_interl.h"
|
2014-05-13 08:03:39 -07:00
|
|
|
|
|
|
|
#define NUMREGS 3
|
|
|
|
|
|
|
|
#define RATE 3
|
|
|
|
#define TOTALTAIL 12
|
|
|
|
|
2015-01-29 16:15:09 -08:00
|
|
|
#ifndef TX_NULL
|
|
|
|
#define TX_NULL 100
|
|
|
|
#endif
|
|
|
|
|
2015-03-18 05:31:13 -07:00
|
|
|
typedef struct SRSLTE_API {
|
2014-07-05 12:00:32 -07:00
|
|
|
uint32_t max_long_cb;
|
2014-06-17 02:11:41 -07:00
|
|
|
tc_interl_t interl;
|
2014-06-17 07:32:19 -07:00
|
|
|
} tcod_t;
|
2014-05-13 08:03:39 -07:00
|
|
|
|
2015-03-18 05:31:13 -07:00
|
|
|
SRSLTE_API int tcod_init(tcod_t *h, uint32_t max_long_cb);
|
|
|
|
SRSLTE_API void tcod_free(tcod_t *h);
|
|
|
|
SRSLTE_API int tcod_encode(tcod_t *h, uint8_t *input, uint8_t *output, uint32_t long_cb);
|
2014-05-13 08:03:39 -07:00
|
|
|
|
2014-06-17 03:44:42 -07:00
|
|
|
#endif
|
2014-05-13 08:03:39 -07:00
|
|
|
|