STM32F1 - LL_GPIO_Init() problem
Hi,
A piece of code from STM32CubeMX v4.0 and latest F1 drivers generated for STM32VLDiscovery (the button is pulled-down by external resistor):
static void MX_GPIO_Init(void)
{LL_GPIO_InitTypeDef GPIO_InitStruct;
/* GPIO Ports Clock Enable */
LL_APB2_GRP1_EnableClock(LL_APB2_GRP1_PERIPH_GPIOC); LL_APB2_GRP1_EnableClock(LL_APB2_GRP1_PERIPH_GPIOD); LL_APB2_GRP1_EnableClock(LL_APB2_GRP1_PERIPH_GPIOA);GPIO_InitStruct.Pin = LL_GPIO_PIN_0;
GPIO_InitStruct.Mode = LL_GPIO_MODE_FLOATING; LL_GPIO_Init(GPIOA, &GPIO_InitStruct);}
and the results from the Keil debugger:
So commented the line below to prove that there is only one line of code used for GPIOA initialization:
// LL_GPIO_Init(GPIOA, &GPIO_InitStruct);
and got as expected (the default settings for GPIOA)
It seems that the LL_GPIO_Init gives messy config on more than one pin. Am I wrong?
Have no luck with F1 line and LL drivers - this issue seems to be continuation of my previous finding:
--------------------------------
So switching back to register programming when working with boards with low SRAM size. It takes less time than investigating issues in LL drivers.
I wonder if you use LL drivers for F1 line. I know that more people prefer SPL drivers for this line.
Note: this post was migrated and contained many threaded conversations, some content may be missing.