diff options
author | lonkaars <loek@pipeframe.xyz> | 2023-03-30 17:00:05 +0200 |
---|---|---|
committer | lonkaars <loek@pipeframe.xyz> | 2023-03-30 17:00:05 +0200 |
commit | fa296fbc6fe1c423932189116bd0cb949de0beef (patch) | |
tree | fc7de2beb8c06e1e244caf0ca201d03c690b657e /src/stm32 | |
parent | 6292c1101121bc8ba2db752cab3cbe41469b29d0 (diff) |
spi not working on hardware
Diffstat (limited to 'src/stm32')
-rw-r--r-- | src/stm32/setup.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/stm32/setup.c b/src/stm32/setup.c index b4112d3..b0abe7a 100644 --- a/src/stm32/setup.c +++ b/src/stm32/setup.c @@ -133,7 +133,6 @@ void hh_io_gpio_setup() { __HAL_RCC_GPIOA_CLK_ENABLE(); __HAL_RCC_GPIOB_CLK_ENABLE(); - HAL_GPIO_WritePin(GPIOA, GPIO_PIN_9, GPIO_PIN_SET); HAL_GPIO_Init(GPIOA, &(GPIO_InitTypeDef) { .Pin = GPIO_PIN_9, .Mode = GPIO_MODE_OUTPUT_PP, @@ -165,6 +164,7 @@ void HAL_SPI_MspDeInit(SPI_HandleTypeDef* hspi) { if(hspi->Instance != SPI1) return; __HAL_RCC_SPI1_CLK_DISABLE(); + __HAL_RCC_GPIOA_CLK_DISABLE(); HAL_GPIO_DeInit(HH_IO_SPI_PORT, HH_IO_SPI_PINS); } |