<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/91422/nrf5340-with-pdm</link><description>HI, 
 We are using the IM69D120 PDM mic for our audio application. I am able to interface the MIC and record audio with the NRF5340. 
 
 I have read the PDM data and stored it in an external SRAM connected through SPI. Then I read the data from SRAM and</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 24 Nov 2025 17:40:33 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/91422/nrf5340-with-pdm" /><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/555273?ContentTypeID=1</link><pubDate>Mon, 24 Nov 2025 17:40:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:315e148a-e951-4010-92d3-70bef6c2a6c5</guid><dc:creator>LjHuang</dc:creator><description>&lt;p&gt;Hi @Mr.NCK and @Kenneth,&lt;/p&gt;
&lt;p&gt;Sorry to bring up this old thread, but I am currently working on a very similar PDM audio setup on nRF5340 and I&amp;rsquo;m really interested in the final outcome of this case.&lt;/p&gt;
&lt;p&gt;From this discussion it looks like:&lt;br /&gt;- You were able to interface the IM69D120 PDM mic with the nRF5340, store the PDM data in external SRAM over SPI and send it over BLE.&lt;br /&gt;- You got clear audio when the SRAM was connected to Port 0 and when you did not use additional timer/thread.&lt;br /&gt;- When you moved the SRAM pins to Port 1, or when you started to use a Zephyr timer and an extra thread, you began to hear random clipping in the audio.&lt;/p&gt;
&lt;p&gt;I would like to ask a couple of follow-up questions:&lt;/p&gt;
&lt;p&gt;1. Did you finally manage to solve the clipping issue and get stable audio on nRF5340 (especially for the Port 1 + timer/thread case)? &lt;br /&gt; - If yes, was the root cause related to network core pin assignment, thread/timer priorities, buffer sizes, nRF Connect SDK version, or something else?&lt;/p&gt;
&lt;p&gt;2. Were there any specific changes you made in devicetree, Kconfig, PDM configuration, or the way you handled the PDM/ISR threads that were important to make the audio clean?&lt;/p&gt;
&lt;p&gt;3. If you have a small example project or can briefly describe the key steps of your working configuration, would it be possible to share it (even in a simplified form)?&lt;/p&gt;
&lt;p&gt;For context, my current setup is:&lt;/p&gt;
&lt;p&gt;- Board: nRF5340 Audio DK (PCA10121)&lt;br /&gt;- SoC: nRF5340&lt;br /&gt;- External PDM microphone: ST MP45DT02&lt;br /&gt;- nRF Connect SDK: v2.5.2&lt;br /&gt;- Goal: reliable PDM audio capture on nRF5340, and later feeding this PDM audio into the `nrf5340_audio` (Walkie Talkie) application as the audio source.&lt;/p&gt;
&lt;p&gt;Even a short summary of what worked and what did not work in your case would be extremely helpful. &lt;br /&gt;Thank you very much for your time and for any hints you can share!&lt;/p&gt;
&lt;p&gt;Best regards, &lt;br /&gt;LjHuang&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/384310?ContentTypeID=1</link><pubDate>Thu, 01 Sep 2022 11:28:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3885c5c9-efac-4310-bbdd-22c136992a1a</guid><dc:creator>Kenneth</dc:creator><description>[quote user="Mr.NCK"]&amp;nbsp; I have mentioned those Pins as Port 1. But I have not changed the pins to application core pins. Kindly tell me the procedure to do that. I will check.[/quote]
&lt;p&gt;If the problem was related to pin assignment between cores they should not work at all, you can find relevant information here on how this assignment is done (though this has changed a bit between ncs releases, so I am also adding a link to a devzone case);&lt;/p&gt;
&lt;p&gt;New:&amp;nbsp;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/build/dts/api/bindings/gpio/nordic,nrf-gpio-forwarder.html"&gt;https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/build/dts/api/bindings/gpio/nordic,nrf-gpio-forwarder.html&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Older:&amp;nbsp;&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/91165/nrf5340-how-to-reconfigure-pins-p0-08-p0-09-p0-10-p0-11-p0-12-for-spi-bus/382740"&gt;RE: nrf5340: How to Reconfigure Pins P0.08. P0.09, P0.10, P0.11, P0.12 for SPI Bus&lt;/a&gt;&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You do have&amp;nbsp;good&amp;nbsp;grounding between the mic and DK right, the pin header is&amp;nbsp;proper&amp;nbsp;connected?&lt;/p&gt;
[quote user="Mr.NCK"]the clipping sounds are random and are not at some regular intervals.&amp;nbsp;in all audio, we get like like one to 3 clipping sound at a random interval.[/quote]
&lt;p&gt;I doubt this is related to the pin assignment, it sounds much more related to application priority and not a pin conflict. I can not understand reason why changing pin the used by the PDM peripheral should cause what you describe. I suggest to continue debugging and simplify the project to narrow down the root cause, you may also consider looking at the audio source to make sure it&amp;#39;s not saturating the input etc.&lt;/p&gt;
&lt;p&gt;Hopefully you will be able to narrow it down and find root cause. If you are unable to make this work, then I guess you need to provide some means of me to recreate&amp;nbsp;this here, but then I likely would need your harware (or at least&amp;nbsp;the mic I can attach to the nRF5340-DK) and a project that I can use to change between the pins when running on the DK.&lt;/p&gt;
&lt;p&gt;Edit; You are on a recent release of ncs?&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/384275?ContentTypeID=1</link><pubDate>Thu, 01 Sep 2022 08:24:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:063ce22a-c21e-4bfc-8f95-0f029649ace0</guid><dc:creator>Mr.NCK</dc:creator><description>&lt;p&gt;Hi Keneth,&lt;/p&gt;
[quote userid="2111" url="~/f/nordic-q-a/91422/nrf5340-with-pdm/384253"]The only thing I can think of that have some influence here is that port1 by default is setup to be used by the network core. But I assume you have changed that so that the pdm pins in question does not conflict with this[/quote]
&lt;p&gt;&amp;nbsp; I have mentioned those Pins as Port 1. But I have not changed the pins to application core pins. Kindly tell me the procedure to do that. I will check.&lt;/p&gt;
[quote userid="2111" url="~/f/nordic-q-a/91422/nrf5340-with-pdm/384253"]What analysis have you done on the &amp;quot;clipping sound&amp;quot;? Does it repeat repeatedly at some interval? Is it constant on all audio etc? Is some of the audio good?[/quote]
&lt;p&gt;the clipping sounds are random and are not at some regular intervals.&amp;nbsp;in all audio, we get like like one to 3 clipping sound at a random interval.&lt;/p&gt;
&lt;p&gt;If We tried with the Audio application alone (means without adding any timer or interrupt). Then We can able to get clear audio.&lt;/p&gt;
&lt;p&gt;Thanks &amp;amp; Regards&lt;/p&gt;
&lt;p&gt;Navin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/384253?ContentTypeID=1</link><pubDate>Thu, 01 Sep 2022 07:10:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4548b7db-387c-4163-9f39-ddaaa078a071</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;The only thing I can think of that have some influence here is that port1 by default is setup to be used by the network core. But I assume you have changed that so that the pdm pins in question does not conflict with this. What analysis have you done on the &amp;quot;clipping sound&amp;quot;? Does it repeat repeatedly at some interval? Is it constant on all audio etc? Is some of the audio good?&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/384228?ContentTypeID=1</link><pubDate>Thu, 01 Sep 2022 00:18:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:13e71836-7371-4642-b0f7-bcbfdb76113c</guid><dc:creator>Mr.NCK</dc:creator><description>&lt;p&gt;Hi kenneth,&lt;/p&gt;
&lt;p&gt;Are you There. We are waiting for your reply.&lt;/p&gt;
&lt;p&gt;Thanks &amp;amp; Regards&lt;/p&gt;
&lt;p&gt;Navin&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/383774?ContentTypeID=1</link><pubDate>Tue, 30 Aug 2022 05:18:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3e9dc6a2-ac65-4769-8397-37a3a8ee2f7c</guid><dc:creator>Mr.NCK</dc:creator><description>&lt;p&gt;Hi Kenneth,&lt;/p&gt;
&lt;p&gt;1) I have attached my soc image for your reference.&lt;/p&gt;
&lt;p&gt;&lt;img style="max-height:240px;max-width:320px;" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1661836654211v1.jpeg" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;2) My DK version is 2.0.0&lt;/p&gt;
&lt;p&gt;3) also, my nrf connect SDK version is 1.9.1&lt;/p&gt;
&lt;p&gt;Thanks &amp;amp; Regards&lt;/p&gt;
&lt;p&gt;Navin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/383691?ContentTypeID=1</link><pubDate>Mon, 29 Aug 2022 12:37:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5c8913b5-1c9b-40a5-ab6c-251b556c61cd</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;What is the markings on the nRF5340 IC you are using? I just want to ensure you are not using some early engineering sampels.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Are you using the nRF5340DK for this test? If yes, what is the version of the DK?&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/383681?ContentTypeID=1</link><pubDate>Mon, 29 Aug 2022 12:27:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:98703b2e-9b83-4b74-84df-7a1f0a3e273f</guid><dc:creator>Mr.NCK</dc:creator><description>&lt;p&gt;Hi kenneth,&lt;/p&gt;
&lt;p&gt;Audio will affect with all pins on p1 and only one thread is assigned because of timer. So, that has higher priority&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Thanks &amp;amp; regards&lt;/p&gt;
&lt;p&gt;Navin&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/383680?ContentTypeID=1</link><pubDate>Mon, 29 Aug 2022 12:25:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:22070326-9a2b-4d4f-b116-c628c5d7d830</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;I suggest to continue debugging and try &amp;quot;things&amp;quot;, e.g. does it affect all pins on P1 or only some? Have you tried to change priority of threads and timers and pdm?&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/383649?ContentTypeID=1</link><pubDate>Mon, 29 Aug 2022 11:19:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f63f57fe-b19d-469f-83ab-2bfc9709f6a7</guid><dc:creator>Mr.NCK</dc:creator><description>&lt;p&gt;Hi Kenneth,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Thanks for your response.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;1) I am sure there are no other changes performed.&lt;/p&gt;
&lt;p&gt;2) PDM&amp;nbsp; and timer will run parallelly.Because based on the timer action we need to read one interrupt.&lt;/p&gt;
&lt;p&gt;Thanks &amp;amp; Regards&lt;/p&gt;
&lt;p&gt;Navin&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NRF5340 with PDM</title><link>https://devzone.nordicsemi.com/thread/383637?ContentTypeID=1</link><pubDate>Mon, 29 Aug 2022 10:36:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:14e42476-d68e-4120-ac2d-f9eb295e7ce6</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;1) There is no reason I can think of that should cause this. Are you sure the only change you did was the pin mapping and no other changes was performed?&lt;/p&gt;
&lt;p&gt;2) Maybe look at the PDM buffer and try to increase it? Sounds to me that the other thread/timer delay the PDM handling, so you may need to look into buffer size and priority of the PDM handling.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;br /&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>