Hello, I modified a project initially written for windriver diab compiler to work with Codewarrior.
I then ran the project with the help of cw_icdppcnexus but experienced a problem after startup when the PC goes to the main function: The PC gets 000000h which makes execution continue at a location where there is no executable code
So I had a look at the assembly instructions equivalency and compared the original Windriver executable file with the CodeWarrior one. Here is the result:
The window on top is the Codewarrior generated code, the second is from Windriver.
Codewarrior generates some extra instructions which make the PC go to 00000h due to SE_BLR instruction (LR is 00000h). After that the code looks very similar for both compilers. Is there a way to disable the generation of those extra instructions?? (does not actually know what those instructions do)
Thanks a lot
P.SCHMIDT
Solved! Go to Solution.
I solved this problem. It was in fact due to bad memory mapping
I have the same problem and I cannot find the correct configuration for the memory mapping.
Please, can you help me with the memory mappgig?
Thanks!
Here is my memory section from the linker:
MEMORY
{
/* Interrupt Service Routines */
flash_rchw : org = 0x00000000, LENGTH = 0x8
flash_vec : org = 0x20000, LENGTH = 0xD00
/* 1MB Internal Flash */
int_flash : org = 0x20D00, LENGTH = 1M - 0x20D00
/* 80K Internal SRAM */
int_sram : org = 0x40000000, LENGTH = 80k
stack : org = 0x00200000, len = 0x0200
}