diff --git a/src/main/drivers/system_stm32f7xx.c b/src/main/drivers/system_stm32f7xx.c index 53729877a8..3ff93d1a6c 100644 --- a/src/main/drivers/system_stm32f7xx.c +++ b/src/main/drivers/system_stm32f7xx.c @@ -135,24 +135,6 @@ void enableGPIOPowerUsageAndNoiseReductions(void) #ifndef STM32F722xx __HAL_RCC_SPI6_CLK_ENABLE(); #endif -// -// GPIO_InitTypeDef GPIO_InitStructure; -// GPIO_StructInit(&GPIO_InitStructure); -// GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_UP; // default is un-pulled input -// -// GPIO_InitStructure.GPIO_Pin = GPIO_Pin_All; -// GPIO_InitStructure.GPIO_Pin &= ~(GPIO_Pin_11 | GPIO_Pin_12); // leave USB D+/D- alone -// -// GPIO_InitStructure.GPIO_Pin &= ~(GPIO_Pin_13 | GPIO_Pin_14); // leave JTAG pins alone -// GPIO_Init(GPIOA, &GPIO_InitStructure); -// -// GPIO_InitStructure.GPIO_Pin = GPIO_Pin_All; -// GPIO_Init(GPIOB, &GPIO_InitStructure); -// -// GPIO_InitStructure.GPIO_Pin = GPIO_Pin_All; -// GPIO_Init(GPIOC, &GPIO_InitStructure); -// GPIO_Init(GPIOD, &GPIO_InitStructure); -// GPIO_Init(GPIOE, &GPIO_InitStructure); } bool isMPUSoftReset(void) diff --git a/src/main/drivers/system_stm32h7xx.c b/src/main/drivers/system_stm32h7xx.c index 38d12c793e..12c6a7f914 100644 --- a/src/main/drivers/system_stm32h7xx.c +++ b/src/main/drivers/system_stm32h7xx.c @@ -118,29 +118,6 @@ void enablePeripherialClocks(void) void enableGPIOPowerUsageAndNoiseReductions(void) { - // GPIO initialization, copied from drivers/system_stm32f7xx.c - // ... It was commented out. - // Where does F7 initializes the GPIO pins? It doesn't do it at all??? - -// -// GPIO_InitTypeDef GPIO_InitStructure; -// GPIO_StructInit(&GPIO_InitStructure); -// GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_UP; // default is un-pulled input -// -// GPIO_InitStructure.GPIO_Pin = GPIO_Pin_All; -// GPIO_InitStructure.GPIO_Pin &= ~(GPIO_Pin_11 | GPIO_Pin_12); // leave USB D+/D- alone -// -// GPIO_InitStructure.GPIO_Pin &= ~(GPIO_Pin_13 | GPIO_Pin_14); // leave JTAG pins alone -// GPIO_Init(GPIOA, &GPIO_InitStructure); -// -// GPIO_InitStructure.GPIO_Pin = GPIO_Pin_All; -// GPIO_Init(GPIOB, &GPIO_InitStructure); -// -// GPIO_InitStructure.GPIO_Pin = GPIO_Pin_All; -// GPIO_Init(GPIOC, &GPIO_InitStructure); -// GPIO_Init(GPIOD, &GPIO_InitStructure); -// GPIO_Init(GPIOE, &GPIO_InitStructure); - } void configureMasterClockOutputs(void) diff --git a/src/main/fc/init.c b/src/main/fc/init.c index cd4e50d7d5..0a8e6342d3 100644 --- a/src/main/fc/init.c +++ b/src/main/fc/init.c @@ -1006,6 +1006,8 @@ void init(void) motorEnable(); #endif + initializeUnusedPins(); + tasksInit(); systemState |= SYSTEM_STATE_READY;