I started a new project for the with codewarrior development studio for S12(x)V5.1.
The compiler generates an "Error: C4202: Invalid pragma OPTION, ADD or DEL expected. " in file "IO_Map.h" this file is added by the tool.
How can this error be fixed?
Regards
Burton
Hello Burton
Thanks a lot for contacting us.
What is compiler option in the "#pragma OPTION…" that introduced this error?
Would you please add this option to your compiler command line options, this error will go away:-Press Alt-F7 to pull up your target settings
-In the left hand panel, expand the 'Target' tree and select 'Compiler for HC12'
-In the right hand panel, add this option to the command line.
Hope it helps! If not, could you please attach an example project to reproduce the problem?
Best Regards
Fiona Kuang
Technical Information & Commercial Support
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi Fiona,
The only compiler option is "-Mb"
#ifndef __V30COMPATIBLE__
#pragma OPTION DEL V30toV31Compatible - This line in "IO_Map.h" is
causing the error
#endif
Thank you for your help
Burton
Hello Burton
There should be some code like below before “#pragma OPTION DEL” that you extracted in the same head file ("IO_Map.h"):
#pragma OPTION ADD V30toV31Compatible …….
Could you please attach your project to help us reproduce the problem? Thanks!
Best Regards
Fiona Kuang
Technical Information & Commercial Support
I posted the project on dropbox:
https://www.dropbox.com/s/7dwhmqqwhtwcp0f/PackAndGo.zip?dl=0
This is caused by your DEL define in flasher_comms.h To fix, either rename DEL define or move #include "flash_comms.h" down in your C files, so that it comes below PE and all other <> includes.
In future fighting similar issues, try preprocessing code which fails to compile. #pragma OPTION 0x7F ... in preprocessor output instead of #pragma OPTION DEL ... will tell you what to search for.
Regards
Edward
Hallo Edward,
Thank you very much, that solved the problem, you guys are great, thanx!
regards
Burton
Hi Fiona,
Thanx for your email, my evaluation license unfortunately expired, can
it be extended perhaps?
Best regards
Hi Burton,
You can contact the license team via the Case system.
After the merge of Freescale and NXP, technical support cases are answered in a different system.
To submit your case into the new system, please follow below steps:
1) Go to http://www.nxp.com/support/sales-and-support:SUPPORTHOME.
2) On the bottom of the page under Submit New Issues, click Hardware & Software.
3) Register with your business email to access NXP technical online support.
4) A verification email will be sent to your account. Click the link embedded in that email to verify your access.
5) On the NXP online support page, select Contact Support from the top menu and click “submit a new case” to start the process.
Have a great day,
Pascal
NXP Technical Support
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Thank you very much Pascal,
I will get to you on the PRAGMA issue,
Thank you for your help
Burton