sze3gi wrote on Monday, May 06, 2019:
Hi!
I am using FreeRTOS 9.0.0. I am trying to determine the stack usage of my tasks and during this I ran into the following problem.
When I increase the stack of the task, it starts to use more stack. For example when the stack size was 100 (words - 32 bit) the uxTaskGetStackHighWaterMark returned 56, meaning that the task uses 56 bytes of stack at maximum. Then I increased the stack size to 160 words and a uxTaskGetStackHighWaterMark returned 126, meaning that the stack usage doubled! I ran the same test code in both cases, the only difference between the to cases is the stack size of the task. No stackoverflow occured, because i did not ran into the stackoverflow hook, which was enabled the whole time. I am using STM32F030F4. How is this possible?
Thanks