mirror of
https://github.com/aicodix/modem.git
synced 2026-04-27 22:35:41 +00:00
use a better seed for combinations
This commit is contained in:
parent
cec02bb851
commit
b8dd4de3d8
2 changed files with 2 additions and 6 deletions
|
|
@ -324,15 +324,13 @@ struct Decoder : Common
|
|||
demod[i] *= DSP::polar<value>(1, -tse(i+tone_off));
|
||||
for (int i = 0; i < tone_count; ++i)
|
||||
chan[i] *= DSP::polar<value>(1, tse(i+tone_off));
|
||||
CODE::XorShiftMask<int, 14, 1, 5, 10, 1> combination;
|
||||
CODE::XorShiftMask<int, 14, 1, 5, 10, 50> combination;
|
||||
int trial = side_data;
|
||||
int comb = 0;
|
||||
for (int i = 0; i <= trial; ++i)
|
||||
comb = combination();
|
||||
int poly_index = comb & 15;
|
||||
int seed_value = comb >> 4;
|
||||
if (seed_value == 0)
|
||||
std::cerr << "reserved seed value detected" << std::endl;
|
||||
CODE::MLS seq(slm_poly[poly_index], seed_value);
|
||||
for (int i = 0; i < tone_count; ++i)
|
||||
if (i % block_length != side_off)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue