schifra-master
所属分类:其他
开发工具:C/C++
文件大小:97KB
下载次数:2
上传日期:2020-04-15 14:57:51
上 传 者:
zhaolee1989
说明: 用于windows下的RS译码功能的开发,包含 CCSDS的RS(255,223)编解码的实现。
(It is used for the development of RS decoding function under windows, including the implementation of RS (255223) encoding and decoding of CCSDS.)
文件列表:
.travis.yml (91, 2020-01-01)
Makefile (4334, 2020-01-01)
schifra_bitio_example01.cpp (2238, 2020-01-01)
schifra_bitio_example02.cpp (2394, 2020-01-01)
schifra_crc.hpp (4728, 2020-01-01)
schifra_ecc_traits.hpp (4656, 2020-01-01)
schifra_erasure_channel.hpp (9637, 2020-01-01)
schifra_erasure_channel_example01.cpp (7617, 2020-01-01)
schifra_erasure_channel_example02.cpp (6660, 2020-01-01)
schifra_error_processes.hpp (23979, 2020-01-01)
schifra_file_interleaving_example01.cpp (1831, 2020-01-01)
schifra_file_interleaving_example02.cpp (1836, 2020-01-01)
schifra_file_interleaving_example03.cpp (2198, 2020-01-01)
schifra_fileio.hpp (7636, 2020-01-01)
schifra_galois_field.hpp (18778, 2020-01-01)
schifra_galois_field_element.hpp (8001, 2020-01-01)
schifra_galois_field_polynomial.hpp (26538, 2020-01-01)
schifra_galois_utilities.hpp (4112, 2020-01-01)
schifra_interleaving_example01.cpp (2563, 2020-01-01)
schifra_interleaving_example02.cpp (2475, 2020-01-01)
schifra_interleaving_example03.cpp (3518, 2020-01-01)
schifra_license.txt (19549, 2020-01-01)
schifra_reed_solomon_bitio.hpp (6690, 2020-01-01)
schifra_reed_solomon_block.hpp (12820, 2020-01-01)
schifra_reed_solomon_codec_validation.cpp (1916, 2020-01-01)
schifra_reed_solomon_codec_validator.hpp (42557, 2020-01-01)
schifra_reed_solomon_decoder.hpp (17196, 2020-01-01)
schifra_reed_solomon_encoder.hpp (6757, 2020-01-01)
schifra_reed_solomon_example01.cpp (5473, 2020-01-01)
schifra_reed_solomon_example02.cpp (5598, 2020-01-01)
schifra_reed_solomon_example03.cpp (5753, 2020-01-01)
schifra_reed_solomon_example04.cpp (6364, 2020-01-01)
schifra_reed_solomon_example05.cpp (6343, 2020-01-01)
schifra_reed_solomon_example06.cpp (6348, 2020-01-01)
schifra_reed_solomon_example07.cpp (6348, 2020-01-01)
schifra_reed_solomon_example08.cpp (5491, 2020-01-01)
schifra_reed_solomon_example09.cpp (5442, 2020-01-01)
schifra_reed_solomon_file_decoder.hpp (6440, 2020-01-01)
... ...
#### Description
Schifra is a very robust, highly optimized and extremely configurable
Reed-Solomon error correcting code library for software applications
implemented in C++. Schifra supports standard, shortened and punctured
Reed-Solomon codes. It also has support for stacked product codes and
interleaving.
Schifra provides a concise, predictable and deterministic interface
which lends itself to easy and seamless integration into the
development of complex data communication projects requiring Reed-
Solomon error correcting code capabilities.
----
#### Download
http://www.schifra.com
----
#### Features
* Errors and Erasures
* Supported Symbol Sizes - 2 to 32 bits
* Variable Code Block Length
* User defined primitive polynomial and finite field
* Accurate and Validated Reed-Solomon Codecs - Complete combinatorial errors and erasures unit testing
* Supported Architectures For Optimizations - x86-32, x86-***, PowerPC, m68k, XScale
* Supported Reed-Solomon Codes - Intelsat 1-4, DVB(S and T), MPEG-2 TSP, VDL Mode 2-4, MIL-STD-188-165a, ITU-T G.709, CCSDS (Basis transform), CIRC, ETS 300-421, ETS 300-429, xDSL, PostBar, MaxiCode, DataMatrix and many more...
* Shortened, Punctured and Concatenated Reed-Solomon Codes - WiMAX IEEE 802.16d standard
* Product Codes
* Standard and Algebraic Interleavers
* Special Optimized Decoder - For cases of 2t = 2, 4, 6, 16 and 32
* DO-178B Level A Certified Reed-Solomon Codec - RTCA DO-224A for VDL mode 2 and 3, RTCA DO-242A (ADS-B), Certified for installation on-board airborne systems
* Reed-Solomon Based channel code for Erasure Channels
----
#### Compatible C++ Compilers
+ GNU Compiler Collection (3.1+)
+ Intel C++ Compiler (8.x+)
+ Clang/LLVM (1.1+)
+ PGI C++ (10.x+)
+ Microsoft Visual Studio C++ Compiler (7.1+)
+ IBM XL C/C++ (9.x+)
----
#### C++ Encoder/Decoder Example
This example will demonstrate using C++ how to instantiate a Reed-
Solomon encoder and decoder, add the full amount of possible errors,
correct the errors, and output the various pieces of relevant
information. The Reed-Solomon code's properties are as follows:
+ Symbol size: 8-bits
+ Codeword length: 255
+ Number of data symbols: 223
+ Number of FEC symbols: 32
+ Finite Field: GF(28)
+ Finite Field polynomial: 1x8 + 1x7 + 0x6 + 0x5 + 0x4 + 0x3 + 1x2 + 1x1 + 1x0
+ Generator polynomial roots: 32
+ Generator polynomial field index: 120th element (32 consecutive roots)
![ScreenShot](http://schifra.com/images/schifra_channel_diagram.png?raw=true "Schifra Reed Solomon Error Correcting Code Channel Model - By Arash Partow")
```c++
#include
#include
#include
#include "schifra_galois_field.hpp"
#include "schifra_galois_field_polynomial.hpp"
#include "schifra_sequential_root_generator_polynomial_creator.hpp"
#include "schifra_reed_solomon_encoder.hpp"
#include "schifra_reed_solomon_decoder.hpp"
#include "schifra_reed_solomon_block.hpp"
#include "schifra_error_processes.hpp"
int main()
{
/* Finite Field Parameters */
const std::size_t field_descriptor = 8;
const std::size_t generator_polynomial_index = 120;
const std::size_t generator_polynomial_root_count = 32;
/* Reed Solomon Code Parameters */
const std::size_t code_length = 255;
const std::size_t fec_length = 32;
const std::size_t data_length = code_length - fec_length;
/* Instantiate Finite Field and Generator Polynomials */
const schifra::galois::field field(field_descriptor,
schifra::galois::primitive_polynomial_size06,
schifra::galois::primitive_polynomial06);
schifra::galois::field_polynomial generator_polynomial(field);
if (
!schifra::make_sequential_root_generator_polynomial(
field,
generator_polynomial_index,
generator_polynomial_root_count,
generator_polynomial)
)
{
std::cout << "Error - Failed to create sequential root generator!" << std::endl;
return 1;
}
/* Instantiate Encoder and Decoder (Codec) */
typedef schifra::reed_solomon::encoder encoder_t;
typedef schifra::reed_solomon::decoder decoder_t;
const encoder_t encoder(field,generator_polynomial);
const decoder_t decoder(field,generator_polynomial_index);
std::string message = "An expert is someone who knows more and more about less and "
"less until they know absolutely everything about nothing";
/* Pad message with nulls up until the code-word length */
message.resize(code_length,0x00);
/* Instantiate RS Block For Codec */
schifra::reed_solomon::block block;
/* Transform message into Reed-Solomon encoded codeword */
if (!encoder.encode(message,block))
{
std::cout << "Error - Critical decoding failure! "
<< "Msg: " << block.error_as_string() << std::endl;
return 1;
}
/* Add errors at every 3rd location starting at position zero */
schifra::corrupt_message_all_errors00(block, 0, 3);
if (!decoder.decode(block))
{
std::cout << "Error - Critical decoding failure!" << std::endl;
return 1;
}
else if (!schifra::is_block_equivelent(block,message))
{
std::cout << "Error - Error correction failed!" << std::endl;
return 1;
}
block.data_to_string(message);
return 0;
}
```
----
#### Performance
The following table is a listing of results obtained from running the
schifra_reed_solomon_speed_evaluation benchmark. The benchmark measures
the decoding rate of codewords in two modalities: "All Errors" and
"All Erasures".
| Reed Solomon Codec | All Errors Decoding Rate (Mbps) | All Erasures Decoding Rate (Mbps) |
| :--------------------| :--------------------------------: | :---------------------------------: |
| RS(255,253,002) | 1669.275 | 1542.483 |
| RS(255,251,004) | 1103.620 | 1019.695 |
| RS(255,249,006) | 843.524 | 781.815 |
| RS(255,247,008) | 670.612 | 612.418 |
| RS(255,245,010) | 552.918 | 513.101 |
| RS(255,243,012) | 461.485 | 430.707 |
| RS(255,241,014) | 399.025 | 378.728 |
| RS(255,239,016) | 355.399 | 338.250 |
| RS(255,237,018) | 315.294 | 304.094 |
| RS(255,235,020) | 282.269 | 273.023 |
| RS(255,223,032) | 173.067 | 162.276 |
| RS(255,207,048) | 106.055 | 102.039 |
| RS(255,191,0***) | 75.213 | 72.671 |
| RS(255,175,080) | 56.374 | 53.210 |
| RS(255,159,096) | 41.354 | 41.009 |
| RS(255,127,128) | 25.445 | 24.823 |
**Note:** The above results were obtained by compiling the benchmark with
GCC 7.2 with O3, LTO, PGO and native architecture target compiler settings,
and executed upon an Intel Xeon E5-2687W 3GHz CPU, ***GB RAM, Ubuntu 16.10
with kernel 4.13 system.
##### Benchmark Binaries
+ [Linux](http://www.schifra.com/downloads/schifra_reed_solomon_speed_evaluation_linux.zip)
+ [Windows](http://www.schifra.com/downloads/schifra_reed_solomon_speed_evaluation_win32.zip)
近期下载者:
相关文件:
收藏者: