APPARATUS AND METHOD FOR GENERATING SPREADING CODE IN CDMA COMMUNICATION SYSTEM

Abstract: A device for generating a spreading code in a CDMA communication system is disclosed. In the device, an ML (Maximal Length) sequence generator generates an ML sequence according to a generator polynomial of an ML sequence having a length 2<S>-1 and a given initial value, and reloads the initial value whenever an ML sequence having a length shorter than the length 2<S>-1 is generated, to repeatedly perform an operation of generating the ML sequence. A mask selector including first and second masks having a given offset, selects the first mask in an ML sequence period and selects the second mask in the other period. A modulo-2 adder adds an output of the ML sequence generator and an output of the mask selector to generate the spreading code, and truncates the ML sequence upon receipt of the second mask.

Description: APPARATUS AND METHOD FOR GENERATING SPREADING CODE IN CDMA COMMUNICATION SYSTEM BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates generally to a device and method for generating spreading code in a CDMA communication system, and in particular, to a device and method for generating spreading code for spread spectrum. 2. Description of the Related Art In an existing IS-95 CDMA system, spread spectrum is performed at a chip rate of 1.2288x10° cps (chips per second), so that a short PN (Pseudo Noise) code is generated at the chip rate of 1.2288xl0 6 cps. Since the short PN code should be generated during one- frame period (80msec/3≡26.67msec) of a sync channel, the short PN code has a period of 2 15 chips (1.2288xl0 6 cps * .02667 sec). FIG. 1 shows a conventional device for generating spreading codes. Referring to FIG. 1 , the spreading code generator generates a short PN code using a generator for generating an ML sequence (M-sequence and/or Maximal-Length sequence, hereinafter the two terms will be used interchangeably) of length 2 15 -1. The generator is comprised of 15 shift registers labeled R1-R15. By inserting one '0' after 14 '0' sequences generated in every period of 2 15 -1, the resulting sequence is used as a short PN code of length 2 15 . A generator polynomial of the ML sequence generator is used for identifying a code as well as a factor for determining a partial correlation property of the code The IS-95 standard identifies two phase channels (i.e., In-phase and Quadrature-phase channels) that use different polynomials and employ two different ML sequences. A short PN code having a delay effect by a specific period Δ with regard to the generated short PN code can be obtained by selectively module-2 adding the shift register values of the generator polynomial. That is, in FIG. 1, modulo-2 adders 101- 115 modulo-2 add outputs of their associated shift registers R1-R15 to the outputs of their associated AND gates 122-135, and provide their outputs to shift registers in the next stages. To select a shift register value for modulo-2 adding, a mask Short_PN_Code_Mask[0: 14] is used. That is, different mask values are applied to generate short PN codes having a different offset (or phase difference). A proposed IMT-2000 system based upon a CDMA-2000 system supports a wideband CDMA system having a spreading frequency bandwidth greater than 1.2288xl0 6 cps. For a short PN code used in this case, 2 s -1 (where s is a positive number) sequences are partially selected from an ML sequence of length 2 15 xN (where N is multiple of 3) which is not the conventional ML sequence of 2 15 -1. Table 1 below shows a length of the short PN code required for each chip rate. [Table 1] Although an offset delay value for identifying the base station is applied to the generated short PN code, only the partially selected sequence should occur. However, in the conventional method in which an offset-delayed short PN code is generated by simply applying one mask, a sequence departing from the selected ML sequence period may be generated undesirably. Such problems will be described with reference to FIG. 2. FIG. 2 shows a method for determining a short PN code having a length p=2 lD x3 from an ML sequence having a length m=2 17 -l represented by (b). Assume that the method for generating the spreading code having a length 2 15 x3 shown in FIG. 1 is expanded to generate a short PN code by selecting only the first 3/4 portion from an ML sequence of length 2 17 -1, in which 17 shift registers are provided. Assuming that a value selected from one period value of the binary ML sequence represented by (b) is C 0 and a short PN code is generated by selecting sequence values of length p beginning at the sequence value C 0 , the remaining (m-p) sequences out of the total m ML sequences correspond to an unused sequence. There is a simple method for generating the short PN code by selecting a partial period of the whole ML sequence. In this method, a present state, represented by (d), of the shift register for generating the ML sequence or a sequence output is monitored. Further, after the state of the shift register becomes S p _, as represented by (d) of FIG. 2, or after a (p-l)th sequence occurs, an initial state signal represented by (c) is generated to initialize the shift register so that the first sequence C 0 is output. A description will be made regarding a phenomenon occurring when only one mask value Maskjr corresponding to 'r' is applied as shown in FIG. 1 to apply an offset delay to the generated short PN code represented by (e) of FIG. 2. In this case, as shown by (f) of FIG. 2, the offset delay value 'r' is applied to the ML sequence value in an A period corresponding to the sequences from 0 th sequence to an (r-l)th sequence to generate (m-r)th to (m-l)th sequence values out of the original whole ML sequence of length 'm', and generate 0 th to (p-r-l)th ML sequence vales from rth to (p-l)th ML sequences. This is because based on a unique property of the ML sequence, the offset delay value is determined according to the present shift register state and the mask value, and since a period of the original ML sequence is 'm', the offset delay occurs based on this period. Therefore, (m-r)th to (m-l)th ML sequence values belonging to the unused period occur in the A period. The presence of the sequence values in the A period is against the original intention of cyclic delaying only the original ML sequence values of 0 th sequence C 0 to (p-l)th sequence C p -]. That is, to achieve the desired cyclic offset delay as represented by (g) of FIG. 2, the offset delay value 'r' is applied to 0th to (r-l)th ML sequence values C Q -C.. ! SO as to generate (p-r)th to (p- l)th sequence values of the original ML sequence. As described above, when the conventional spreading code generation method generates a short PN code using only one mask, the undesired output is obtained in the A period of FIG. 2. To solve such problems, there is required a mask, Mask_(m-p+r), for further delaying by 'm-p' which corresponds to a length of the unused sequence of the original ML sequence, instead of using the mask Mask_r for delaying by 'r' in the A area. SUMMARY OF THE INVENTION It is, therefore, an object of the present invention to provide a device and method for generating a short PN code for spread spectrum in a CDMA communication system. It is another object of the present invention to provide a device and method for generating a spreading code having a short period from a sequence having a long period in a CDMA communication system. It is further another object of the present invention to provide a spreading code generation device and method which uses at least two masks in consideration of an offset so that an unused sequence period out of the whole sequence having a long period should not occur in the spreading code having the offset, in a CDMA communication system. To achieve the above object, there is provided a device for generating a spreading code in a CDMA communication system. In the device, an ML (Maximal Length) sequence generator generates an ML sequence according to a generator polynomial of an ML sequence having a length 2 s - 1 and a given initial value, and reloads the initial value whenever an ML sequence having a length shorter than the length 2 s - 1 is generated, to repeatedly perform an operation of generating the ML sequence. A mask selector including first and second masks having a given offset, selects the first mask in an ML sequence period of the desired length and selects the second mask in the other period. An adder modulo-2 adds an output of the ML sequence generator and an output of the mask selector to generate the spreading code, and truncates the ML sequence upon receipt of the second mask. BRIEF DESCRIPTION OF THE DRAWINGS The above and other objects, features and advantages of the present invention will become more apparent from the following detailed description when taken in conjunction with the accompanying drawings in which: FIG. 1 is a diagram illustrating a device for generating spread spectrum spreading codes in an existing CDMA communication system; FIG. 2 is a diagram for explaining a procedure for generating a spreading code using one mask in the existing CDMA communication system; FIG. 3 is a diagram illustrating a device for generating spread spectrum spreading codes in a CDMA communication system according to an embodiment of the present invention; FIG. 4 is a timing diagram for generating spreading codes in the spreading code generation device of FIG. 3; and FIG. 5 is a diagram illustrating a procedure for generating a mask select signal and an M-sequence reload signal. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENT A preferred embodiment of the present invention will be described herein below with reference to the accompanying drawings. In the following description, well-known functions or constructions are not described in detail since they would obscure the invention in unnecessary detail. A CDMA communication system identifies base stations by assigning different offset delay values for a short PN code, and uncorrelates interference between multiple paths when multi-path delay occurs which is a general channel property of the mobile communication channel. With regard to the short PN code, all the mobile stations connected to one base station use the codes having the same offset delay value. When the mobile station handoff to another base station, the mobile station should use a code having different offset delay value. In particular, while a soft handoff is being performed, one mobile station may assign two or more different offset delay values to demodulation fingers of the rake receiver for the respective multi-paths to perform demodulation. Here, to generate a short PN code having a desired offset delay value, a common method applies a proper mask for the desired offset delay vale to a short PN code having an offset delay value of 'r'. Meanwhile, in an IS-95/IS-95A or CDMA-2000 (or IS-2000) system, for the short PN code, a binary code of period 32768 chips is typically used which is obtained by adding one '0' to an ML (Maximal Length) sequence having a chip rate of 1.2288MHz and a period of 32768 chips. A length of the binary code is identical to one-frame length (80msec/3) of the sync channel. However, the 3 rd generation IS-2000 or UMTS CDMA systems may have a spreading frequency bandwidth wider than that of the IS-95 system. For example, in a 3xCDMA-2000 (IS-2000) system having a bandwidth of 1.2288x3-3.6864MHz, which is three times the spreading frequency bandwidth of the IS-95 system, to maintain the constant frame length (80msec/3) of the sync channel, there is required a short PN code having a length 32768x3. This is three times the length of the existing IS-95 short PN code. That is, in the wideband communication system having a wider spreading bandwidth than the existing CDMA communication system, a period of the desired short PN code varies according to applied bands. However, when the ML sequence is used for the short PN code as in the existing IS-95 system, the full period is always 2 s (where s is a integer number; although the period of the ML sequence is always 2 s -1, one '0' is added to make the period become 2 s in a CDMA system, for convenience of implementation) based on the theoretical property of the ML sequence. Therefore, when the period of the desired short PN code is 2 15 xN (where N is a multiple of 3), it is not possible to use the short PN code comprised of the full period of the ML sequence and instead, a partial period of the ML sequence of period 2 15 xN (where N is a multiple of 3) should be used. However, when the short PN code is comprised of only a partial period of the ML sequence, the following problems occur. That is, as stated above, when a mask is simply applied as in the conventional method to generate a short PN code having a specific offset delay value, the generated code includes even the undesired period which is not the desired partial period of the ML sequence. Accordingly, the present invention proposes a method for generating a short PN code having a desired offset delay value, in the case where for a length of the desired short PN code, a partial period should be selected from the theoretical full period of the ML sequence. Although the invention will be described with reference to the IS-95 and IS-2000 systems for convenience of explanation, it will be understood by those skilled in the art that the invention can be applied to every system in which the short PN code is comprised of the partial period of the ML sequence. FIG. 3 shows a device for generating a spreading code having a chip period of 32768xN (N=3,6,9,12) according to an embodiment of the present invention. Referring to FIG. 3, registers 320 to 32s- 1 constitute a shift register. The registers 320 to 32s- 1 are initialized by an initial state value INITIAL_STATE[0:s- 1]. The output value of the register 32s-l is provided to AND operators 300 to 30s-l . The AND operators 300 to 30s-l AND the output of the register 32s-l with their associated coefficients aO to as-1 of the generator polynomial. Adders 310 to 31s-l connected between the registers, modulo-2 add the outputs of the AND operators 301 to 30s-l and the outputs of the previous stages and then store the resulting values to the registers in the next stages. A controller 360 generates a PN_ROLL_OVER signal for controlling the period 32768xN, and a mask select signal for selecting a corresponding mask. A selector 340 receiving a first mask Maskl[0:s-1] and a second mask Mask2[0:s-1], selects a mask signal according to the mask select signal output from the controller 360. AND gates 330 to 33s-l each AND the output values R to R-.., of registers 320 to 32s- 1 with the mask signal selected by the selector 340. A modulo-2 adder 350 adds the output values of the AND operators 330 to 33s- 1 to generate a short PN code. Referring to FIG. 3, the spreading code generator according to an embodiment of the present invention includes an ML sequence generator 370 and the controller 360. The ML sequence generator 370 generates an ML sequence which can reload the initial shift register values Ro to R^, according to the generator polynomial of the ML sequence in order to generate a PN code generator which truncates a desired period from the spreading code of length 2 s - 1 (where S is the number of the shift registers) generated by the ML sequence generator and repeatedly generates the truncated period. The controller 360 selects the desired length of the spread spectrum spreading code from the whole spreading code of the generated ML sequence. Further, the spreading code generator includes the modulo-2 adders 310 to 31s-2 and the selector 340, in order to generate a spreading code having a specific offset with regard to the selected spreading code. The modulo-2 adders 310 to 31s-l selectively modulo-2 add the output values of the shift registers 320 to 32s- 1 according to the mask value to generate an offset-delayed spreading code having a specific offset with respect to the generated original spreading code. The selector 340 selects one of the two mask values to generate the spreading code. FIG. 4 shows a timing diagram for generating a short PN code of chip period 2 15 x3 according to an embodiment of the present invention. The invention will be described with reference to an example wherein a short PN code of chip period p=2 15 x3 is generated when a spreading band has a chip rate of 1.2288xl0 6 x3. Referring to FIGS. 3 and 4, to generate a short PN code of chip period p=2 15 x3, an ML sequence generator having a minimum period of 2 17 -1 can be used. A generator polynomial of the ML sequence generator can be expressed as shown in Equation (1) below. [Equation 1] P(x)=x 17 +al6-x lo +al5-x 15 +al4-x 14 +al3-x 13 +al2-x ,2 +all-x"+al0-x 10 +a9-x 9 +a8-x 8 +a7-x 7 +a6-x D +a5-x 5 +a4-x 4 +a3-x 3 +a2-x 2 +al-x 1 -r-a0 In Equation (1), 'an' (where n=0,l,--,16) is a coefficient of the generator polynomial and has a value of '0' or ' 1 '. This can be implemented using 17-stage shift registers R Q to R^ and modulo-2 adders 310 to 31s-2 as in the ML sequence generator 370 of FIG. 3. The initial values 0 to s-1 of the 17-stage register in the ML sequence generator 370 should be reloadable. This is because the spreading code of chip period 2 l5 x3 can be generated by continuously reloading the initial values of the 17-stage register in the ML sequence generator 370 every 2 15 x3 chip. The spreading code generator requires a control signal generator for generating a control signal (i.e., a short PN code initial state load enable signal) for reloading the initial state value of the 17-stage register. The control signal is generated by the controller 360. The controller 360 can generate the control signal by using a counter having a period p=2 I5 x3 and providing a device for comparing the values of the shift registers Ro to R-.j. The method using the values of the shift registers R Q to R^ generates the control signal (i.e., short PN code initial state load enable signal) to reload an initial state S 0 when a state value of the shift register is S p _,, as shown in FIG. 4. In this manner, it is possible to generate a short PN code of period p=2 15 x3 from the ML sequence generator 370 having a period m=2 17 -l. With respect to the short PN code determined in the above-stated method, the short PN code having a specific offset can be generated by selectively modulo- 2 adding the state values of the shift registers, and this can be implemented by the block 380 of FIG, 3. Selection of the modulo-2 added value from the shift register is determined according to a mask value, and different mask values are required according to the desired offset. In the embodiment of the present invention, the short PN code of period 2 15 x3 is determined by truncating the M-sequence of period 2 17 -1. When the short PN code having an offset is generated using the mask, consideration should be given to the unused codes out of the generated codes. Considering this, the embodiment of the present invention includes at least two types of mask sets: Maskl and Mask2. That is, the embodiment of the present invention includes two masks to apply a first mask to an M sequence in a first period and a second mask to an M sequence in a second period, so that it is possible to generate one short PN code using the masks having different offsets. Such mask operation is performed by the selector 340, and the selector 340 is controlled by the controller 360. The controller 360 maintains selection of a specific mask before a length of the generated spreading code becomes the desired offset value 'r' of the generated spreading code, and generates a mask select signal for selecting the other mask when the length exceeds the offset value 'r' (i.e., when a spreading code of the desired length is generated). A detailed description of the mask selection process will be described below. When the untruncated original ML sequence show by 413 of FIG. 4 is M 0 , the spreading code M represented by 419 of FIG. 4 is determined by truncating the sequence M 0 at p=2 15 x3. A masked PN sequence M r , represented by 421 of FIG. 4, having an offset 'r' from the spreading code M is available by combining the output values of the shift register of a generator for generating the code M represented by 419 with a mask (Maskl in the embodiment) required for phase delay (or offset) 'r'. Here, when the Maskl is used for the code value M=[C 0 :C r .,], the code values [C p :C m ] of the unused period of the original code M 0 are generated undesirably. Therefore, in the embodiment, in this period [C 0 :C ], the Mask2 is used which causes the offset of 'r+m-p' rather than 'r'. FIG. 5 shows a procedure for generating a mask select signal and an initial state load enable signal in the controller 360 of FIG. 3. Referring to FIG. 5, a count value CNT includes a state of the ML sequence and an index for an output value, and a given state desired by the user is assumed to be a 0 th state. The controller 360 initializes the count value CNT to '0' in step 511, and then increases the count value CNT by one each time the clock is generated, in step 513. Thereafter, the controller 360 compares the count value CNT with the offset value V in step 515. When the count value CNT is lower than the offset value 'r', the controller 360 proceeds to step 517 and enables a mask select signal to select Mask2. Otherwise, the controller 360 proceeds to step 521 and disables the mask select signal to select Maskl . The selector 340 then selects Maskl or Mask2 according to the mask select signal from the controller 360. The mask select signal provided to the selector 340 is shown by 425 of FIG. 4, and the mask output from the controller 360 is shown by 423 of FIG. 4. The mask output from the selector 340 is provided to the AND gates 330 to 33s- 1. After selecting Maskl in step 521, the controller 360 determines in step 523 whether the count value CNT is equal to a length (p-1) of the desired short PN code. When the count value CNT is not equal to the length of the desired spreading code, the controller 360 returns to step 513 to repeat the above operation. However, when the count value CNT is equal to the length of the desired spreading code, the controller 360 generates an initial state reload signal and provides the generated signal to the M-sequence generator 370, in step 525. The M-sequence generator 370 then loads the initial state value INITIAL_STATE[0:s-l] and returns to the initial state of the ML sequence. As described above, the novel spreading code generator generates a short PN code of desired length by operating the ML sequence of the desired length and the first mask from a spreading code of length 2 s - 1 generated by the ML sequence generator and performs truncation by operating the ML sequence of the unused period and the second mask having a specific offset with the first mask, so as to generate a spreading code having a length of the short PN code during one frame of the sync channel. Therefore, the short PN code is generated by repeating the above process. At this point, a partial period of the ML sequence should be selected in consideration of partial correlation of the spreading code and distribution balance of the binary value. In addition, it is possible to generate a spreading code having a specific offset with respect to the spreading code partially selected from the ML sequence. While the invention has been shown and described with reference to a certain preferred embodiment thereof, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention as defined by the appended claims.

Claims: WHAT IS CLAIMED IS: 1. A device for generating a spreading code in a CDMA (Code Division Multiple Access) communication system, comprising: an sequence generator for generating an sequence according to a generator polynomial of an sequence having a length 2 s - 1 and a given initial value, and reloading the initial value whenever an sequence having a length shorter than the length 2 s - 1 is generated, to repeatedly perform an operation of generating the sequence; a mask selector including first and second masks having a given offset, for selecting the first mask in an sequence period and selecting the second mask in another sequence period; and an adder for modulo-2 adding an output of the sequence generator and an output of the mask selector to generate the spreading code, and truncating the sequence upon receipt of the second mask. 2. A spreading code generating device for a CDMA communication system, which generates a spreading code having a length short than a length 2 s - 1 from an sequence having the length 2 s - 1, the device comprising: an sequence generator for generating an sequence according to a generator polynomial of an sequence having a length 2 s - 1 and a given initial value, and reloading the initial value upon receipt of a reload control signal to repeatedly perform an operation of generating the sequence; a controller for analyzing a length of the generated sequence, and generating the reload control signal and a mask select signal when the sequence of desired length is generated; a mask selector including first and second masks having a given offset, for selecting the second mask upon receipt of the mask select signal; and an adder for modulo-2 adding an output of the sequence generator and an output of the mask selector to generate the spreading code, and truncating the sequence upon receipt of the second mask. 3. A spreading code generating method for a CDMA communication system, which generates a spreading code having a length shorter than a length 2 s - 1 from an sequence having the length 2 s - 1, the method comprising the steps of: generating an sequence according to a generator polynomial of an sequence having a length 2 s - 1 and a given initial value; adding, using modulo-2 addition, the generated sequence and a first mask to generate the spreading code; analyzing a length of the generated sequence, reloading the initial value whenever the sequence of desired length is generated; adding, using modulo-2 addition, a second mask having a given offset with the first mask; and truncating the generated sequence.

Inventors: BAE SANG-MIN, CHO MI-YOUNG, BAE, SANG-MIN, CHO, MI-YOUNG
Applicants: SAMSUNG ELECTRONICS CO LTD, SAMSUNG ELECTRONICS CO., LTD.
Application year: 2000
Main classification: H04J13
IPC codes: H03K3, H04B1, H04B7, H04J13