cancel
Showing results for 
Search instead for 
Did you mean: 

Factory bootloader CRC command?

TheStumbler
Associate III

I noticed that in STM32FLASH programming utility, there is support for a CRC bootloader command. From what I can tell in the source code and commit history, this command is 0xA1 and was introduced around June of 2014. But from the ST documentation, I can't find any STM32 factory bootloader that enumerates a CRC command. If such a command exists, could someone point me to the app note?

5 REPLIES 5

The H7 Step-V ROM contains support for the 0xA1 command

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
TheStumbler
Associate III

Is this documented anywhere? I can find mention of the Rev V silicon in the H7 chips, but nothing about new bootloader commands. And was this available in 2014? The searches seem to indicated that Rev V is quite recent.​

The chip was from 2019Q1, but the one from 2018Q3 has it also (either Y or X). Both report v1.2

Cmd 00/FF GET

12 12 00 01 02 11 21 31 44 63 73 82 92 32 45 64 74 83 93 A1 79 

Not haven't seen it documented, but not something I'd looked for either.

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

Thanks for the help. Now I'm curious how the stm32flash team knew to implement the 0xA1 command back in 2014. I guess I'll make an account on their

repository ​(Sourceforge) and ask for the background information and any reference documentation. The reason I'm asking is that I'm writing a secondary bootloader having the same interface as the factory bootloader. One of the custom commands I'm adding is a memory hash function, and I realized it can have the same interface as the CRC command. I have it working now, based on my understanding of the CRC command obtained via the stm32flash source code. But it would be nice to have the official STM32 "extended" bootloader appnote to confirm, and to know details like is it available on all the interfaces, or just USART and I2C, for example.

Seems consistent with the source I looked at.

On H7 it wants the address in the 0x08000000..0x081FFFFF range (2MB Flash), length is a multiple of 4

Send A1 5E - CRC

Recv 79 (31 Protected)

Send Addr+Checksum

Recv 79 (31 Checksum, Scope)

Send Length+Checksum

Recv 79 (31 Checksum, Scope or Multiple)

..

Recv 79

Recv CRC+Checksum

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