Quality RTOS & Embedded Software

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


Loading

STR912 IAR demo and FreeRTOS v4.20

Posted by Nobody/Anonymous on February 12, 2007
Hi!

I just tried to compile STR912 demo with newest version (4.2.0) of FreeRTOS without success. Produced code is too big to fit in 32KB limit for IAR KS version, even with maximum size optimization. If I switch back to 4.1.3 everything compiles and links without errors.

So... this demo (and maybe others also) needs some tuning (removing some tasks) to work "out of the box" with IAR 4.41 and FreeRTOS 4.2.0

Best regards,
Slawc

RE: STR912 IAR demo and FreeRTOS v4.20

Posted by Nobody/Anonymous on February 13, 2007
Bummer. It must have been tight before. There are only minor changes between the two versions. This needs a mod in the download to maintain compatibility with the kickstart compiler.

RE: STR912 IAR demo and FreeRTOS v4.20

Posted by James Grenning on September 26, 2007
I just ran into the same problem. I downloaded the IAR evaluation that support 32k of object code, and then unzipped the project. The i did a clean and a rebuild all. it choked reporting the build exceeded the 0x8000 limit.

Has anyone solved this problem?

thanks, James

RE: STR912 IAR demo and FreeRTOS v4.20

Posted by Richard on September 26, 2007
The STR9 demo had a major update for the V4.5.0 release. The project contains 5 configurations, and my tests showed that the THUMB configuration came in at 31624 bytes - just under the limit. This configuration was included specifically so it could be built with the KickStart edition of the IAR tools. Are you having problems still with the THUMB configuration in the V4.5.0 download?

You can remove some of the demo tasks to reduce the code size further. I can tell you how to do this if necessary.

Regards.

RE: STR912 IAR demo and FreeRTOS v4.20

Posted by James Grenning on September 27, 2007
Thanks for the help. I have downloaded the current FreeRTOS v4.5

I am using the IAR kickstart version 4.0 (current version)

Thanks for the pointer to the THUMB configuration. I tried each configuration and they all end with a too big error. I did not see how to reduce the number of tasks though. I'd love the help, so thanks for the offer to help.

James

RE: STR912 IAR demo and FreeRTOS v4.20

Posted by Richard on September 27, 2007
I think IAR V4.2 is the latest so I'm surprised the project can be opened in V4.0. Sometimes with IAR opening the project in an older version will silently clobber some of the compilation options, so be aware of that if you have any compilation problems.

All the demo tasks are created in main(). If you look in main you will see:

vStartIntegerMathTasks( tskIDLE_PRIORITY );
vStartLEDFlashTasks( mainLED_TASK_PRIORITY );
vStartPolledQueueTasks( mainQUEUE_POLL_PRIORITY );
vStartSemaphoreTasks( mainSEM_TEST_PRIORITY );
vStartBlockingQueueTasks( mainBLOCK_Q_PRIORITY );
vStartDynamicPriorityTasks();
vStartMathTasks( tskIDLE_PRIORITY );
vAltStartComTestTasks( mainCOM_TEST_PRIORITY, mainCOM_TEST_BAUD_RATE, mainCOM_TEST_LED );
vStartGenericQueueTasks( mainGENERIC_QUEUE_PRIORITY );
vStartQueuePeekTasks();


Start by commenting out some of these, for example:

//vStartIntegerMathTasks( tskIDLE_PRIORITY );
vStartLEDFlashTasks( mainLED_TASK_PRIORITY ); // Leave this one!
//vStartPolledQueueTasks( mainQUEUE_POLL_PRIORITY );
//vStartSemaphoreTasks( mainSEM_TEST_PRIORITY );
//vStartBlockingQueueTasks( mainBLOCK_Q_PRIORITY );
vStartDynamicPriorityTasks();
vStartMathTasks( tskIDLE_PRIORITY );
vAltStartComTestTasks( mainCOM_TEST_PRIORITY, mainCOM_TEST_BAUD_RATE, mainCOM_TEST_LED );
vStartGenericQueueTasks( mainGENERIC_QUEUE_PRIORITY );
vStartQueuePeekTasks();

Each of the demo tasks is also checked from within main.c - within a function prvCheckOtherTasksAreStillRunning() - so you also need to comment out the reference to the task within this function.

For example, if you have commented out vStartIntegerMathTasks(), then you also need to comment out:

//if( xAreIntegerMathsTaskStillRunning() != pdTRUE )
//{
// ulErrorFlags |= 0x01;
//}

Likewise, if you have commented out vStartBlockingQueueTasks(), then you also need to comment out:

//if( xAreBlockingQueuesStillRunning() != pdTRUE )
//{
// ulErrorFlags |= 0x08;
//}


IAR is intelligent enough to remove any unreferenced functions from the binary image, so this should make the code smaller by itself. If not, then remove the unused demo tasks from the build also. For example, if commenting out vStartIntegerMathTasks(), then you can also remove the file in which this function is defined, integer.c. This last step should not be necessary though.

Regards.


RE: STR912 IAR demo and FreeRTOS v4.20

Posted by James Grenning on September 27, 2007
After looking a little further I have v4.42.

I commented out some tasks and have gotten it to compile and link. I don't have the board to run it on yet. I wanted to trial run the build first.

thanks for your help, James


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


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

Latest News

NXP tweet showing LPC5500 (ARMv8-M Cortex-M33) running FreeRTOS.

Meet Richard Barry and learn about running FreeRTOS on RISC-V at FOSDEM 2019

Version 10.1.1 of the FreeRTOS kernel is available for immediate download. MIT licensed.

View a recording of the "OTA Update Security and Reliability" webinar, presented by TI and AWS.


Careers

FreeRTOS and other embedded software careers at AWS.



FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Espressif ESP32

IAR Partner

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Renesas

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

Xilinx Microblaze and Zynq partner