Skip to content

Commit 93792b2

Browse files
authored
Update drv_spi.c
1 parent 3c32e01 commit 93792b2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

bsp/stm32/libraries/HAL_Drivers/drv_spi.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -293,9 +293,9 @@ static rt_uint32_t spixfer(struct rt_spi_device *device, struct rt_spi_message *
293293

294294
if (message->cs_take && !(device->config.mode & RT_SPI_NO_CS))
295295
{
296-
if(device->config.mode & RT_SPI_CS_HIGH)
296+
if (device->config.mode & RT_SPI_CS_HIGH)
297297
HAL_GPIO_WritePin(cs->GPIOx, cs->GPIO_Pin, GPIO_PIN_SET);
298-
else
298+
else
299299
HAL_GPIO_WritePin(cs->GPIOx, cs->GPIO_Pin, GPIO_PIN_RESET);
300300
}
301301

@@ -390,7 +390,7 @@ static rt_uint32_t spixfer(struct rt_spi_device *device, struct rt_spi_message *
390390

391391
if (message->cs_release && !(device->config.mode & RT_SPI_NO_CS))
392392
{
393-
if(device->config.mode & RT_SPI_CS_HIGH)
393+
if (device->config.mode & RT_SPI_CS_HIGH)
394394
HAL_GPIO_WritePin(cs->GPIOx, cs->GPIO_Pin, GPIO_PIN_RESET);
395395
else
396396
HAL_GPIO_WritePin(cs->GPIOx, cs->GPIO_Pin, GPIO_PIN_SET);

0 commit comments

Comments
 (0)