It's possible to generate clearer error messages for this scenario; the following change to chsys.h works:
Code: Select all
#if PORT_SUPPORTS_RT == TRUE
bool chSysIsCounterWithinX(rtcnt_t cnt, rtcnt_t start, rtcnt_t end);
void chSysPolledDelayX(rtcnt_t cycles);
#else
#define chSysIsCounterWithinX(a, b, c) _Pragma("GCC error \"chSysIsCounterWithinX() not available on platform\"")
#define chSysPolledDelayX(a) _Pragma("GCC error \"chSysPolledDelayX() not available on platform\"")
#endif
(Documentation on _Pragma: https://gcc.gnu.org/onlinedocs/gcc-8.3. ... agmas.html)