A spread-spectrum demodulator includes a spreading code generating
section, correlation value computing section, data signal demodulating
section, peak signal detecting section, and spreading code generation
control section. The spreading code generating section generates a
spreading code for correlating with a received spread signal. The
correlation value computing section computes a correlation value between
the spread signal and the spreading code output from the spreading code
generating section. The data signal demodulating section detects the peak
of an output from the correlation value computing section and demodulates
a data signal on the basis of the detected peak. The peak signal
detecting section detects the peak of the output from the correlation
value computing section. The spreading code generation control section
changes the shifting direction of the spreading code relative to the
spread signal every time a peak is detected by the peak signal detecting
section.