From 25224f7b7ec9c871e378a9fdcb7037de47a971f4 Mon Sep 17 00:00:00 2001 From: matei jordache Date: Tue, 14 Nov 2023 21:06:31 -0500 Subject: [PATCH] add vmotor pin in gpio init --- firmware/lib/currentsense/opamp.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/firmware/lib/currentsense/opamp.cpp b/firmware/lib/currentsense/opamp.cpp index 0641c7d..2200170 100644 --- a/firmware/lib/currentsense/opamp.cpp +++ b/firmware/lib/currentsense/opamp.cpp @@ -42,11 +42,14 @@ void OPAMP_GPIO_Init(void) GPIO_InitTypeDef GPIO_InitStruct = {0}; __HAL_RCC_GPIOA_CLK_ENABLE(); - GPIO_InitStruct.Pin = GPIO_PIN_3; + GPIO_InitStruct.Pin = GPIO_PIN_2; GPIO_InitStruct.Mode = GPIO_MODE_ANALOG; GPIO_InitStruct.Pull = GPIO_NOPULL; HAL_GPIO_Init(GPIOA, &GPIO_InitStruct); + GPIO_InitStruct.Pin = GPIO_PIN_3; + HAL_GPIO_Init(GPIOA, &GPIO_InitStruct); + __HAL_RCC_GPIOB_CLK_ENABLE(); GPIO_InitStruct.Pin = GPIO_PIN_0; HAL_GPIO_Init(GPIOB, &GPIO_InitStruct);