AnsweredAssumed Answered

STM32L053 bootloader unable to erase

Question asked by crocker.lee on Jun 3, 2016
Latest reply on Jun 7, 2016 by crocker.lee
I'm writing a USART boot-uploader for a project of ours, testing it on an STM32L053 discovery board. I can bring up the bootloader and talk to it just fine, send all the GET commands for info (It reports chip id 0x417, bootloader version 0x31, available commands include 0x44 extended erase).

But when I send the extended erase command (0x44, 0xBB), I get back a NAK (0x1F) right away, even before I get a chance tell it to do an erase all or page-by-page. I've seen in AN2606 the read-protect/unprotect trick, but when I try that it ACKs the first (0x82) command, but then does not respond at all to the second (0x92).

So how do I erase pages on this chip to prepare for writing? I've also seen mention of some chips being "locked", but I do not want to overwrite the bootloader itself, just upload a normal app to the normal flash location.

Is this possibly an eval-board thing getting in my way?

Outcomes