## 3 DSSS in Electric Field Communication
### The Demodulation of DSSS BPSK Signals  
At the receiving end, the received spread spectrum signal undergoes high-frequency amplification and mixing. It is correlated with a pseudorandom code sequence synchronized with the transmitter to despread the intermediate frequency spread modulation signal, restoring the spectrum of the spread modulation signal to that of the intermediate frequency modulation signal. Then, demodulation is performed to recover the transmitted baseband signal, completing the information transmission.  
A spread spectrum BPSK system builds upon baseline BPSK modulation and demodulation by incorporating spreading and despreading functions. The demodulation circuit still requires a Costas loop for carrier recovery [23]. The Costas loop, employed in the extraction of coherent carriers, also accomplishes the demodulation of baseband signals. Upon extracting the demodulated baseband signal, synchronization of the symbol clock for information bits can be associated with the pseudocode symbol clock. The synchronization of one naturally leads to the synchronization of the other. A pseudorandom code despreading module is added to the Costas loop so that the receiver can achieve bit synchronization, Ref. [24] pseudorandom code synchronization, and carrier synchronization with the transmitter, as shown in Figure 5.  
Pseudocode synchronization consists of two stages: capture and tracking. In the acquisition stage, the local signal is correlated with the received signal to obtain correlation values. A threshold detection is used to determine whether the useful signal has been acquired. In the specific implementation, when the received pseudorandom code sequence deviates in frequency from the local pseudorandom code sequence, the two sequences slide relative to each other in phase. Upon the phases of the two sequences coinciding at a  
Figure 4: Waveform and spectrum of a DSSS modulated signal.  
Figure 5: Flowchart of spread spectrum BPSK demodulation.  
certain moment, i.e., achieving phase alignment, the correlation value exhibits its maximum output. The sliding is halted at this point, marking the completion of the capture operation. Once the useful signal is acquired, and the phase difference between the pseudocodes at the transmitter and receiver is within one pseudocode chip, the system enters the tracking stage.  
The capture and tracking stages employ distinct loops, with the two stages following a sequential order on the locking loop. This theoretical framework allows for the reuse of integrators, local pseudocode generators, and multipliers between the two loops, thereby minimizing the logical resource consumption in processing units. Paper [25] proposes a structure that reuses certain components between the capture and tracking loops. The primary principle involves using the squared sum of the leading and lagging branch accumulators from the delay-locked loop as a criterion for determining the presence of a useful signal. While the paper illustrates a flat sum of the peak outputs of the two branch accumulators, in practical terms and under the system's parameters, the curve of the sum of peaks exhibits a concave shape. This variation in the sum of peaks is unfavorable for determining whether the tracking loop is locked. Therefore, as shown in Figure 6, this paper introduces an additional correlator on the intermediate branch above the leading and lagging branches, serving as the decision basis for the capture state.