Embodiments of the present invention provide a fast, software-implemented
data scrambling system for data communications. For pseudo-random codes
that are periodic within a predetermined number of bits, a memory array
may be populated with segments of the code, one entry in the array
starting at a unique bit position within the code. During data
scrambling, a seed code may be used to identify a first entry from the
array that should be used for scrambling. Thereafter, subsequent segments
may be retrieved by traversing the array in a regular fashion. By
calculating the code before use and by populating the array prior to
processing of any source data, the system is very fast.