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

FreeRTOS and HighTec Development Platform build problem

Posted by pamdev on June 21, 2017

Hi! My team is trying to use TC1798 evaluation board with FreeRTOS 9.0.0.

I'm experiencing big trubles porting FreeRTOS Demo project for TC1782 to the latest(?) version of HighTec Development Platform (Version: 1.6.2.20170130-b29c1f1). As I have concluded the Demo project was made for the Platform version prior to 1.1.0 (though it seems to build on version 1.2 platform). I did my best trying to port the project code for the HighTec Development Platform but nothing helps. Build fails with message:

~~~ FreeRTOS_Demo: Each LDF project needs an LDF project nature (since version 1.1.0) ~~~

I moved the FreeRTOS Demo source code folder to a new empty HighTec project for TC1782 and copied some config setting from demo to the new project (e.g. include paths). I tried to build the project but got the error from 'FreeRTOSConfig.h' file that has the following line:

~~~

error Ensure CreateProjectDirectoryStructure.bat has been executed before building. See comment immediately above.

~~~

The comment itself tells that you can remove that line and refresh the project. That's what I did but ...

The next build gave lots of errors like this:

~~~ "C:HighTectoolchainstricorev4.9.1.0-infineon-1.1/bin/tricore-gcc" -c -I"../h" -I"C:HighTectoolchainstricorev4.9.1.0-infineon-1.1tricoreinclude" -I"C:UsersTVTworkspaceCORRIDARTOSDemoCommonDemoSourceinclude" -I"C:UsersTVTworkspaceCORRIDARTOSDemo" -I"C:UsersTVTworkspaceCORRIDARTOSDemoFreeRTOSSourceinclude" -I"C:UsersTVTworkspaceCORRIDARTOSDemoFreeRTOSSourceportableGCCTriCore1782" -fno-common -Os -g3 -W -Wall -Wextra -Wdiv-by-zero -Warray-bounds -Wcast-align -Wignored-qualifiers -Wformat -Wformat-security -DTRIBOARDTC1782 -fshort-double -mcpu=tc1782 -mversion-info -MMD -MP -MF"RTOSDemo/FreeRTOSSource/portable/MemMang/heap2.d" -MT"RTOSDemo/FreeRTOSSource/portable/MemMang/heap2.d" -o "RTOSDemo/FreeRTOSSource/portable/MemMang/heap2.o" "../RTOSDemo/FreeRTOSSource/portable/MemMang/heap2.c" 'Finished building: ../RTOSDemo/FreeRTOSSource/portable/MemMang/heap2.c' ' ' 'Building file: ../RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.c' 'Invoking: TriCore C Compiler' "C:HighTectoolchainstricorev4.9.1.0-infineon-1.1/bin/tricore-gcc" -c -I"../h" -I"C:HighTectoolchainstricorev4.9.1.0-infineon-1.1tricoreinclude" -I"C:UsersTVTworkspaceCORRIDARTOSDemoCommonDemoSourceinclude" -I"C:UsersTVTworkspaceCORRIDARTOSDemo" -I"C:UsersTVTworkspaceCORRIDARTOSDemoFreeRTOSSourceinclude" -I"C:UsersTVTworkspaceCORRIDARTOSDemoFreeRTOSSourceportableGCCTriCore1782" -fno-common -Os -g3 -W -Wall -Wextra -Wdiv-by-zero -Warray-bounds -Wcast-align -Wignored-qualifiers -Wformat -Wformat-security -DTRIBOARDTC1782 -fshort-double -mcpu=tc1782 -mversion-info -MMD -MP -MF"RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.d" -MT"RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.d" -o "RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.o" "../RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.c" ../RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.c: In function 'pxPortInitialiseStack': ../RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.c:170:3: error: stray '$' in program pulLowerCSA = portCSATOADDRESS( mfcr( $FCX ) ); ^ In file included from C:UsersTVTworkspaceCORRIDARTOSDemoFreeRTOSSourceinclude/portable.h:94:0, from C:UsersTVTworkspaceCORRIDARTOSDemoFreeRTOSSourceinclude/FreeRTOS.h:104, from ../RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.c:81: ../RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.c:170:37: error: incompatible type for argument 1 of 'mfcr' pulLowerCSA = portCSATOADDRESS( mfcr( $FCX ) ); ^ C:UsersTVTworkspaceCORRIDARTOSDemoFreeRTOSSourceportableGCCTriCore1782/portmacro.h:142:62: note: in definition of macro 'portCSATOADDRESS' #define portCSATOADDRESS( pCSA ) ( ( uint32t * )( ( ( ( pCSA ) & 0x000F0000 ) << 12 ) | ( ( ( pCSA ) & 0x0000FFFF ) << 6 ) ) ) ^ In file included from ../RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.c:76:0: c:hightectoolchainstricorev4.9.1.0-infineon-1.1tricoreincludemachineintrinsics.h:111:10: note: expected 'unsigned int' but argument is of type 'FCXt' unsigned _mfcr (const unsigned __regaddr) ^ ../RTOSDemo/FreeRTOSSource/portable/GCC/TriCore1782/port.c:170:3: error: stray '$' in program pulLowerCSA = portCSATO_ADDRESS( _mfcr( $FCX ) ); ^ ~~~

Is it possible to use FreeRTOS with the latest HighTec Development Platform? If the answer is yes is there possibility to port FreeRTOS TC1782 Demo to this invironment?

Thanks in advance!

With best wishes, Theodore


FreeRTOS and HighTec Development Platform build problem

Posted by rtel on June 21, 2017

I'm sure it is possible, but it seems from your post there will be a bit of scratching and prodding to do so as the syntax the compiler wants seems to have changed.

You should be able to correct errors where just the type is wrong easily enough - perhaps there are some library files in the FreeRTOS project directory that need updating to their latest versions?

After that, faced with this sort of issue I would try a couple of things: first look for an application note that from Tasking that tells you how to move from one version to another, second look at assembly code and examples that come with the compiler to see what it is expecting, then copy that. If you are still stuck then you could try the documentation for the _mfcr macro to see what it says to do :o)


FreeRTOS and HighTec Development Platform build problem

Posted by pamdev on June 26, 2017

It's not easy to beleive that there is a reason to change the syntax of the register referencing though generally it's possible. Is there any source of information (reference, manual, examples, etc) to figure out the CPU register and system areas referencing for modern TriCore toolchain c compiler? I couldn't find any so far.


FreeRTOS and HighTec Development Platform build problem

Posted by rtel on June 26, 2017

L Is there any > source of information (reference, manual, examples, etc) to figure out > the CPU register and system areas referencing for modern TriCore > toolchain c compiler? I couldn't find any so far.

I'm sure there are but you are asking the wrong person - we provide support for FreeRTOS not the compilers (we use more than 18 compilers at the last count) so this question will have to be directed to the compiler vendor.


FreeRTOS and HighTec Development Platform build problem

Posted by pamdev on June 27, 2017

Perhaps I have found a solution in one of docs. The syntax didn't change but the macros did.

_mfcr( $FCX ) --> __MFCR( $FCX )

This way the code compiles normally.


FreeRTOS and HighTec Development Platform build problem

Posted by rtel on June 27, 2017

Great. Thanks for reporting back. Was that the only change that was necessary?


[ 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