Browse Source

[stm32][spi] remove hardware NSS

Meco Man 3 years ago
parent
commit
73236a825c
1 changed files with 1 additions and 8 deletions
  1. 1 8
      bsp/stm32/libraries/HAL_Drivers/drv_spi.c

+ 1 - 8
bsp/stm32/libraries/HAL_Drivers/drv_spi.c

@@ -138,14 +138,7 @@ static rt_err_t stm32_spi_init(struct stm32_spi *spi_drv, struct rt_spi_configur
         spi_handle->Init.CLKPolarity = SPI_POLARITY_LOW;
         spi_handle->Init.CLKPolarity = SPI_POLARITY_LOW;
     }
     }
 
 
-    if (cfg->mode & RT_SPI_NO_CS)
-    {
-        spi_handle->Init.NSS = SPI_NSS_HARD_OUTPUT;
-    }
-    else
-    {
-        spi_handle->Init.NSS = SPI_NSS_SOFT;
-    }
+    spi_handle->Init.NSS = SPI_NSS_SOFT;
 
 
     uint32_t SPI_APB_CLOCK;
     uint32_t SPI_APB_CLOCK;