User Tools

Site Tools


en:scrambler

Coding and Decoding of a frame

a frame consists of 255 byte data and 3 byte header. The header is a fixed 3-byte value and will not be processed further. The sequence of header processing is described in “Frame Format”. This document show the details of the various processing stages.

If you want to program a compatible modem, just copy these functions as-is into your application, initialize them at program start and use them.

Scrambler

Scrambling is used to prevent long sequences of same values, which would make synchronization in the receiver impossible.

scrambler.cpp uses a table with pseudo-random values and X-ORs the complete frame (except the header) with these values.

The receiver unscrambles the frame with the same function to get the original data.

FEC

many different FEC/Reed Solomon algorithms have been tested at a signal SNR of +15dB above noise.

The best results delivered the “Shifra” reed solomon code. This code is free and open source for non-commercial projects like HSmodem. A wrapper for HSmodem is in fec.cpp. It has functions to initialize, generate and decode the FEC for one complete frame.

CRC16

A standard CRC16 algorithm is used with a generator polynom of 0x8408. The code is simple and located in crc16.cpp

en/scrambler.txt · Last modified: 2021/01/19 13:15 by kurt

Page Tools