Quality RTOS & Embedded Software

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




Loading

Memory used in uIP IAR build for AT91SAM7X

Posted by baxsie on November 13, 2005
The summary of the map file for the uIP_Demo_IAR_ARM7 shows:

21 480 bytes of CODE memory
34 534 bytes of DATA memory
9 981 bytes of CONST memory

30K for code on a 256K flash part seems very reasonable. But the 34K of data for a 64K RAM part seems steep. Is there a reasonable way to reduce this requiement? How much is used by the kernal and how much is used by uIP?

Full map file here for reference:
http://www.baxsie.com/scratch/FreeRTOS_uIP_IAR_Map_AT91SAM7X-EK.txt
I also built uIP_Demo_Rowley_ARM7, which seems to say 45K flash and 15K RAM, but I'm not sure I'm reading it right.
http://www.baxsie.com/scratch/FreeRTOS_uIP_Rowley_AT91SAM7X-EK.txt

RE: Memory used in uIP IAR build for AT91SAM7X

Posted by Richard on November 13, 2005
The kernel requires RAM for the task stacks, as described in the Memory Management section of the API documentation. The amount of RAM reserved for the kernel to use is defined by configTOTAL_HEAP_SIZE in FreeRTOSConfig.h. This can be sized to whatever is appropriate for your application (how many tasks/queues/semaphores do you want to create?). The default heap size is defined to provide enough heap to run all the demo tasks. If you reduce the heap size then also remove some of the demo tasks. Most true applications will not require so many tasks. From the map file in your link you can see that the majority of RAM is going here.

The uIP memory usage is also configurable. In particular the buffer it uses to receive and create IP packets can be set as low as 200 bytes (I think?), but the demo sizes this to be around 2K (again this is from memory so can be double checked). This can be optimised for your system also. From the map file in your link the uIP buffer is using much less RAM than the heap, but still, but total uIP RAM usage is still 3K (very small for a stack!).

Finally, again from the map file, there is 7.5K allocated to SAM7_EMAC.h. This memory is used by the peripheral buffers - the RAM that the emac itself uses to pass data to and from the application. The size and number of the Tx buffers is also configurable, but the Rx buffers are fixed.

regards.


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




Copyright (C) 2004-2010 Richard Barry. Copyright (C) 2010-2016 Real Time Engineers Ltd.
Any and all data, files, source code, html content and documentation included in the FreeRTOSTM distribution or available on this site are the exclusive property of Real Time Engineers Ltd.. See the files license.txt (included in the distribution) and this copyright notice for more information. FreeRTOSTM and FreeRTOS.orgTM are trade marks of Real Time Engineers Ltd.

Latest News:

FreeRTOS V9.0.0 is now available for download.


Free TCP/IP and file system demos for the RTOS


Sponsored Links

⇓ Now With No Code Size Limit! ⇓
⇑ Free Download Without Registering ⇑


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Renesas Electronics Gold Alliance RTOS Partner.jpg

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Atmel RTOS partner supporting ARM Cortex-M3 and AVR32 microcontrollers

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

Xilinx Microblaze and Zynq partner

Silicon Labs low power RTOS partner

Altera RTOS partner for Nios II and Cortex-A9 SoC

Freescale Alliance RTOS Member supporting ARM and ColdFire microcontrollers

Infineon ARM Cortex-M microcontrollers

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

Cypress RTOS partner supporting ARM Cortex-M3

Fujitsu RTOS partner supporting ARM Cortex-M3 and FM3

Microsemi (previously Actel) RTOS partner supporting ARM Cortex-M3

Atollic Partner

IAR Partner

Keil ARM Partner

Embedded Artists