Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem TCP & FAT




Loading

How to monitor stack usage in a PIC24?

Posted by renaldtravispaad on March 15, 2010
Hi everyone,
I am a newbie to freeRTOS. I did a baseline software development for a project using freeRTOS on a microchip PIC24F. The system seems to be working fine with its current heap and stack values. I know that I just got lucky with my numbers. I would like to do a thorough stack and heap analysis as part of my optimization. First, I want to do a stack requirement analysis. Is there any demo code for the PIC24F processor that clearly tells me how to use pxCurrentTCB for the purpose? Also, How do I find out the amount of heap being used by my code?

I would really appreciate any help

Thanks!
Sid

RE: How to monitor stack usage in a PIC24?

Posted by Dave on March 15, 2010
“First, I want to do a stack requirement analysis.”


See http://www.freertos.org/uxTaskGetStackHighWaterMark.html

“ How do I find out the amount of heap being used by my code?


If you are using heap_1.c or heap_2.c then simply call xPortGetFreeHeapSize().


[ Back to the top ]    [ About FreeRTOS ]    [ Sitemap ]    [ ]




Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.

Latest News

FreeRTOS kernel V10 is available for immediate download. Now MIT licensed.


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

IAR Partner

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

OpenRTOS and SafeRTOS