1. Field of the Invention
The present invention relates to (wireless) receivers, and, in particular, to buffer-based methods for generating Orthogonal Variable Spreading Factor (OVSF) codes for the spreading and despreading of data.
2. Description of the Related Art
When a signal travels through a real-world environment, it often reaches a receiver by multiple paths. These paths occur as a result of the signal reflecting, diffracting, and scattering from various elements in the environment, e.g., mountains, trees, and buildings. Multi-path components are essentially time-delayed variants of a single signal. While, in some applications, these multiple components may result in interference, e.g., ghosting on the display of an analog television receiver, Code Division Multiple Access (CDMA) systems intentionally make use of these multiple components.
The basic principle of CDMA systems is orthogonal coding, whereby, instead of assigning specific frequencies or time slots to each user of a system, the users are distinguished from one another by assigning codes. The codes fulfill the same role as frequency or time in frequency- or time-division systems, i.e., to keep the signals for different users from interfering with one another. In orthogonal spreading, a symbol is XOR-multiplied by a defined sequence of bits called a “code sequence” (also called a “code pattern” or simply a “code”). If the code sequence length is n bits, then each symbol is transformed to n so-called chips. The resulting chip rate, i.e., the number of chips per second (e.g., bits per second), is n times the original symbol rate (number of symbols per second). For example, the spreading code sequence 1111 has a length, also called a spreading or spread factor (SF) or Orthogonal Variable Spreading Factor (OVSF), of four. A single 1 will be spread to the sequence 0000 (1 XOR'ed with 1 gives 0), and a single 0 will be spread to the sequence 1111. In general, code sequences are not arbitrarily chosen, but rather, selected according to certain mathematical rules that provide sets of code sequences that are orthogonal to each other. Orthogonal code sequences have no correlation. Consequently, signals spread with code sequences that are orthogonal to each other do not interfere with one another. For a single connection, input data is spread with a particular code sequence at the transmitter end. To recover the data, the same orthogonal code sequence is used at the receiver end to despread the signal.
Implementation of OVSF spreading and/or despreading operations in a transmitter and/or receiver requires the generation of OVSF codes. The most common and widely used solution requires a chip-rate counter to drive an OVSF generation circuit. The OVSF generation circuit performs an XOR operation between the current count from the chip-rate counter and the OVSF code index in reverse order to produce an OVSF sequence bit every cycle.
However, there is a need for an OVSF code generator that is not limited by the constraints imposed by the use of a chip-rate counter (where count values are used in an algorithm for generating OVSF code sequences), e.g., to be able to generate OVSF codes asynchronously with respect to a chip counter.