Relocatable code?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Relocatable code?

Jump to solution
1,216 Views
bonzo
NXP Employee
NXP Employee

Is it possible to generate relocatable DSC code using CW10.6 with Processor Expert?  Also need to relocate the vector tables.

If so, how?

 

Processor is MC56F84763 and uses a bootloader.

 

Thanks,

Brad

Darren Hintze

Labels (1)
0 Kudos
1 Solution
949 Views
TICS_Fiona
NXP Employee
NXP Employee

Hello Bradley

Yes, user can relocate the vector table. With Processor Expert,  you can modify the address for .p_Interrupts secion in CPU component:

vector.png

However, there are two tips that need to pay attention to:

1)  Please reserve 0x00_0000 for program entry because after power-on reset, the device must boot from program flash at 0x00_0000.  So 0x00_0000~0x00_0003 should reserved for hardware reset and cop reset.

2)  Please set the Vector Base Address Register (INTC_VBA) to the new interrupt vector address in start-up code.

Best Regards

Fiona Kuang

TIC - Technical Information Center

-----------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Mark Correct button. Thank you!

-----------------------------------------------------------------------------------------------------------------------

View solution in original post

2 Replies
950 Views
TICS_Fiona
NXP Employee
NXP Employee

Hello Bradley

Yes, user can relocate the vector table. With Processor Expert,  you can modify the address for .p_Interrupts secion in CPU component:

vector.png

However, there are two tips that need to pay attention to:

1)  Please reserve 0x00_0000 for program entry because after power-on reset, the device must boot from program flash at 0x00_0000.  So 0x00_0000~0x00_0003 should reserved for hardware reset and cop reset.

2)  Please set the Vector Base Address Register (INTC_VBA) to the new interrupt vector address in start-up code.

Best Regards

Fiona Kuang

TIC - Technical Information Center

-----------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Mark Correct button. Thank you!

-----------------------------------------------------------------------------------------------------------------------

949 Views
federicogori
Contributor I

Hello I have a similar problem. I have to program ( bootloader and blinking LED). The to programs are located in different part of memory, and I have 2 different vector table ( the bootloader vector table start from 0x000000, and the "LED" vector table from 0x00000F0). After dowloading the blinking led program, bootloader jump to the main function of LED application, but the LED doesn't blink, like the interrupt generating from the timer can't be handle.

Can you explain how to set the INC_VBA ? 

Can you give me the right steps to jump from bootloader to the blinking led with  changing  the interrupt vector?

Thank you soo much!

Best regards

Federico 

0 Kudos