PDM to PCM latency in mic array library routine Topic is solved

Technical discussions related to any XMOS development kit or reference design. Eg XK-1A, sliceKIT, etc.
Post Reply
woodsb
Experienced Member
Posts: 79
Joined: Thu Nov 17, 2016 11:24 pm

PDM to PCM latency in mic array library routine

Post by woodsb »

Hello,

I have been working with the microphone array library to convert PDM mic data to PCM words for processing. Figure 1 in the Microphone array library 3.0.0 doc (http://www.xmos.com/download/private/li ... rc1%29.pdf) shows the steps.

I'd be grateful if someone could tell me what the latency is from the input to the "Div 8 Decimator" block to the output of the "Div N, Decimator, N=2,4,6,8 or 12" block.

I'm particularly interested in the latency value for 16 and 48 kHz output sample rates.

Thank you,
Bill


View Solution
User avatar
infiniteimprobability
XCore Legend
Posts: 1126
Joined: Thu May 27, 2010 10:08 am
Contact:

Post by infiniteimprobability »

Hi Bill,
we only specify the total group delay from PDM to output PCM which is:
16.5 Group delay
The group delay of the default filters is 18 output clock cycles. This can be shortened by either using a minimum phase FIR as the final stage decimation FIR and/or by reducing the number of taps on the final stage decimation FIR.

So 18 sample periods at the output sample rate. This is true across all supported sample rates.

Is there a reason you need a breakdown of that? Are you tapping signals off in between? They are all symmetric FIRs and have an even number of taps so the group delay is half the number of taps at each stage.
woodsb
Experienced Member
Posts: 79
Joined: Thu Nov 17, 2016 11:24 pm

Post by woodsb »

Hello,

Thanks for the info. Sorry to learn it's in the doc I cited!

I asked the way I did in order to ask the question about the blocks (the first 3 decimator blocks) I didn't have a detailed understanding of. I understood the details of the last two blocks of the process shown in Fig. 1. Also, I wasn't sure if the delay was the same for all sample rates and have been looking at using 16 and 48 kHz rates.

cheers,
Bill
User avatar
infiniteimprobability
XCore Legend
Posts: 1126
Joined: Thu May 27, 2010 10:08 am
Contact:

Post by infiniteimprobability »

Sorry to learn it's in the doc I cited!
No problem. I did exactly the same thing with the author of lib_mic_array recently!
Also, I wasn't sure if the delay was the same for all sample rates and have been looking at using 16 and 48 kHz rates
Yes it is, in terms of output sample periods but obv. that means the delay in seconds will depend on the sample rate. I have modified my answer to make that clearer for others.
Post Reply