[Sound-open-firmware] [PATCH 1/4] [RFC]DMIC: Add PDM microphones (DMIC) support to DAI

Pierre-Louis Bossart pierre-louis.bossart at linux.intel.com
Wed May 2 18:54:49 CEST 2018


On 5/2/18 10:27 AM, Seppo Ingalsuo wrote:
> 
> 
> On 02.05.2018 16:43, Pierre-Louis Bossart wrote:
>>>>> +    /* Calculate CIC shift from the decimation factor specific gain.
>>>>> +     */
>>>>> +    mcic = cfg->mcic;
>>>>> +    g_cic = mcic * mcic * mcic * mcic * mcic;
>>>>
>>>> yikes, what is this mcic^5 ?
>>>
>>> Yep, it's the gain for +1 / -1 PDM bits in CIC decimator part. It's 
>>> needed to set the scaling HW shifter. It also gives some idea of 
>>> oversampling ratios to use for a microphone to get some # of bits of 
>>> resolution as PCM code.
>>
>> I meant: where does this ^5 come from? First time i see this sort of 
>> formula in filter design.
> 
> I see now -- There's a 5th order integrator-comb filter as 1st 
> decimation filter stage for the PDM bits. Wikipedia has nowadays 
> everything:
> 
> https://en.wikipedia.org/wiki/Cascaded_integrator%E2%80%93comb_filter
> 
> The high DC gain is caused by the integration part. The 1st equation 
> with the Sigma statement shows the transfer function. By setting R=mcic, 
> N=5, omega = 0 the same DC gain formula that I used is achieved.

Do I get this right that this 5 figure is hardware-related and used to 
figure out the compensation that needs to happens in additional 
FIR-based processing?


More information about the Sound-open-firmware mailing list