I'm not 100% sure, but I think this will detect that it's being compiled for the Link:
#ifdef __arm__
You can use #ifndef instead of #ifdef to instead compile only for non-Link environments (e.g. the simulator).
Note that ARM-based devices such as Windows RT and Android devices will be detected as Links (although I can't imagine why you would be running the KISS-IDE simulator on Windows RT or Android).
If this works, please let us know.
-Jeremy Rand
Senior Programmer, Team SNARC (2012-2013), Norman Advanced (2010-2011), Norman HS (2008-2009), Norman North (2005-2007), Whittier MS (2003-2004)
2012-2013 VP of Tech, 2011 President, Botball YAC (2009-2013)
Mentor, Alcott and Whittier MS
I'm not 100% sure, but I think this will detect that it's being compiled for the Link:
#ifdef __arm__
You can use #ifndef instead of #ifdef to instead compile only for non-Link environments (e.g. the simulator).
Note that ARM-based devices such as Windows RT and Android devices will be detected as Links (although I can't imagine why you would be running the KISS-IDE simulator on Windows RT or Android).
If this works, please let us know.
-Jeremy Rand
Senior Programmer, Team SNARC (2012-2013), Norman Advanced (2010-2011), Norman HS (2008-2009), Norman North (2005-2007), Whittier MS (2003-2004)
2012-2013 VP of Tech, 2011 President, Botball YAC (2009-2013)
Mentor, Alcott and Whittier MS
I can confirm that
#ifdef __arm__
works. I used it for a while with the link.You can also check for windows if you want to do that by:
#ifdef _WIN32
I believe.I used this to import the libkovan from KIPR's github so I could use codeblocks.