Skip to content

Commit 183f9be

Browse files
committed
[bsp][gd32450z-eval]fixed spi driver bug
1 parent df3d4b7 commit 183f9be

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bsp/gd32450z-eval/drivers/drv_spi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ static rt_err_t configure(struct rt_spi_device* device,
130130
}
131131
} /* baudrate */
132132

133-
switch(configuration->mode)
133+
switch(configuration->mode & RT_SPI_MODE_3)
134134
{
135135
case RT_SPI_MODE_0:
136136
spi_init_struct.clock_polarity_phase = SPI_CK_PL_LOW_PH_1EDGE;

0 commit comments

Comments
 (0)