2016-09-15 09:22 PM
Hello all,
I created a board for a STM32F411 that I program using the serial bootloader. It works great, except that since I am programming it over bluetooth, it is extremely slow (over 3 minutes to upload a 100k .bin file even at 115200 baud). I believe this is because of the latency of programming over bluetooth. I read in AN3155 that ''The maximum length of the block to be written for the STM32 is 256 bytes.'' There is handshaking in between each block written, and having to do this over bluetooth makes it very slow to program the chip. When I program the same program with a USB-to-serial converter at the same baud rate, it programs much faster. Increasing the baud rate doesn't really help the overall programming speed. It is all the time handshaking over the air every 256 bytes that is taking up all the time.So, I'm wondering if there is any way to modify the default serial bootloader to increate the maximum block size that can be written at once?Or, if I need to write my own bootloader, ideally it would seamlessly replace the existing one, except have a bigger maximum block size. Are there any sample bootloaders as I don't have any experience with writing one? Is the code for the included one available and how would I use it?Any/all help is appreciated. Thanks.2016-09-16 01:39 AM
The System Loader is in ROM/OTP so you aren't going to be able to change it, and source is unlikely to be provided. I would attack this by coding a secondary loader which was small and sent to SRAM and then transfer control to that for the programming of the FLASH, perhaps using Y-MODEM.
ST provides IAP code examples