-
Notifications
You must be signed in to change notification settings - Fork 7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: i2s: Reconfigure i2s speed test HW environment on RT1170 EVK board
Use TX and RX blocks on SAI for i2s speed test, by this way we can avoid HW reworking. Update Readme file and DMA channel configuration in overlay file to avoid DMA channel conflict with other peripherals like UART. Signed-off-by: Raymond Lei <[email protected]>
- Loading branch information
1 parent
332115c
commit 7e8abff
Showing
6 changed files
with
66 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 7 additions & 18 deletions
25
tests/drivers/i2s/i2s_speed/boards/mimxrt1170_evk_mimxrt1176_cm7.overlay
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,15 @@ | ||
/* i2s_speed with CONFIG_I2S_TEST_SEPARATE_DEVICES=y uses two I2S peripherals: | ||
* i2s-node0 is the receiver - uses SAI1 peripheral on RT1170 | ||
* i2s-node1 is the transmitter - uses SAI4 peripheral | ||
/* i2s_speed with CONFIG_I2S_TEST_SEPARATE_DEVICES=n uses only one I2S peripheral: | ||
* i2s-node0 is both the transitter and receiver. | ||
* uses SAI1 peripheral on RT1170 | ||
*/ | ||
|
||
/ { | ||
aliases { | ||
i2s-node0 = &sai1; | ||
i2s-node1 = &sai4; | ||
}; | ||
}; | ||
|
||
/* Enable SAI4, and set clocks to match SAI1 */ | ||
&sai4 { | ||
status = "okay"; | ||
podf = < 0x4 >; | ||
pinctrl-0 = <&pinmux_sai4>; | ||
pinctrl-names = "default"; | ||
}; | ||
|
||
/* On MIMXRT1170-EVK, there is a conflict with signal SAI4_TX_BCLK shared with | ||
* ENET_RST. For i2s_speed test, disable ENET peripheral. | ||
*/ | ||
&enet { | ||
status = "disabled"; | ||
/* Default DMA channel 0 and 1 maybe used by other peripherals like UART. */ | ||
&sai1 { | ||
nxp,tx-dma-channel = <8>; | ||
nxp,rx-dma-channel = <9>; | ||
}; |
25 changes: 25 additions & 0 deletions
25
tests/drivers/i2s/i2s_speed/boards/mimxrt1170_evk_mimxrt1176_cm7_B.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# | ||
# Copyright (c) 2021, NXP | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
|
||
# SAI peripheral does not have loopback mode but we can connect CLK, SYNC, | ||
# RXD and TXD of one SAI for test purpose. | ||
CONFIG_I2S_TEST_SEPARATE_DEVICES=n | ||
|
||
# CONFIG_DMA_TCD_QUEUE_SIZE sets size of queue used to chain DMA blocks (TCDs) | ||
# together, and should be sized as needed by the application. If not large | ||
# enough, the DMA may starve. Symptoms of this issue include transmit blocks | ||
# repeated, or RX blocks skipped. For I2S driver, queue size must be at least 3. | ||
CONFIG_DMA_TCD_QUEUE_SIZE=4 | ||
|
||
# Repeat test continually to help find intermittent issues | ||
CONFIG_ZTEST_RETEST_IF_PASSED=y | ||
|
||
# I2S and DMA logging can occur in interrupt context, and interfere with I2S | ||
# stream timing. If using either logging, set logging to deferred | ||
# CONFIG_LOG_MODE_DEFERRED=y | ||
|
||
CONFIG_DMA_LOG_LEVEL_OFF=y | ||
CONFIG_I2S_LOG_LEVEL_OFF=y |
15 changes: 15 additions & 0 deletions
15
tests/drivers/i2s/i2s_speed/boards/mimxrt1170_evk_mimxrt1176_cm7_B.overlay
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* i2s_speed with CONFIG_I2S_TEST_SEPARATE_DEVICES=n uses only one I2S peripheral: | ||
* i2s-node0 is both the transitter and receiver. | ||
* uses SAI1 peripheral on RT1170 | ||
*/ | ||
/ { | ||
aliases { | ||
i2s-node0 = &sai1; | ||
}; | ||
}; | ||
|
||
/* Default DMA channel 0 and 1 maybe used by other peripherals like UART. */ | ||
&sai1 { | ||
nxp,tx-dma-channel = <8>; | ||
nxp,rx-dma-channel = <9>; | ||
}; |