Commit 7f45bbed authored by Lucien Zhao's avatar Lucien Zhao Committed by Daniel DeGrasse
Browse files

samples: drivers: i2s/i2s_codec: support case on rt700

put __16kHz16bit_stereo_sine_pcm buffer into nocache region
Do some settings for rt700 cm33_cpu0 core

Signed-off-by: default avatarLucien Zhao <lucien.zhao@nxp.com>
parent 63a7a930
Loading
Loading
Loading
Loading
+11 −0
Changes for samples/drivers/i2s/i2s_codec/boards/mimxrt700_evk_mimxrt798s_cm33_cpu0.conf: 11 added lines, 0 removed lines.
Original line number Diff line number Diff line
#
# Copyright 2025 NXP
#
# SPDX-License-Identifier: Apache-2.0
#

CONFIG_HEAP_MEM_POOL_SIZE=81920
CONFIG_AUDIO_CODEC=y
CONFIG_DMA_TCD_QUEUE_SIZE=4
CONFIG_SAMPLE_FREQ=16000
CONFIG_USE_DMIC=n
+9 −0
Changes for samples/drivers/i2s/i2s_codec/boards/mimxrt700_evk_mimxrt798s_cm33_cpu0.overlay: 9 added lines, 0 removed lines.
Original line number Diff line number Diff line
/*
 * Copyright 2025 NXP
 *
 * SPDX-License-Identifier: Apache-2.0
 */

&sai0 {
	mclk-output;
};
+1 −0
Changes for samples/drivers/i2s/i2s_codec/sample.yaml: 1 added line, 0 removed lines.
Original line number Diff line number Diff line
@@ -6,6 +6,7 @@ tests:
    platform_allow:
      - mimxrt595_evk/mimxrt595s/cm33
      - mimxrt1170_evk@B/mimxrt1176/cm7
      - mimxrt700_evk/mimxrt798s/cm33_cpu0
    harness: console
    harness_config:
      type: one_line
+9 −0
Changes for samples/drivers/i2s/i2s_codec/src/sine.h: 9 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -7,6 +7,15 @@
 #ifndef SINE_H_
 #define SINE_H_

#if CONFIG_NOCACHE_MEMORY
#define __NOCACHE	__attribute__((__section__(".nocache")))
#elif defined(CONFIG_DT_DEFINED_NOCACHE)
#define __NOCACHE	__attribute__((__section__(CONFIG_DT_DEFINED_NOCACHE_NAME)))
#else /* CONFIG_NOCACHE_MEMORY */
#define __NOCACHE
#endif /* CONFIG_NOCACHE_MEMORY */

unsigned char __16kHz16bit_stereo_sine_pcm[] __NOCACHE;
unsigned char __16kHz16bit_stereo_sine_pcm[] = {
	0x00, 0x00, 0x00, 0x00, 0x08, 0x0b, 0x08, 0x0b, 0xbb, 0x15, 0xbb, 0x15, 0xc9, 0x1f, 0xc9,
	0x1f, 0xe4, 0x28, 0xe4, 0x28, 0xc8, 0x30, 0xc8, 0x30, 0x38, 0x37, 0x38, 0x37, 0x03, 0x3c,
+2 −0
Changes for samples/drivers/i2s/output/boards/mimxrt700_evk_mimxrt798s_cm33_cpu0.conf: 2 added lines, 0 removed lines.
Original line number Diff line number Diff line
# Raise DMA TCD Queue size, as this is required by the I2S SAI driver
CONFIG_DMA_TCD_QUEUE_SIZE=4