also return codeword unmodulated

This commit is contained in:
Ahmet Inan 2020-06-09 09:24:05 +02:00
commit 05bd06ec0a
2 changed files with 8 additions and 7 deletions

View file

@ -34,11 +34,12 @@ public:
{
return (msg << P) | par[msg];
}
void operator()(int8_t *code, int msg)
int operator()(int8_t *code, int msg)
{
int cw = (*this)(msg);
for (int i = 0; i < N; ++i)
code[i] = 1 - 2 * ((cw >> i) & 1);
return cw;
}
};