A method for compensating a frequency response of a microphone, comprising: multiple microphones (micl, mic2, micN) in a microphone array receiving a compensation signal sent from a calibration speaker and outputting multiple output signals; determining a uniform frequency response of the multiple microphones (mic1, mic2, micN) based on the multiple output signals; calculating a compensation gain for each of the multiple microphones (micl, mic2, micN) according to the uniform frequency response; storing the calculated compensation gain of each microphone; and determining whether the calibration speaker is positioned to be equally spaced from the microphones (micl, mic2, micN) in the microphone array, wherein when the calibration speaker is not positioned to be equally spaced from the microphones (micl, mic2, micN) in the microphone array, it is determined whether the calibration speaker is located on a central symmetry axis of the microphone array, if the calibration speaker is located on the central symmetry axis of the microphone array and the number of microphones (micl, mic2, micN) in the microphone array is an even number, the multiple microphones (micl, mic2, micN) are grouped by grouping every two microphones equally spaced from the calibration speaker, if the calibration speaker is located on the central symmetry axis of the microphone array and the number of microphones (micl, mic2, micN) in the microphone array is an odd number, multiple microphones (micl, mic2, micN) other than the microphone located on the central symmetry axis are grouped by grouping every two microphones equally spaced from the calibration speaker, and when the number of microphones (micl, mic2, micN) in the microphone array is an even number, a frequency response of an output signal of one microphone in each group of microphones is selected as a uniform frequency response of the group, a compensation gain of the selected microphone is set to 1, and a compensation gain of the other microphone in the group of microphones is calculated as a ratio of the uniform frequency response of the group to a frequency response amplitude of an output signal of the other microphone in the group of microphones. multiple microphones (micl, mic2, micN) in a microphone array receiving a compensation signal sent from a calibration speaker and outputting multiple output signals; determining a uniform frequency response of the multiple microphones (mic1, mic2, micN) based on the multiple output signals; calculating a compensation gain for each of the multiple microphones (micl, mic2, micN) according to the uniform frequency response; storing the calculated compensation gain of each microphone; and determining whether the calibration speaker is positioned to be equally spaced from the microphones (micl, mic2, micN) in the microphone array, wherein when the calibration speaker is not positioned to be equally spaced from the microphones (micl, mic2, micN) in the microphone array, it is determined whether the calibration speaker is located on a central symmetry axis of the microphone array, if the calibration speaker is located on the central symmetry axis of the microphone array and the number of microphones (micl, mic2, micN) in the microphone array is an even number, the multiple microphones (micl, mic2, micN) are grouped by grouping every two microphones equally spaced from the calibration speaker, if the calibration speaker is located on the central symmetry axis of the microphone array and the number of microphones (micl, mic2, micN) in the microphone array is an odd number, multiple microphones (micl, mic2, micN) other than the microphone located on the central symmetry axis are grouped by grouping every two microphones equally spaced from the calibration speaker, and when the number of microphones (micl, mic2, micN) in the microphone array is an even number, a frequency response of an output signal of one microphone in each group of microphones is selected as a uniform frequency response of the group, a compensation gain of the selected microphone is set to 1, and a compensation gain of the other microphone in the group of microphones is calculated as a ratio of the uniform frequency response of the group to a frequency response amplitude of an output signal of the other microphone in the group of microphones.