AN2254 Freescale Semiconductor / Motorola, AN2254 Datasheet - Page 13

no-image

AN2254

Manufacturer Part Number
AN2254
Description
Scrambling Code Generation for WCDMA
Manufacturer
Freescale Semiconductor / Motorola
Datasheet
increment
value 1,
1,
increment
3.4 Complex Scrambling of an IQ/Code Multiplexed Signal
This section describes in detail how complex scrambling code is formed on the SC140 DSP core, and also
describes the process of actual complex scrambling of an I/Q code multiplexed signal. With its four ALUs, the
SC140 core can compute complex numbers and perform several different operations very efficiently. Imposing one
constraint on the incoming complex signal is required to ensure that all entries of the incoming I-Q/code
multiplexed signal are less than one to help prevent overflow. After complex scrambling, the final output signal is
scaled down by a factor of 2 and stored in memory.
After the complex signal has been formed, it is time for scrambling the received data. This function carries out the
complex scrambling operation according to Equation 16. The received I-Q/code multiplexed signal is multiplied
by the complex scrambling code, and the Output_IQ is stored in memory. Following is the flow of the assembly
code in Example 4 for generating the complex scrambling sequence from previously-generated binary PN code
and scrambling the received data:
Freescale Semiconductor
mappingloop
1.
2.
START mainloop #38400.
Read the I and Q, complex scrambling code from memory, 1-word sample at a time.
Scrambling Code Generation for WCDMA on the StarCore™ SC140/SC1400 Cores, Rev. 1
endsec
]
loopstart1
[
tfrf d14,d11
and #MASKONE,d12,d2
asr d12,d12
]
[
moves.2f d10:d11,(r0)+
tsteq d2
tfr d13,d10
and #MASKONE,d8,d3
asr d8,d8
]
[
tfrf d14,d10
tsteq d3
tfr d13,d11
]
loopend1
tfrf d14,d11
moves.2f d10:d11,(r0)+
loopend0
[
pop r6
pop r7
]
[
pop d6
pop d7
]
rts
Software Implementation on the StarCore SC140/SC1400 Cores
;//if c2==1, map into real value -1, i.e. put 0.5
;//extract c1’s least sig. bit
;//shift out the c1 bit already checked
;//move I and Q scrambling code into memory buffer,
;//buffer
;//test c1’s bit for 0 or 1
;//I part of scram. code, assume c1==0, map into real
;//i.e. put 0.5
;//extracts c2’s least sig. bit
;//extracts c2’s least sig. bit
;//I part of scram. code, if c1==1, map into real value -
;//i.e. put -0.5
;//test c2’s bit for 0 or 1
;//assume c2==0, map into real value 1, i.e. put 0.5
;//if c2==1, map into real value -1, i.e. put 0.5
;//move I and Q scrambling code into memory buffer,
;//buffer
13

Related parts for AN2254