From: drowe67 Date: Mon, 12 Sep 2016 07:50:00 +0000 (+0000) Subject: partially refactored X-Git-Url: http://git.whiteaudio.com/gitweb/?a=commitdiff_plain;h=27f4abfec21b27874eed52baf91f6178775255e7;p=freetel-svn-tracking.git partially refactored git-svn-id: https://svn.code.sf.net/p/freetel/code@2856 01035d8c-6547-0410-b346-abe4f91aad63 --- diff --git a/codec2-dev/src/ldpc_enc.c b/codec2-dev/src/ldpc_enc.c index c7d03311..d6753bfc 100644 --- a/codec2-dev/src/ldpc_enc.c +++ b/codec2-dev/src/ldpc_enc.c @@ -1,31 +1,28 @@ -/* RA encoder program; Bill, March 2016 - Using the elegant back substitution of RA LDPC codes. - This version does not store the data in bytes! */ +/* + FILE...: ldpc_enc.c + AUTHOR.: Bill Cowley, David Rowe + CREATED: Sep 2016 + RA LDPC encoder program. Using the elegant back substitution of RA + LDPC codes. +*/ #include #include -#define Nibits 2064 -#define Npbits 516 -#define Nwt 12 - /* generated by ldpc_fsk_lib.m:ldpc_decode() */ #include "ldpc_code.h" -unsigned char ibits[Nibits]; // info array -unsigned char pbits[Npbits]; // parity array - -void encode() { - unsigned int p, i, tmp, par, prev=0; +void encode(unsigned char ibits[], unsigned char pbits[]) { + unsigned int p, i, tmp, par, prev=0; int ind; - for (p=0; p