2019-01-17 08:38 AM
I'm using an ST part that has 2 banks of flash memory. I've built a code image for the second bank and downloaded it through the debugger. I've changed the startup script to set the VTOR register to the value needed for the second bank, with the line:
set *0xe000ed08 = (0x08040000)
however VTOR still has the default value for the first flash bank (0x08000000) after the download. I assume I've made a mistake in the script. Can anyone tell me how to correctly change the VTOR value in the script? Thanks.
Regards,
Lee
2019-01-17 08:47 AM
Perhaps other code, in SystemInit(), which changes it.
ST has a backward macro method for setting the address, my preference is to have the linker fixup a symbol like it's designed too.
Not sure how to step the scripting here. You could probably write the value or a pattern to a RAM address as well, and check the script is executing by examining the memory in the debugger.
set *0x20002000 = (0x12345678)