Need to change Vector table Address

Post here all questions related to LibMaple core if you can't find a relevant section!
stevestrong
Posts: 315
Joined: Fri Dec 27, 2019 4:53 pm
Answers: 7
Location: Munich, Germany
Contact:

Re: Need to change Vector table Address

Post by stevestrong »

I have no idea if this is resetting or jumping to 8010000, the debugger should show you the stack pointer.

sankarAMP2
Posts: 27
Joined: Mon Feb 10, 2020 2:50 pm
Answers: 1
Location: India

Re: Need to change Vector table Address

Post by sankarAMP2 »

In keil
Registers window

Code: Select all

R0:0x08010145
R13(SP):0x20000458
in debugger window the pointer showing

Code: Select all

0x8010E62 421   CMP    r1,r4
I'm in very big confusion now, why it this bootloader is working with keil generated code not Arduino?

stevestrong
Posts: 315
Joined: Fri Dec 27, 2019 4:53 pm
Answers: 7
Location: Munich, Germany
Contact:

Re: Need to change Vector table Address

Post by stevestrong »

You should track step by step with the debugger what is happening with Arduino generated code.
If the bootloader jumps to 0x8010xxxx address then it is the application which is faulty.

You could also compare the MAP files for the code generated with Keil and Arduino to figure out the difference.

darkspr1te
Posts: 14
Joined: Tue Jan 07, 2020 4:22 pm

Re: Need to change Vector table Address

Post by darkspr1te »

It could be a module in arduino being enabled (eg usb) that might be conflicting with the bootloader , that is just a assumption thought.

sankarAMP2
Posts: 27
Joined: Mon Feb 10, 2020 2:50 pm
Answers: 1
Location: India

Re: Need to change Vector table Address

Post by sankarAMP2 »

thank you @stevestrong and @darkspr1te.
bootloader is jumping to 0x8010000 perfectly but application not going forward. I assume that the problem with arduino generated file.
Now I want to generate same simple blinky example in STM32CUBE IDE. I'm new to use this IDE.
I found linker file STM32F103RET6_FLASH.ld and I changed flash address there, Is that enough or need to change any other files?

stas2z
Posts: 131
Joined: Mon Feb 24, 2020 8:17 pm
Answers: 8

Re: Need to change Vector table Address

Post by stas2z »

sankarAMP2 wrote:
Mon Jun 08, 2020 6:50 am
I found linker file STM32F103RET6_FLASH.ld and I changed flash address there, Is that enough or need to change any other files?
VECT_TAB_OFFSET inside the system_stm32f1xx.c

sankarAMP2
Posts: 27
Joined: Mon Feb 10, 2020 2:50 pm
Answers: 1
Location: India

Re: Need to change Vector table Address

Post by sankarAMP2 »

stas2z wrote:
Mon Jun 08, 2020 7:54 am
VECT_TAB_OFFSET inside the system_stm32f1xx.c
Thank you @stas2z
After changing flash address in both files, this blinky application generated in cude ide also not working with that bootloader. Bootloader might be buggy.. :roll:

stas2z
Posts: 131
Joined: Mon Feb 24, 2020 8:17 pm
Answers: 8

Re: Need to change Vector table Address

Post by stas2z »

First check if your jump from bl is working properly, just flash generated bin to exact offset using cubeprog

sankarAMP2
Posts: 27
Joined: Mon Feb 10, 2020 2:50 pm
Answers: 1
Location: India

Re: Need to change Vector table Address

Post by sankarAMP2 »

Thank you every one for your great support.
Now its working fine.
bug in bootloader code only.
by commenting __set_MSP(*mcuFirstPageAddr); this line is going to work.

Post Reply

Return to “General discussion”