Skip to main content
sunny123
Associate
January 12, 2023
Question

Hi I am trying to bootload STM32F405RG using USART. The bootloader version is 3.1 I get the ACK back for erase memory and even when I send the address for the Write Memory. However I never get an ACK back when I start writing the data bytes. Please h

I am using 9600 baud rate and even parity .

Address bytes sent with checksum is 08 00 00 00 08 ACK Received

This topic has been closed for replies.

2 replies

ST Technical Moderator
January 18, 2023

Hello @sunny123​,

Could you please be more specific about NACK? Does it transmits a NACK byte or aborts the command?

Could you check if the address is valid? If yes, please provide us a dump/ log for better understanding of the issue.

You should refer to AN3155 section 3.6 Write Memory command for further details about the requirements to respect the order of the code sequence.

To give better visibility on the answered topics, please click on "Best answer" on the reply which solved your issue or answered your question.Best regards,FBL
Tesla DeLorean
Guru
January 18, 2023

Provide a more complete data-gram flow, your situation is hard to understand/interpret.

My recollection of a data packet.. For FLASH use aligned addresses and perhaps 8-16 byte patterns

{ // Tx: 31 Write
BYTE data[25] = { 0x31, 0xCE, 0x20, 0x00, 0x00, 0x00, 0x20, // WRITE 0x20000000, w/SUM
0x0F, // 16 Bytes
0x00, 0x11, 0x22, 0x33, 0x44, 0x55, 0x66, 0x77, // Data pattern
0x88, 0x99, 0xAA, 0xBB, 0xCC, 0xDD, 0xEE, 0xFF, 
0x0F }; // SUM

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..