We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi.
I am using two Project targets, a Debug and a Release, and now I what to test which one that is selected, but how do I do it?
#ifdef Debug ????????? /* Set the Vector Table base location at 0x08000000 */ NVIC_SetVectorTable(NVIC_VectTab_FLASH, 0); #else /* VECT_TAB_FLASH */ /* Set the Vector Table base location at 0x08001800 */ NVIC_SetVectorTable(NVIC_VectTab_FLASH, 0x1800); #endif
I hope somebody can help me.
Soeren P.
In the project options, you will have to define some symbol that indicates which Target is being built.
It is a longstanding deficiency of uVision that it doesn't make such information directly available.
:-(
One way would be to define an appropriate symbol in the compiler settings dialog window.
Hi, go to your project setting, tab C/C++ and add a DEBUG in the Preprocessor Symbols field for the debug build. And RELEASE for your release build.
Thanks.