diff --git a/afsk/make_wav.h b/afsk/make_wav.h index ee0ca243..a35bc17b 100644 --- a/afsk/make_wav.h +++ b/afsk/make_wav.h @@ -28,66 +28,11 @@ void update_rs( unsigned char c // Current data byte to update ); -int encode_8b10b( - int32_t *state, // pointer to encoder state (run disparity, RD) - int32_t data); - #define CHARACTER_BITS 10 #define CHARACTERS_PER_LONGWORD 3 #define CHARACTER_MASK ((1< maxNewBuffer)maxNewBuffer = bufferIndex; - if(index > maxOldBuffer)maxOldBuffer = index; -} - -static uint16_t inline Get10bFromBuffer( - uint32_t *bufferBase, - int index) -{ - int bufferIndex = index/CHARACTERS_PER_LONGWORD; /* Which 32-bit word?*/ - int position = (index%CHARACTERS_PER_LONGWORD)*CHARACTER_BITS; /* Which position within the 32 bits? */ - uint16_t retChar; - retChar = (bufferBase[bufferIndex]>>position) & CHARACTER_MASK; - return retChar; - -} -#else -static void inline Put10bInBuffer( - uint32_t *bufferBase, - int index, - uint16_t data) -{ - uint16_t *buffer = (uint16_t *)bufferBase; - buffer[index] = data; - if(index > maxOldBuffer)maxOldBuffer = index; -} - -static uint16_t inline Get10bFromBuffer( - uint32_t *bufferBase, - int index) -{ - uint16_t *buffer = (uint16_t *)bufferBase; - return buffer[index]; -} -#endif - #define PARITY_BYTES_PER_CODEWORD 32U // Number of parity symbols in frame #define NP 32U //For Phil's code