2023-08-11 03:08 AM
Hello everyone!
This is my first post in the community, sorry for the grammatical error, my English isn't very good.
At this moment I am working with a Nucleo STM32L476 board and I want to configure the usart2 using CMSIS HAL, I have already configured the CR1, CR2, CR3, and the BRR registers of USART2 module, also I have configured the AH2BENR, CCIPR registers of RCC module and the GPIO PA2 and PA3 as alternative function (RX, TX) into the MODER and AFR[0] registers of GPIOA module, I am using the HSI with the PLL for a PCLOK=80MHz, and a BRR = 208D for 9600 bauds, but the data receiving by the serial port console integrated into the STM32CubeIDE aren't the same that I write in the TDR register, I have included the code of my project in the post, if someone could me explain where the error is, I would gratefully the help.
2023-08-11 03:09 AM