Hi,
I want to build a MPC5643L CodeWarrior project using codes generated by toolbox, but there're some errors I never met .Can anybody give me some suggestion to configured the CodeWarrior project?
Thank you!
Hj
Original Attachment has been moved to: can_simple_block_rappid_rtw.rar
Hello,
I would like to ask you to NOT create duplicated threads at NXP community, because of our resources.
About your issue, there is a problem with mixing code generated by Rappid and code generated by CodeWarrior.
At first, if you use conditional translation in assembly file, you must create specific file for symbols. Please see figures below.
I created defines.inc file and I added this file to your project. In this file I created symbol VLE_IS_ON 1 which you use in crt0.s
Second step is to tell to EPPC Assembler there is defines.inc file. Click project settings, select EPPC assembler, check Generate Listing File and choose the file.
After this steps are done, there are another compile (linker) errors, because in crt0.s file you use linker symbols which does not exist in linker file. You have two possible solutions. First one is to define this symbols in linker file, second one is not use symbols only symbols defined in linker file.
In general, it is not good to mix these two project together, because there another dependencies like exception and interrupts settings and some other and this could cause some other issues.
If you have any other questions, please feel free to write me back.
Regards,
Martin
Hello,
when you look at the linker file, there are some symbols defined by default:
_stack_addr = ADDR(stack)+SIZEOF(stack);
_stack_end = ADDR(stack);
_heap_addr = ADDR(heap);
_heap_end = ADDR(heap)+SIZEOF(heap);
So for example, if you use symbol called __SP_INIT in your project, you must define it in linker. It should look like:
__SP_INIT = _stack_addr;
Now it is up to you to create all necessary symbols and assign correct addresses to them.
For more information about linker and all it's features and settings, please read the document in post attachment.
Regards,
Martin
Hi Martin,
First of all,I'm sorry for creating duplicated threads at NXP community because I was hurried to ask for help .For some reasons,we try to add all the codes generated by toolbox to a CodeWarrior project ,hoping that it's possible for us to write codes in both simulink model and CodeWarrior project.
Besides,I want to use linker symbols in crt0.s file to eliminate the compile (linker) errors .Can you help me to define these symbols in linker file?
Thank you !
Hj