uxTaskGetStackHighWaterMark. Freescale port.

angelchik wrote on Tuesday, February 07, 2012:

Hello, everyone! I’m using freescale HCS12 port of the FreeRTOS. And I have a little problem with the uxTaskGetStackHighWaterMark() function. The return type of the one is


, which defined as


, i.e. there is only 8 bit. It means, that only 256 stack bytes can be debugged using uxTaskGetStackHighWaterMark() function, besides, usTaskCheckFreeStackSpace() function have a 16-bit return type (USHORT). But! I’m using much more, than 256 byte (512 and higher). Of course, i have to resolve my problem by changing the return type of the uxTaskGetStackHighWaterMark() function to UINT (16 bit)…

So, why does FreeRTOS developers define such return type of this function? Maybe, it was an involuntary definition? Maybe i shouldn’t redefine this type?

angelchik wrote on Tuesday, February 07, 2012:

I mean, could it leads to some other problems? Maybe it was connected with fact, that uxTaskGetStackHighWaterMark() is very heavy for the processor load and created only for the debug purposes?

Sorry for my bad english :))))