Quality RTOS & Embedded Software

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


Loading

Porting FreeRTOS to Renesas RL78F14R5F10pgj

Posted by chris-itk on September 29, 2014

Hi everybody, i've got some problems with porting the freertos demo project to a RL78F14 (RL78F14R5F10pgj) controller. I'm using the iar compiler. I can build the existing demo projects (as provided by freertos v8.1.2 for the rl78 controllers) without any error. But if I include the necesarry register definitions (ior5f10pgj.h, ior5f10pgjext.t) for my controller in FreeRTOSConfig.h, I get a compiler error about some undefined symbols. See the logfile extract below. Does anybody know about this problem, or how to fix it? I would be very glad if you could help me.

Regards Chris

/****************************************************************************************************/ port.c iccrl78.exe C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSportableIARRL78port.c --core rl782 --codemodel near --datamodel near --nearconstlocation rom0 -o C:Usersckurz.ITKDesktopRL78DemoRL78DemoDebugObj --dlibconfig C:Program Files (x86)IAR SystemsEmbedded Workbench 7.0rl78LIBdlrl78nn2n.h -e -Ol --nocse --nounroll --noinline --nocodemotion --notbaa --nocrosscall --noscheduling --noclustering --debug -I C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOS -I C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSportableIARRL78 -I C:Usersckurz.ITKDesktopRL78DemoRL78Demouser_srcFreeRTOSinclude

IAR C/C++ Compiler V1.40.3.898 for RL78 Copyright 2011-2014 IAR Systems AB. Evaluation license - IAR Embedded Workbench for Renesas RL78, Evaluation version 1.40 C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSportableIARRL78port.c(279) : Error[Pe020]: identifier "ITMK" is undefined C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSportableIARRL78port.c(282) : Error[Pe020]: identifier "ITMC" is undefined C:Usersckurz.ITKDesktopRL78DemoRL78Demouser_srcFreeRTOSportableIARRL78port.c(285) : Error[Pe020]: identifier "ITIF" is undefined

Errors: 3 Warnings: none Error while running C/C++ Compiler

portasm.s87 arl78.exe C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSportableIARRL78portasm.s87 --core rl782 -DDEVICE_FILE= -DDEVICEFILEEXT= -o C:Usersckurz.ITKDesktopRL78DemoRL78DemoDebugObj -M<> -r -I C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOS -I C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSportableIARRL78 -I C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSinclude -D__NEARMODEL__ -DNEARDATAMODEL --codemodel near --datamodel near

IAR Assembler V1.40.3.898 for RL78 Copyright 2011-2014 IAR Systems AB. C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSportableIARRL78portasm.s87(102) : Error[As014]: Expression can not be forward C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSportableIARRL78portasm.s87(102) : Error[As014]: Expression can not be forward C:Usersckurz.ITKDesktopRL78DemoRL78DemousersrcFreeRTOSportableIARRL78portasm.s87(102) : Error[As011]: Undefined symbol: INTITvect C:Usersckurz.ITKDesktopRL78DemoRL78Demouser_srcFreeRTOSportableIARRL78portasm.s87(102) : Error[As014]: Expression can not be forward

Errors: 4 Warnings: none Error while running Assembler

Total number of errors: 7 Total number of warnings: 0

/****************************************************************************************************/


Porting FreeRTOS to Renesas RL78F14R5F10pgj

Posted by rtel on September 29, 2014

I think the second set of errors are related to the first.

That demo has configurations for multiple different RL78 families. To switch between the families you have to select the correct build configuration in IAR (done using the drop down box at the top of the workspace window, just above where the files are listed). Selecting a build configuration will ensure the correct device is selected in the IAR project options (General Options, target tab), and define a pre-processor constant. The pre-processor constant is then used to select the correct header files for the selected device, but:

But if I include the necesarry register definitions (ior5f10pgj.h, ior5f10pgjext.t) for my controller in FreeRTOSConfig.h

the header files are included in demospecificio.h, not FreeRTOSConfig.h. I don't think you need to edit FreeRTOSConfig.h.

Have you selected the correct target in the project options (the FreeRTOS download does not include a build configuration for the RL78f14) and ensured there are no pre-processor constants defined in the project (C/C++ Compiler, preprocessor tab in the project options dialogue box)?

Regards.


Porting FreeRTOS to Renesas RL78F14R5F10pgj

Posted by chris-itk on September 29, 2014

Hi, thanks for your quick answer.

"To switch between the families you have to select the correct build configuration in IAR (done using the drop down box at the top of the workspace window, just above where the files are listed). "

Yes, I know that. And it does work for the available targets. But the controller I'm using isn't provided by any of your demos. So I thougt about creating my own demo for the RL78F14. As you write on http://www.freertos.org/a00090.html#RENESAS: "These demos can be adapted to any microcontroller within the same family that has sufficient ROM/RAM." This applies to the RL78F14 in my oppinion, or am I wrong?

Regards Christian


Porting FreeRTOS to Renesas RL78F14R5F10pgj

Posted by rtel on September 29, 2014

[sorry if this post appears twice]

The port is using an interval timer to generate the tick interrupt. In the build configurations included in the FreeRTOS download, the definitions for ITMC come from the ior_nnn.h header file, but the ior5f10pgj.h file for your part does not contain that definition.

Looking at the block diagram for that part here, the timers block does not show an interval timer: http://www.renesas.com/products/mpumcu/rl78/rl78f1x/rl78f14/index.jsp

whereas the block diagram for other RL78 families does show an interval timer. For example the block diagram on the following page: http://www.renesas.com/products/mpumcu/rl78/rl78g1x/rl78g14/index.jsp

So it does indeed look like you are going to have to change the port.c file so that it generates its tick interrupt from a different timer peripheral.

Regards.


Porting FreeRTOS to Renesas RL78F14R5F10pgj

Posted by chris-itk on September 29, 2014

Thank your very much for your answer. I also thought on doing that. Regards


[ 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