Hi. I have been trying to flash an STM32L152RD (STM32L1xxxD) using the CUBE programmer through the USART2 and it never connects (Timeout error occured while waiting for acknowledgement). I have used the software method of branching into the bootloade
Because I do not have access to the BOOT0 pin (custom board, not eval board) I have used the software method of branching into the bootloader : https://stm32f4-discovery.net/2017/04/tutorial-jump-system-memory-software-stm32/
I have adpted this code for the device (notably bootloader address 0x1FF0 0000)
USART2 physical pins are PA2 and 3
My questions are:
- Is the bootloader code listening to USART2, is it listening to everything? Or does this require a specific configuration?
- Do I need to configure the USART2 with baudrate etc. before jumping to the bootlaoder so that it corresponds to the CUBE->UART settings or is this an automatic process?
____
logs from Cube
15:59:33:510 : Serial Port COM34 is successfully opened.
15:59:33:511 : Port configuration: parity = even, baudrate = 115200, data-bit = 8, stop-bit = 1.0, flow-control = off
15:59:33:511 : No Init bits value is : 0
15:59:33:511 : Sending init command:
15:59:33:511 : byte 0x7F sent successfully to target
15:59:34:511 : Wait ends after 1 loop, dataready = 0, delay = 1001
15:59:34:511 : Timeout error occured while waiting for acknowledgement.
15:59:34:512 : No response from target received
15:59:34:519 : byte 0x7F sent successfully to target
15:59:34:621 : Wait ends after 1 loop, dataready = 0, delay = 100
15:59:34:621 : Timeout error occured while waiting for acknowledgement.
15:59:34:621 : No response from target received
15:59:34:621 : Error: Activating device: KO. Please, verify the boot mode configuration and check the serial port configuration. Reset your device then try again...
Any help is appreciated, thank-you!
