tests: drivers: spi loopback test running on the stm32l152re nucleo
add configuration for testing the spi through the dma1 on the nucleo_l152re target. This test requires the MOSI pin to be connected to the MISO pin on the board. Signed-off-by: Francois Ramu <francois.ramu@st.com>
This commit is contained in:
parent
744e1dc692
commit
d36cdd5a27
2 changed files with 26 additions and 0 deletions
8
tests/drivers/spi/spi_loopback/boards/nucleo_l152re.conf
Normal file
8
tests/drivers/spi/spi_loopback/boards/nucleo_l152re.conf
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
CONFIG_SPI_LOOPBACK_DRV_NAME="SPI_1"
|
||||||
|
|
||||||
|
CONFIG_SPI_STM32_DMA=y
|
||||||
|
CONFIG_SPI_STM32_INTERRUPT=n
|
||||||
|
|
||||||
|
CONFIG_SPI_ASYNC=n
|
||||||
|
|
||||||
|
CONFIG_SPI_LOOPBACK_MODE_LOOP=n
|
18
tests/drivers/spi/spi_loopback/boards/nucleo_l152re.overlay
Normal file
18
tests/drivers/spi/spi_loopback/boards/nucleo_l152re.overlay
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2021 STMicroelectronics
|
||||||
|
*
|
||||||
|
* SPDX-License-Identifier: Apache-2.0
|
||||||
|
*/
|
||||||
|
|
||||||
|
&spi1 {
|
||||||
|
pinctrl-0 = <&spi1_nss_pa4 &spi1_sck_pa5
|
||||||
|
&spi1_miso_pa6 &spi1_mosi_pa7>;
|
||||||
|
dmas = <&dma1 3 0x20440
|
||||||
|
&dma1 2 0x20480>;
|
||||||
|
dma-names = "tx", "rx";
|
||||||
|
status = "okay";
|
||||||
|
};
|
||||||
|
|
||||||
|
&dma1 {
|
||||||
|
status = "okay";
|
||||||
|
};
|
Loading…
Add table
Add a link
Reference in a new issue