Commit 3c87b7ac authored by Thomas Stranger's avatar Thomas Stranger Committed by Kumar Gala
Browse files

tests: spi: add nucleo_g431rb to spi_loopback test in async mode



Add nucleo_g431rb to spi_loopback test using spi async configuration.
Such that tests do not only run with syncronous spi configuration
(nucleo_g474re), but also with the asyncronous configuration.

Signed-off-by: default avatarThomas Stranger <thomas.stranger@outlook.com>
parent a3967cef
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
CONFIG_SPI_LOOPBACK_DRV_NAME="SPI_1"

CONFIG_SPI_STM32_DMA=y
CONFIG_SPI_STM32_INTERRUPT=n

CONFIG_SPI_ASYNC=y

CONFIG_SPI_LOOPBACK_MODE_LOOP=n
+27 −0
Original line number Diff line number Diff line
/*
 * Copyright (c) 2021 Thomas Stranger
 *
 * SPDX-License-Identifier: Apache-2.0
 */

&spi1 {
	dmas = <&dmamux1 0 11 0x20440 0
		&dmamux1 1 10 0x20480 0>;
	dma-names = "tx", "rx";
};

&dma1 {
	status = "okay";
};

&dmamux1 {
	status = "okay";
};

&rcc {
	/*
	 * Reduce bus clock speed to be able to reach
	 * SPI_LOOPBACK_SLOW_FREQ = 500000 with max prescaler 256
	 */
	apb2-prescaler = <2>;
};