cancel
Showing results for 
Search instead for 
Did you mean: 

Flash Loader Demonstrator no longer responds to reply from STM32L151C

Krenek.Steve
Associate III
Posted on August 09, 2017 at 04:15

I have been using the bootloader in the STM32L151C with STMFlashLoaderDemo for some years to update firmware.

Now, with nothing changed, the Flash Loader no longer connects to the chip

I have spied on the serial connection between the PC (hardware serial port) and the device, and the exchange for the first two commands is normal:

>7F   (Flashloader sent)

79    (chip response)

>00 FF

79 0B 30 00 01 02 11 21 31 44 63 73 82 92 79

This response is byte for byte identical to that shown as the expected response in AN3155 page 9.

After receiving the last response, the Flash loader times out with the message'Cannot get available commands, Please try to change Echo selection etc'

I have also simulated the chip responses using a terminal program that can send strings of hex characters. Same result.

The second byte of the response, 0x0B is decimal 11, and is the correct value for the number of succeeding characters -1, not counting the final 0x79 ACK.

HOWEVER... if I change this to 0x0A in my simulated response, the Flash loader will issue a subsequent command, 

02 FD.

I have reduced the baud rate to 9600 in case there were timing problems, no difference. I have checked the signals with an oscilloscope, all well-formed characters.

I have tried two different versions of Flash Loader (2.5.0 and 2.8.0), three computers, and three different PCBs with the same chip on board.

I am at my wits end.  Can anyone shine light on this one?

Thanks,

Steve

#usart-bootloader #flash-loader-demo #bootloader
2 REPLIES 2
Posted on August 11, 2017 at 00:22

Can we try not to post duplicates, you can get to your old posts via your Inbox or My view. Depending on who's on the forum, and the nature of their experiences you might not get responses. I'm not using L1 parts.

Using USB-to-Serial adapters?

What version of the system loader do the parts in question have?

I use RealTerm in hex mode to walk the loader through it's functionality.

Noise on other pins supported by the loader may interfere with it's operation, the initial 0x7F pattern is used for auto-baud timing. Suggest using 9600 8E1 (Even Parity)

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Krenek.Steve
Associate III
Posted on August 11, 2017 at 02:06

Hi Clive.  Sorry for the repost - I had erroneously thought this was a different forum from the one I first posted in.

Using hardware serial port, 9600 8E1.

Get proper responses to the first 2 commands from FlashLoader.  

The 3rd byte of the response to the 00 command indicates that it's ver 3.0 of the bootloader in the chip.

Yep, I have the equivalent functionality of your Realterm, though I'm using it to test the functionality of FlashLoader, not the chip response. At this stage the chip is giving perfect responses. It is FlashLoader that does nothing after receiving the correct response to its second message, 00 FF.  

What is most perplexing is that if I simulate a response from the chip with the INCORRECT byte count (0A instead of 0B), then FlashLoader will issue it's subsequent command.