<?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>Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/115112/cannot-build-i2s-echo-application-for-nrf5340</link><description>Hi, I am a beginner into the embedded audio space, and happened upon this board to use for our university project. Our team&amp;#39;s current plan would be to produce audio directly on the board and play it through the headphone jack, but have not found much</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 14 Oct 2024 06:22:43 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/115112/cannot-build-i2s-echo-application-for-nrf5340" /><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/506008?ContentTypeID=1</link><pubDate>Mon, 14 Oct 2024 06:22:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:46a6e9fc-3d90-43af-8825-9fce6f91e343</guid><dc:creator>Alexander Svensen</dc:creator><description>&lt;p&gt;CMSIS is Arm&amp;#39;s own system and not something we maintain or provide samples for. In Nordic we will generally be more focused on the connectivity part of a product, as this is our main business. Sorry I can&amp;#39;t provide any further help on this.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505994?ContentTypeID=1</link><pubDate>Sun, 13 Oct 2024 19:51:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:60ec5bc9-a42d-4784-825d-848f449b26f0</guid><dc:creator>TomHe</dc:creator><description>&lt;p&gt;Hi Johnny, here is the github repo I&amp;#39;ve just created:&amp;nbsp;&lt;a id="" href="https://github.com/Tom2096/nrfadk-audio_i2s_sine1k/tree/master"&gt;https://github.com/Tom2096/nrfadk-audio_i2s_sine1k&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Some plans I have for this moving forward:&lt;/p&gt;
&lt;p&gt;- Use zephyr ring buffer to supply data into&amp;nbsp;&lt;strong&gt;audio_i2s_set_next_buf&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;- Play around with setting channels=2 for cleaner code&lt;/p&gt;
&lt;p&gt;- Eventually write a true I2S echo application to echo microphone input&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;- Get rid of all the unnecessary&amp;nbsp;modules/drivers that are not used from the nrf5340_audio application&lt;/p&gt;
&lt;p&gt;Hope you find this repo useful!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505986?ContentTypeID=1</link><pubDate>Sun, 13 Oct 2024 06:29:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f98de29f-a27f-45fd-9679-24d5091ba481</guid><dc:creator>TomHe</dc:creator><description>&lt;p&gt;After some work I&amp;#39;ve finally been able to put together something. In the code attached I have used&amp;nbsp;&lt;strong&gt;audio_i2s_set_next_buf&lt;/strong&gt;&amp;nbsp;to continuously update the I2S buffer to play a 1000Hz sine wave. I hope this example can be of some help for folks looking for a &amp;quot;hello_world&amp;quot; example coming into NRF5340. Thanks again to&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/alexander-svensen"&gt;Alexander Svensen&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/ace.johnny"&gt;ace.johnny&lt;/a&gt;&amp;nbsp;, and&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/dejans"&gt;dejans&lt;/a&gt;&amp;nbsp;! I&amp;#39;ve also attached Johnny&amp;#39;s repo here:&amp;nbsp;&lt;a id="" href="https://github.com/ace-johnny/nrfadk-hello_codec"&gt;https://github.com/ace-johnny/nrfadk-hello_codec&lt;/a&gt;&amp;nbsp;for anyone that is interested!&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/i2s_5F00_1000hz.7z"&gt;devzone.nordicsemi.com/.../i2s_5F00_1000hz.7z&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505872?ContentTypeID=1</link><pubDate>Fri, 11 Oct 2024 11:28:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8a763c88-3c6f-46f5-9b3d-15083b0ce9e8</guid><dc:creator>Alexander Svensen</dc:creator><description>&lt;p&gt;Here I am sorry that I have to disappoint you &lt;a href="https://devzone.nordicsemi.com/members/ace.johnny"&gt;ace.johnny&lt;/a&gt;&amp;nbsp;, we do not have any design that uses the DSP features of the Cirrus chip as this is more Cirrus&amp;#39; domain. The DSP features like noise cancellation, beam forming and all the bells and whistles are highly dependent on the layout of the final design and is usually something the end-costumer deals with directly with Cirrus. You could try to reach out to Cirrus directly, but unfortunately I know that their support might be harder to get through than ours.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505861?ContentTypeID=1</link><pubDate>Fri, 11 Oct 2024 10:16:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3da5331b-0985-4374-948c-0af62aac531d</guid><dc:creator>Alexander Svensen</dc:creator><description>&lt;p&gt;For I2S there is one buffer that will supply both left and right interleaved. So it sounds like you are supplying it with only the left one and then the underlying I2S-driver will divide that into two channels, meaning you get half the audio to each channel, hence double the frequency. You can double check this by looking at the I2S with a logic analyzer. An easy way around this is to use the&amp;nbsp;&lt;a href="https://github.com/nrfconnect/sdk-nrf/blob/f28fe38a709e6e863b4ac173712249124f5201b2/include/pcm_stream_channel_modifier.h#L39"&gt;pcm_zero_pad&lt;/a&gt;&amp;nbsp;function we made for this.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505820?ContentTypeID=1</link><pubDate>Fri, 11 Oct 2024 07:43:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:28ffe3f2-a410-4def-9d92-f062288741d3</guid><dc:creator>TomHe</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/alexander-svensen"&gt;Alexander Svensen&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/ace.johnny"&gt;ace.johnny&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/dejans"&gt;dejans&lt;/a&gt;&amp;nbsp;Thanks for all the help so far! I have been poking around with using&amp;nbsp;&lt;strong&gt;audio_i2s_start()&lt;/strong&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;,&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span&gt;&lt;strong&gt;audio_i2s_blk_comp_cb_register()&lt;/strong&gt;, and&amp;nbsp;&lt;/span&gt;&lt;strong&gt;audio_i2s_stop()&lt;/strong&gt; for continuous I2S audio streaming, and I&amp;#39;ve arrived at the following sample:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;#include &amp;lt;zephyr/kernel.h&amp;gt;
#include &amp;lt;nrfx_clock.h&amp;gt;
#include &amp;lt;audio_i2s.h&amp;gt;
#include &amp;lt;macros_common.h&amp;gt;
#include &amp;lt;hw_codec.h&amp;gt;
#include &amp;lt;tone.h&amp;gt;

#include &amp;lt;zephyr/logging/log.h&amp;gt;
LOG_MODULE_REGISTER(main, CONFIG_MAIN_LOG_LEVEL);

#define CONFIG_LOGGING

#define BLK_PERIOD_US 1000

/* Number of audio blocks given a duration */
#define NUM_BLKS(d) ((d) / BLK_PERIOD_US)
/* Single audio block size in number of samples (stereo) */
/* clang-format off */
#define BLK_SIZE_SAMPLES(r) (((r)*BLK_PERIOD_US) / 1000000)

#define NUM_BLKS_IN_FRAME      NUM_BLKS(CONFIG_AUDIO_FRAME_DURATION_US)
#define BLK_MONO_NUM_SAMPS     BLK_SIZE_SAMPLES(CONFIG_AUDIO_SAMPLE_RATE_HZ)

#define BLK_MONO_SIZE_OCTETS   (BLK_MONO_NUM_SAMPS * CONFIG_AUDIO_BIT_DEPTH_OCTETS)

static uint8_t *tx_buf;
static uint32_t *rx_buf;

/* Alternate-buffers used when there is no active audio stream.
 * Used interchangeably by I2S.
 */
static struct {
	uint8_t __aligned(WB_UP(1)) buf_0[BLK_MONO_SIZE_OCTETS];
	uint8_t __aligned(WB_UP(1)) buf_1[BLK_MONO_SIZE_OCTETS];
	bool buf_0_in_use;
	bool buf_1_in_use;
} alt;

/**
 * @brief	Get first available alternative-buffer.
 *
 * @param	p_buffer	Double pointer to populate with buffer.
 *
 * @retval	0 if success.
 * @retval	-ENOMEM No available buffers.
 */
static int alt_buffer_get(void **p_buffer)
{
	if (!alt.buf_0_in_use) {
		alt.buf_0_in_use = true;
		*p_buffer = alt.buf_0;
	} else if (!alt.buf_1_in_use) {
		alt.buf_1_in_use = true;
		*p_buffer = alt.buf_1;
	} else {
		return -ENOMEM;
	}

	return 0;
}

/**
 * @brief	Frees both alternative buffers.
 */
static void alt_buffer_free_both(void)
{
	alt.buf_0_in_use = false;
	alt.buf_1_in_use = false;
}

static void i2s_block_complete_callback()
{
	/*** Data exchange ***/
	audio_i2s_set_next_buf(tx_buf, rx_buf);
}

int main(void) 
{
    int ret;

#ifdef CONFIG_LOGGING
    printk(&amp;quot;\nLogging I2S Info ...\n&amp;quot;);
    printk(&amp;quot;\nCONFIG_I2S_LRCK_FREQ_HZ:     %d\n&amp;quot;, CONFIG_I2S_LRCK_FREQ_HZ);
    printk(&amp;quot;\nCONFIG_I2S_CH_NUM:           %d\n&amp;quot;, CONFIG_I2S_CH_NUM);
    printk(&amp;quot;\nCONFIG_AUDIO_BIT_DEPTH_BITS: %d\n&amp;quot;, CONFIG_AUDIO_BIT_DEPTH_BITS);
#endif

	/* Use this to turn on 128 MHz clock for cpu_app */
	ret = nrfx_clock_divider_set(NRF_CLOCK_DOMAIN_HFCLK, NRF_CLOCK_HFCLK_DIV_1);
	ret -= NRFX_ERROR_BASE_NUM;
	if (ret) {
		return ret;
	}

	audio_i2s_blk_comp_cb_register(i2s_block_complete_callback);
	audio_i2s_init();

	ret = hw_codec_init();
	if (ret) {
		LOG_ERR(&amp;quot;Failed to initialize HW codec: %d&amp;quot;, ret);
		return ret;
	}
	hw_codec_volume_set(100);

	printk(&amp;quot;\nStarting I2S!\n&amp;quot;);

	/* Starting I2S */

	/********** I2S TX **********/
	ret = alt_buffer_get((void **)&amp;amp;tx_buf);
	ERR_CHK(ret);

	/********** I2S RX **********/
	ret = alt_buffer_get((void **)&amp;amp;rx_buf);
	ERR_CHK(ret);

	size_t tone_size;
	ret = tone_gen((uint16_t *)tx_buf, &amp;amp;tone_size, 1000, CONFIG_I2S_LRCK_FREQ_HZ, 1.0);
	if (ret || tone_size != BLK_MONO_SIZE_OCTETS) {
		LOG_ERR(&amp;quot;Failed to generate test tone&amp;quot;);
		return ret;
	}

	ret = hw_codec_default_conf_enable();
	ERR_CHK(ret);
	audio_i2s_start(tx_buf, rx_buf);
	
	k_msleep(5000);

	ret = hw_codec_soft_reset();
	ERR_CHK(ret);
	audio_i2s_stop();
	
	alt_buffer_free_both();

	printk(&amp;quot;\nI2S Stopped!\n&amp;quot;);

    return 0;
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;It basically re-uses the&amp;nbsp;&lt;strong&gt;alt_buffer_get()&lt;/strong&gt; function to first fetch empty buffers each of size&amp;nbsp;&lt;strong&gt;BLK_MONO_SIZE_OCTETS&lt;/strong&gt; since I do not want two channels. It then fills the&amp;nbsp;&lt;strong&gt;tx_buf&lt;/strong&gt; with a single period of sine wave via&amp;nbsp;&lt;strong&gt;tone_gen&lt;/strong&gt;.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I know that:&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&amp;nbsp; BLK_MONO_SIZE_OCTETS&amp;nbsp;= 32&lt;/strong&gt;&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;span&gt;&amp;nbsp; &lt;strong&gt;n&lt;/strong&gt;&lt;/span&gt;&lt;strong&gt;CONFIG_I2S_LRCK_FREQ_HZ = 16000&lt;/strong&gt;&lt;/div&gt;
&lt;div&gt;&lt;strong&gt;&lt;strong&gt;&amp;nbsp;&lt;/strong&gt;&lt;/strong&gt;
&lt;div&gt;
&lt;div&gt;&lt;span&gt;&amp;nbsp;&lt;strong&gt; n&lt;/strong&gt;&lt;/span&gt;&lt;strong&gt;CONFIG_I2S_CH_NUM = 1&lt;/strong&gt;&lt;/div&gt;
&lt;div&gt;&lt;br /&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;&lt;strong&gt;&amp;nbsp; nCONFIG_AUDIO_BIT_DEPTH_BITS = 16&lt;/strong&gt;&lt;/div&gt;
&lt;div&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div&gt;This means that a single &lt;strong&gt;tx_buf&lt;/strong&gt; (which is of size 32bytes -&amp;gt; 16 samples), when filled with a single sine period, should play to 1000Hz. &lt;strong&gt;However&lt;/strong&gt;&lt;strong&gt;, I am hearing 2000Hz when measuring with my device.&lt;/strong&gt; I&amp;#39;m not sure if I&amp;#39;ve missed anything or did some steps wrong. I have attached the full project as a zip file if interested (there is a .git file inside so you can track all the changes I&amp;#39;ve made starting from the nrf5340_audio application). I would really appreciate some pointers and thanks again for your help!&lt;/div&gt;
&lt;div&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/i2s_5F00_sample_2D00_copy.7z"&gt;devzone.nordicsemi.com/.../i2s_5F00_sample_2D00_copy.7z&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505737?ContentTypeID=1</link><pubDate>Thu, 10 Oct 2024 12:55:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:170ec6a4-f9fc-4b39-9d55-1eba36646b03</guid><dc:creator>Alexander Svensen</dc:creator><description>&lt;p&gt;No problem, glad I could help &lt;span class="emoticon" data-url="https://devzone.nordicsemi.com/cfs-file/__key/system/emoji/1f642.svg" title="Slight smile"&gt;&amp;#x1f642;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505715?ContentTypeID=1</link><pubDate>Thu, 10 Oct 2024 11:26:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c7a0b78b-feed-427f-9b2b-77b18f0f26a9</guid><dc:creator>Alexander Svensen</dc:creator><description>&lt;p&gt;The&amp;nbsp;main reason is as you already mentioned that we can reach all our desired LRCLK with the ratio settings available. If you look at table 3-13 in the CS47L63 data sheet it also states that if you use MCLK as a source for SYSCLK it has to be either 6.144 MHz or 12.288 MHz. Given the selection of ratios we have available we went with 6.144 MHz to be able to support 16 kHz.&lt;/p&gt;
&lt;p&gt;As mentioned we are adjusting the audio PLL ever so slightly up and down to be able to achieve synchronization between the left and the right audio receiver, this is based on the needs of LE Audio.&lt;br /&gt;&lt;br /&gt;As for the 0x66666000, that is the result based on the calculation you showed above. If you don&amp;#39;t do the flooring operation it will be&amp;nbsp;&lt;span&gt;0x66666666, but with the flooring it will be 0x66666000.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505306?ContentTypeID=1</link><pubDate>Tue, 08 Oct 2024 10:31:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:43c438fd-c70e-40b7-bf10-93e29a38c17d</guid><dc:creator>Alexander Svensen</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/ace.johnny"&gt;ace.johnny&lt;/a&gt;&amp;nbsp; and&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/tomhe"&gt;TomHe&lt;/a&gt;&amp;nbsp;, I&amp;#39;m one of the developers of the audio application and I&amp;#39;m sorry to see that this is causing issues for you. This is a very big application that encompasses a lot of moving parts and some of these were written a long time ago.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;To get a working I2S sample I would recommend taking our audio_i2s.c and header file together with the callback function here:&amp;nbsp;&lt;a href="https://github.com/nrfconnect/sdk-nrf/blob/18d7fd830f9293d5ce95ae70a70313b177257d03/applications/nrf5340_audio/src/audio/audio_datapath.c#L615"&gt;i2s_block_complete_cb&lt;/a&gt;&amp;nbsp;At the top of the I2S file you can see the ratios we use to get the different sample rates.&amp;nbsp;The actual MCK frequency when using our driver is 6.144MHz, so that is why the ratio is half of what you would have used if the MCK was 12.288MHz.&lt;/p&gt;
&lt;p&gt;Looking at you code Johnny I spotted a bug in our code where we have mixed up&amp;nbsp;39845.888 (0x9BA6) with 39854 (0x9BAE) causing us to set the wrong value for the HFClock so thank you for that and sorry if that caused any confusion. It shouldn&amp;#39;t cause much of an issue as this results in the LRClock running&amp;nbsp; 1 Hz faster than expected to begin with but that would be corrected by drift compensation later on. I have opened a PR for fixing it though.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/nrfconnect/sdk-nrf/blob/18d7fd830f9293d5ce95ae70a70313b177257d03/applications/nrf5340_audio/src/audio/audio_datapath.c#L615"&gt;I&lt;/a&gt;n this function you can remove everything except the&amp;nbsp;`audio_i2s_set_next_buf(tx_buf, rx_buf);` this is where the buffers for the next frame is set. How you provide those buffers are up to you and depends on where you are sourcing your data from. To get something up and running quickly you could use the `alt_buffer_get()` function to provide empty buffers to start with.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;To explain quickly how the I2S driver works:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;It can be initialized at boot up using the `audio_i2s_init()` function&lt;/li&gt;
&lt;li&gt;Once ready to start sending audio, call `audio_i2s_start()` providing the first tx-buffer to transmit and a rx-buffer to contain data fetched, these two are the same size.&lt;/li&gt;
&lt;li&gt;Once the data has been sent to the I2S-module it will call the callback, that can be registered using `audio_i2s_blk_comp_cb_register()`, to ask for a new tx and rx-buffer and this goes in a loop until `audio_i2s_stop()` is called. The interval of how often the callback is called depends on the size of the buffers provided.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Hope this helped a bit.&lt;/p&gt;
&lt;p&gt;EDIT: This response is written just with the I2S in mind, not changing any settings on the CS47L63. THat can be done by adding a line in the spi-writing, setting&amp;nbsp;CS47L63_SAMPLE_RATE1 to 0x12&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505159?ContentTypeID=1</link><pubDate>Mon, 07 Oct 2024 11:11:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a12ed79d-1db6-4060-a87d-c5a8a0447743</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;&lt;a href="https://devzone.nordicsemi.com/members/ace.johnny"&gt;ace.johnny&lt;/a&gt;&amp;nbsp;Thank you for providing the sample.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;&lt;a href="https://devzone.nordicsemi.com/members/tomhe"&gt;TomHe&lt;/a&gt;&amp;nbsp;,&amp;nbsp;you could try to set your desired frequency using&amp;nbsp;CONFIG_AUDIO_SAMPLE_RATE_16000_HZ=y and putting this KConfig option directly in your project configuration file.&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505060?ContentTypeID=1</link><pubDate>Sat, 05 Oct 2024 08:15:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:99eeecf0-79a5-4887-973a-d729ff33dd29</guid><dc:creator>TomHe</dc:creator><description>&lt;p&gt;Hi Johnny,&lt;/p&gt;
&lt;p&gt;I can&amp;#39;t thank you enough for all the effort you put into this. This is the first time we&amp;#39;ve had success with the nRF5340 - no build errors and we can actually hear the output! With that said, we have a small question regarding adjusting the sampling rate. I noticed that in your code the calculation is stated as follows:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;/**
 * @brief	Initialize the CS47L63, start clocks, and configure subsystems.
 * 
 * @details	MCLK1 =  12,288,000 Hz  (I2S_CLKSRC.ACLK)
 * 		LRCLK =      48,000 Hz  (MCLK1 / I2S_CONFIG.RATIO)
 * 		BCLK =    1,536,000 Hz  (LRCLK * I2S_CONFIG.SWIDTH * 2)
 * 		FLL1 =   49,152,000 Hz  (MCLK1 * 4)
 * 		SYSCLK = 98,304,000 Hz  (FLL1 * 2)
 * 
 * @retval	`CS47L63_STATUS_OK`     The operation was successful.
 * @retval	`CS47L63_STATUS_FAIL`   Configuring the CS47L63 failed.
 * 
 * @warning	I2S MCLK1 must already be running before calling this function.
 * 
 */&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Where LRCKL (I presume is the sampling rate) is the master clock rate divided by the left-right clock ratio. For our application we require the sampling to be 16kHz - this means we need the left-right clock ratio to be&amp;nbsp;&lt;strong&gt;I2S_CONFIG_RATIO_RATIO_768X&amp;nbsp;&lt;/strong&gt;without touching the master clock rate. However, upon looking at the macros files the ratio only goes up to &lt;strong&gt;512X:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;/* Register: I2S_CONFIG_RATIO */
/* Description: MCK / LRCK ratio */

/* Bits 3..0 : MCK / LRCK ratio */
#define I2S_CONFIG_RATIO_RATIO_Pos (0UL) /*!&amp;lt; Position of RATIO field. */
#define I2S_CONFIG_RATIO_RATIO_Msk (0xFUL &amp;lt;&amp;lt; I2S_CONFIG_RATIO_RATIO_Pos) /*!&amp;lt; Bit mask of RATIO field. */
#define I2S_CONFIG_RATIO_RATIO_32X (0UL) /*!&amp;lt; LRCK = MCK / 32 */
#define I2S_CONFIG_RATIO_RATIO_48X (1UL) /*!&amp;lt; LRCK = MCK / 48 */
#define I2S_CONFIG_RATIO_RATIO_64X (2UL) /*!&amp;lt; LRCK = MCK / 64 */
#define I2S_CONFIG_RATIO_RATIO_96X (3UL) /*!&amp;lt; LRCK = MCK / 96 */
#define I2S_CONFIG_RATIO_RATIO_128X (4UL) /*!&amp;lt; LRCK = MCK / 128 */
#define I2S_CONFIG_RATIO_RATIO_192X (5UL) /*!&amp;lt; LRCK = MCK / 192 */
#define I2S_CONFIG_RATIO_RATIO_256X (6UL) /*!&amp;lt; LRCK = MCK / 256 */
#define I2S_CONFIG_RATIO_RATIO_384X (7UL) /*!&amp;lt; LRCK = MCK / 384 */
#define I2S_CONFIG_RATIO_RATIO_512X (8UL) /*!&amp;lt; LRCK = MCK / 512 */&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Is there a work around for this? Again,&amp;nbsp;your help has been absolutely invaluable, and I truly hope others will come across this sample when they are learning to work with the nRF5340. Tremendous thanks again!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/505045?ContentTypeID=1</link><pubDate>Fri, 04 Oct 2024 17:11:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:726b44cf-7997-4d17-a6a9-3c417cef2ba1</guid><dc:creator>TomHe</dc:creator><description>&lt;p&gt;Hi, when I press the buttons I can see on&amp;nbsp;the serial console stream/echo is toggled on/off, but I cannot hear anything&amp;nbsp;over my headphones.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/504939?ContentTypeID=1</link><pubDate>Fri, 04 Oct 2024 07:51:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:50e214ae-0995-45d2-8037-92125997345d</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;After successful flashing, you should be able to use Button 1 and Button 2 on the board as described in the&amp;nbsp;&lt;a href="https://docs.nordicsemi.com/bundle/ncs-2.5.3/page/zephyr/samples/drivers/i2s/echo/README.html"&gt;I2S_echo sample&lt;/a&gt;&amp;nbsp;documentation - &amp;quot;&lt;span&gt;Press Button 1 to toggle the echo effect and Button 2 to stop the streams.&lt;/span&gt;&amp;quot; What happens when you press Button 1 and Button 2?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/504921?ContentTypeID=1</link><pubDate>Fri, 04 Oct 2024 06:01:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e7b1270c-59d4-4b3c-b876-b245e262c630</guid><dc:creator>TomHe</dc:creator><description>&lt;p&gt;Hi I removed the wm8731 section from my overlay file. It now looks like this:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;/*
 * Copyright (c) 2021 Nordic Semiconductor ASA
 *
 * SPDX-License-Identifier: Apache-2.0
 */

&amp;amp;pinctrl {
	i2c0_default_alt: i2c0_default_alt {
		group1 {
			psels = &amp;lt;NRF_PSEL(TWIM_SDA, 0, 25)&amp;gt;,
				&amp;lt;NRF_PSEL(TWIM_SCL, 0, 26)&amp;gt;;
		};
	};

	i2c0_sleep_alt: i2c0_sleep_alt {
		group1 {
			psels = &amp;lt;NRF_PSEL(TWIM_SDA, 0, 25)&amp;gt;,
				&amp;lt;NRF_PSEL(TWIM_SCL, 0, 26)&amp;gt;;
			low-power-enable;
		};
	};

	i2s0_default_alt: i2s0_default_alt {
		group1 {
			psels = &amp;lt;NRF_PSEL(I2S_SCK_M, 1, 15)&amp;gt;,
				&amp;lt;NRF_PSEL(I2S_LRCK_M, 1, 12)&amp;gt;,
				&amp;lt;NRF_PSEL(I2S_SDOUT, 1, 13)&amp;gt;,
				&amp;lt;NRF_PSEL(I2S_SDIN, 1, 14)&amp;gt;;
		};
	};
};

&amp;amp;i2c1 {
	status = &amp;quot;okay&amp;quot;;
	pinctrl-0 = &amp;lt;&amp;amp;i2c0_default_alt&amp;gt;;
	pinctrl-1 = &amp;lt;&amp;amp;i2c0_sleep_alt&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;, &amp;quot;sleep&amp;quot;;
};

&amp;amp;clock {
	hfclkaudio-frequency = &amp;lt;11289600&amp;gt;;
};

i2s_rxtx: &amp;amp;i2s0 {
	status = &amp;quot;okay&amp;quot;;
	pinctrl-0 = &amp;lt;&amp;amp;i2s0_default_alt&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;, &amp;quot;sleep&amp;quot;;
	clock-source = &amp;quot;ACLK&amp;quot;;
};

&amp;amp;spi4 {
	compatible = &amp;quot;nordic,nrf-spim&amp;quot;;
	status = &amp;quot;okay&amp;quot;;
	cs-gpios = &amp;lt;&amp;amp;gpio0 11 GPIO_ACTIVE_LOW&amp;gt;, &amp;lt;&amp;amp;gpio0 17 GPIO_ACTIVE_LOW&amp;gt;;
	pinctrl-0 = &amp;lt;&amp;amp;spi4_default&amp;gt;;
	pinctrl-1 = &amp;lt;&amp;amp;spi4_sleep&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;, &amp;quot;sleep&amp;quot;;

	cs47l63: cs47l63@1 {
		compatible = &amp;quot;cirrus,cs47l63&amp;quot;;
		reg = &amp;lt;1&amp;gt;;
		spi-max-frequency = &amp;lt;8000000&amp;gt;;
		irq-gpios = &amp;lt;&amp;amp;gpio0 19 GPIO_ACTIVE_LOW&amp;gt;;
		reset-gpios = &amp;lt;&amp;amp;gpio0 18 GPIO_ACTIVE_LOW&amp;gt;;
		gpio9-gpios = &amp;lt;&amp;amp;gpio0 20 GPIO_ACTIVE_LOW&amp;gt;;
	};
};
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;I was able to build the board (seems like now it just skipped the&amp;nbsp;&lt;span&gt;&lt;strong&gt;init_wm8731_i2c&lt;/strong&gt; function&lt;/span&gt;). Since I do not have a microphone, I am filling in the bytes of the ring buffer manually like below:&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;int alt = 0;
while (k_sem_take(&amp;amp;toggle_transfer, K_NO_WAIT) != 0) {
	void *mem_block;
	uint32_t block_size;
	int ret;

	ret = i2s_read(i2s_dev_rx, &amp;amp;mem_block, &amp;amp;block_size);
	if (ret &amp;lt; 0) {
		printk(&amp;quot;Failed to read data: %d\n&amp;quot;, ret);
		break;
	}

	alt = 10 - alt;
	//process_block_data(mem_block, SAMPLES_PER_BLOCK);
	for (int i = 0; i &amp;lt; SAMPLES_PER_BLOCK; ++i) {
		int16_t *sample = &amp;amp;((int16_t *)mem_block)[i];
		*sample = alt;
	}

	ret = i2s_write(i2s_dev_tx, mem_block, block_size);
	if (ret &amp;lt; 0) {
		printk(&amp;quot;Failed to write data: %d\n&amp;quot;, ret);
		break;
	}
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;However, I am not hearing anything when I plug my headphones in. I suspect it has something to do with the hardware codec? Any support would be appreciated!&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/504813?ContentTypeID=1</link><pubDate>Thu, 03 Oct 2024 11:08:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ba018f4f-26dc-40dc-8b7e-fb13eb9fa0b3</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;You could try to remove wm8731 section from &amp;amp;i2c1 in your overlay file.&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/504777?ContentTypeID=1</link><pubDate>Thu, 03 Oct 2024 06:17:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ac92d976-e858-4e49-b578-39bb97cf4f29</guid><dc:creator>TomHe</dc:creator><description>&lt;p&gt;Hi Dejan, I&amp;#39;ve added it to my overlay file but am still facing the same issue. Please see below my full overlay file:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;/*
 * Copyright (c) 2021 Nordic Semiconductor ASA
 *
 * SPDX-License-Identifier: Apache-2.0
 */

&amp;amp;pinctrl {
	i2c0_default_alt: i2c0_default_alt {
		group1 {
			psels = &amp;lt;NRF_PSEL(TWIM_SDA, 0, 25)&amp;gt;,
				&amp;lt;NRF_PSEL(TWIM_SCL, 0, 26)&amp;gt;;
		};
	};

	i2c0_sleep_alt: i2c0_sleep_alt {
		group1 {
			psels = &amp;lt;NRF_PSEL(TWIM_SDA, 0, 25)&amp;gt;,
				&amp;lt;NRF_PSEL(TWIM_SCL, 0, 26)&amp;gt;;
			low-power-enable;
		};
	};

	i2s0_default_alt: i2s0_default_alt {
		group1 {
			psels = &amp;lt;NRF_PSEL(I2S_SCK_M, 1, 15)&amp;gt;,
				&amp;lt;NRF_PSEL(I2S_LRCK_M, 1, 12)&amp;gt;,
				&amp;lt;NRF_PSEL(I2S_SDOUT, 1, 13)&amp;gt;,
				&amp;lt;NRF_PSEL(I2S_SDIN, 1, 14)&amp;gt;;
		};
	};
};

&amp;amp;i2c1 {
	status = &amp;quot;okay&amp;quot;;
	pinctrl-0 = &amp;lt;&amp;amp;i2c0_default_alt&amp;gt;;
	pinctrl-1 = &amp;lt;&amp;amp;i2c0_sleep_alt&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;, &amp;quot;sleep&amp;quot;;

	wm8731: wm8731@1a {
		compatible = &amp;quot;wolfson,wm8731&amp;quot;;
		reg = &amp;lt;0x1a&amp;gt;;
	};
};

&amp;amp;clock {
	hfclkaudio-frequency = &amp;lt;11289600&amp;gt;;
};

i2s_rxtx: &amp;amp;i2s0 {
	status = &amp;quot;okay&amp;quot;;
	pinctrl-0 = &amp;lt;&amp;amp;i2s0_default_alt&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;, &amp;quot;sleep&amp;quot;;
	clock-source = &amp;quot;ACLK&amp;quot;;
};

&amp;amp;spi4 {
	compatible = &amp;quot;nordic,nrf-spim&amp;quot;;
	status = &amp;quot;okay&amp;quot;;
	cs-gpios = &amp;lt;&amp;amp;gpio0 11 GPIO_ACTIVE_LOW&amp;gt;, &amp;lt;&amp;amp;gpio0 17 GPIO_ACTIVE_LOW&amp;gt;;
	pinctrl-0 = &amp;lt;&amp;amp;spi4_default&amp;gt;;
	pinctrl-1 = &amp;lt;&amp;amp;spi4_sleep&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;, &amp;quot;sleep&amp;quot;;

	cs47l63: cs47l63@1 {
		compatible = &amp;quot;cirrus,cs47l63&amp;quot;;
		reg = &amp;lt;1&amp;gt;;
		spi-max-frequency = &amp;lt;8000000&amp;gt;;
		irq-gpios = &amp;lt;&amp;amp;gpio0 19 GPIO_ACTIVE_LOW&amp;gt;;
		reset-gpios = &amp;lt;&amp;amp;gpio0 18 GPIO_ACTIVE_LOW&amp;gt;;
		gpio9-gpios = &amp;lt;&amp;amp;gpio0 20 GPIO_ACTIVE_LOW&amp;gt;;
	};
};
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;All other files remain untouched. Any ideas on how to proceed? It&amp;#39;s still erroring out inside the&amp;nbsp;&lt;strong&gt;init_wm8731_i2c&lt;/strong&gt; function. Thanks!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/504699?ContentTypeID=1</link><pubDate>Wed, 02 Oct 2024 12:57:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3bbb5c53-08b5-4b75-93ec-ccf0eb980651</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;In the sample requirements, you can read this &amp;quot;&lt;span&gt;The sample uses the WM8731 audio CODEC that can be found, for example, on the Audio Codec Shield, but it can be easily adapted to use other CODECs.&lt;/span&gt;&amp;quot; but it is not the same codec that is used by the nrf5340_audio-dk board. You could try to add the lines below to your nrf5340_audio_dk_nrf5340_cpuapp.overlay file:&lt;br /&gt;&lt;pre class="ui-code" data-mode="text"&gt;&amp;amp;spi4 {
	compatible = &amp;quot;nordic,nrf-spim&amp;quot;;
	status = &amp;quot;okay&amp;quot;;
	cs-gpios = &amp;lt;&amp;amp;gpio0 11 GPIO_ACTIVE_LOW&amp;gt;, &amp;lt;&amp;amp;gpio0 17 GPIO_ACTIVE_LOW&amp;gt;;
	pinctrl-0 = &amp;lt;&amp;amp;spi4_default&amp;gt;;
	pinctrl-1 = &amp;lt;&amp;amp;spi4_sleep&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;, &amp;quot;sleep&amp;quot;;

	cs47l63: cs47l63@1 {
		compatible = &amp;quot;cirrus,cs47l63&amp;quot;;
		reg = &amp;lt;1&amp;gt;;
		spi-max-frequency = &amp;lt;8000000&amp;gt;;
		irq-gpios = &amp;lt;&amp;amp;gpio0 19 GPIO_ACTIVE_LOW&amp;gt;;
		reset-gpios = &amp;lt;&amp;amp;gpio0 18 GPIO_ACTIVE_LOW&amp;gt;;
		gpio9-gpios = &amp;lt;&amp;amp;gpio0 20 GPIO_ACTIVE_LOW&amp;gt;;
	};
};&lt;/pre&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/504614?ContentTypeID=1</link><pubDate>Wed, 02 Oct 2024 07:23:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:703bf107-3b82-4aeb-94d1-a5eed1ff9874</guid><dc:creator>TomHe</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Here is what I see over the serial console:&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;span&gt; Serial &lt;/span&gt;&lt;span&gt; Port opened &lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;*** Booting nRF Connect SDK 4040aa0bf581 *** &lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;I2S echo sample &lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;Initialization step 0 failed &lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;Tracing &amp;quot;Initialization step 0 failed&amp;quot; led to line 117 in codec.c, which leads me to believe that something went wrong with setting up the codec. Appreciate the help!&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/504491?ContentTypeID=1</link><pubDate>Tue, 01 Oct 2024 08:57:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6f1f32f6-bd72-43f5-b0e2-da00f66956d4</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;Can you provide application error log?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/504411?ContentTypeID=1</link><pubDate>Mon, 30 Sep 2024 16:34:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:61c73cad-7811-48b4-a8df-1c176cb0cf72</guid><dc:creator>TomHe</dc:creator><description>&lt;p&gt;Hi, thanks for the reply! This problem was fixed when I added a second name. However, now when I run the application, it gives an error when trying to build the codec. Is there a work around for this? On the wiki page it says the NRF5340 is supported by this sample.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Cannot build I2S echo application for NRF5340</title><link>https://devzone.nordicsemi.com/thread/504405?ContentTypeID=1</link><pubDate>Mon, 30 Sep 2024 15:46:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0fe34a78-58da-4f1c-9eb7-eea024f5729b</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;To successfully build Zephyr&amp;nbsp;&lt;a href="https://docs.nordicsemi.com/bundle/ncs-latest/page/zephyr/samples/drivers/i2s/echo/README.html"&gt;I2S echo&lt;/a&gt;&amp;nbsp;sample on the nrf5340_audio-dk board, you would need to make some modifications in your overlay file. You would need to have 2 pin control names and specify them in the pinctrl-names property for i2s in the overlay file. You can compare content of i2s0 in your overlay file with the i2s0 content nrf5340_audio_dk_nrf5340_cpuapp_common.dtsi file. Try to make the changes (shown below) in your overlay file and rebuild the application.&lt;br /&gt;&lt;pre class="ui-code" data-mode="text"&gt;i2s_rxtx: &amp;amp;i2s0 {
	status = &amp;quot;okay&amp;quot;;
	pinctrl-0 = &amp;lt;&amp;amp;i2s0_default_alt&amp;gt;;
	pinctrl-1 = &amp;lt;&amp;amp;i2s0_sleep&amp;gt;;
	pinctrl-names = &amp;quot;default&amp;quot;,&amp;quot;sleep&amp;quot;;
	clock-source = &amp;quot;ACLK&amp;quot;;
};&lt;/pre&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>