2015-06-08 01:05 PM
Hello,
I'm trying to use the default bootloader of this STM32L151CCT6 over USART1.I've read and follow all the tips and tutorials of AN2606 and AN3155, but without sucess.This is my process to try a communication:Turn on my board
Set the microcontroller in reset mode (LOW in Reset Pin)
Set the pin BOOT0 in HIGH
Release the Reset Pin
Send 0x7F;
Wait for 0x79;
When I send 0x7F and wait for 0x79, it never returns.
Am I missing something in this process?Many thanks for any help or guidance that can be offered!2015-06-08 01:30 PM
Analogue supplies connected?
Even Parity? CMOS Serial? Not RS232 levels. Sent as hex, in a tool like RealTerm?2015-06-08 02:08 PM
Hello Clive1,
My board is connected to MAX3232 then I have a DB9 to my computer. The pins RX/TX has a pullup resistor +3V3. (This little module -http://i00.i.aliimg.com/photo/v0/1857319466/F08056_JMT_1_Pcs_MCU_Mini_RS232.jpg
)I used the Terminal or Realterm to send the 0x7F. In these software I used 9600, 19200 or 115200 8N1, but nothing changed.Thank you!2015-06-08 02:41 PM
Right now you need to confirm the part is functional in any fashion
EVEN PARITY Double check the TX and RX sense is correct. Check you can access the part via JTAG or SWD Check the state of the NRESET pin Check the orientation of the part Do you have a schematic2015-06-09 12:09 AM
After releasing reset, you need to wait for a while for the part to come out of reset and start executing the bootloader before sending out the 0x7F.
You need to make sure that BOOT1 pin is low. I am not familiar with the terminal program you are using, but are you sure you are sending out 0x7F and it is not getting translated to some other character due to terminal emulation?2015-06-09 05:02 AM
Hello Clive1,
With Even Parity don't works either.The sense of Tx/Rx is correct, because I use this pins to send AT Commands in my application.The JTAG and SWD is ok too.I have a scope here to debug this process, and I can see NRESET pin changing.2015-06-09 05:09 AM
Hello hwasti,
When I start the process, I hope for a while until send 0x7F.In this part number there isn't this pin (BOOT1).Is for sure that this terminas are sending the correct values, however, do you have another to tell me?2015-06-10 02:19 AM
>In this part number there isn't this pin (BOOT1).
Sure there is. It is pin 20 on the 48 pin packages. After boot it can also be used as PB2 and a few other alternate functions. But during boot it needs to be externally driven or pulled low in order for you to boot to the ROM bootloader.2015-06-10 05:02 AM
Hello hwasti and clive1!
I was discussion with a friend about this issue, and he pointed the problem.The board I'm using, does not provide the pins PA9 and PA10 and I'm using the PB6 and PB7 to send my AT commands in the application. However, I didn't pay attention for this detail that is written on AN2606.I will design a new board for my project and change this pins.I'd like to thanks your help!2015-06-10 02:05 PM
Glad you found the problem. As you redesign the board, keep in mind the chip does have a BOOT1 input and it needs to be low during boot in order to do what you want to do.