Predefined project level defines

Post your requests and ideas on the future development of mikroPascal PRO for PIC.
Post Reply
Author
Message
janni
Posts: 5373
Joined: 18 Feb 2006 13:17
Contact:

Predefined project level defines

#1 Post by janni » 15 Nov 2014 02:58

Could we have extended predefined project level defines like in mC
Predefined project level defines
mikroC PRO for PIC provides several predefined project level defines that you can use in your project :

First one is equal to the name of selected device for the project i.e. if 16F887 is selected device, then 16F887 token will be defined as 1, so it can be used for conditional compilation :
#ifdef P16F887
...
#endif
The second one is value of frequency (in kHz) for which the project is built :
#ifdef __FOSC__ == 80000
...
#endif
Third one is for identifying mikroC PRO for PIC compiler:
#ifdef __MIKROC_PRO_FOR_PIC__
...
#endif
Fourth one is for identifying the build version. For instance, if a desired build version is 142, user should put this in his code :
#if __MIKROC_PRO_FOR_PIC_BUILD__ == 142
...
#endif
Looks like mP and mB have only the first one implemented :( .

User avatar
filip
mikroElektronika team
Posts: 11874
Joined: 25 Jan 2008 09:56

Re: Predefined project level defines

#2 Post by filip » 28 Nov 2014 09:55

Hi,

Thank you for the proposal, I will pass it to our developers.

Regards,
Filip.

Post Reply

Return to “mikroPascal PRO for PIC Wish List”