cancel
Showing results for 
Search instead for 
Did you mean: 

How to write a code after RDP level 1 ?

swapnil champaneria
Associate III
Posted on June 23, 2018 at 08:49

Hello

I am using stm32l152rc controller and I am trying to load a code using a dfusedemo application and during that time my flash  is on RDP level 1.

With help of msp my code jump to location 0x1FF00000 which is location of system boot loader.

So, My question is  how can I load a new code?

here I am attached some screen short which can help to identify my problem.

thanks,

Swapnil Champaneria

#system-bootloader #st-dfuse #rdp-level-1
1 ACCEPTED SOLUTION

Accepted Solutions
Posted on July 05, 2018 at 15:13

You don't want to use the BOOTx pins, or your design doesn't permit you too?

The RDP level effects the behaviour of the boot loader by locking it down. If you want different behaviour you are going to need to implement your own loader/DFU functionality, and perhaps erase/write individual sectors rather than bulk-erase.

Also as noted earlier you are setting the MSP incorrectly.

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

View solution in original post

4 REPLIES 4
Posted on June 24, 2018 at 19:56

You don't want to set the stack pointer to an address in ROM, the stack needs to be in RAM, per the *content* of the vector.

You might have to provide your own access methods for a part in RDP 1 as the system loader locks down certain functionality.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on July 05, 2018 at 13:31

sir,

Actually I'm using internal boot loader (system boot loader) with help of software because i don't want to use Boot 0 and Boot 1 pin to access that. Without RDP level 1 it's worked fine but when I apply RDP level 1 it won't work properly.

when I'm trying to decrees the RDP level 1 to 0 my flash was erased so I can't access boot loader (system boot loader) with help of software. 

thanks regards 

Posted on July 05, 2018 at 15:13

You don't want to use the BOOTx pins, or your design doesn't permit you too?

The RDP level effects the behaviour of the boot loader by locking it down. If you want different behaviour you are going to need to implement your own loader/DFU functionality, and perhaps erase/write individual sectors rather than bulk-erase.

Also as noted earlier you are setting the MSP incorrectly.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on July 09, 2018 at 07:34

You don't want to use the BOOTx pins, or your design doesn't permit you too?

sir, 

actually  i don't won't to use BOOTx pins, and thanks to notify regarding MSP, without it my code work same, just  in my case i have to jump on system boot loader location.