Quality RTOS & Embedded Software

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


Loading

Task name missing

Posted by Juan_Pablo Garcia_Martinez on January 7, 2009
Enviroment MPLAB 8.15a
Compiler C18 V3.21

I'm new with FreeRTOS and I'm interested in PIC 18 HW. So I tried with MCC18 and PIC 18F452 port.
I have noticed task name is missing in tskTCB.

File taks.c line 1674. strncpy do not copies from rom to ram, so replacing by strncpypgm2ram it works. Have anyone detected this behaviour?.

JP.

RE: Task name missing

Posted by PICmeup on January 8, 2009
You can set the length to 1 in the freertosconfig file to save space as it is not useful.

RE: Task name missing

Posted by Juan_Pablo Garcia_Martinez on January 8, 2009
You're right, but task name is useful for debugging process. So this feture is interesting to make work.

I don't know if old C18 worked OK with strncpy and latest verssion do not or it was a "mistake" from the begining. In such case it would be good idea to modify the source code to solve this problem with C18 compiler.

I have noticed some other "mistakes" like this. I wanted to check if anyone has detected them and if were detected yet, is there a reason to maintain them?. I'm surprised.

RE: Task name missing

Posted by mike on January 12, 2009
Hello JG
You are quite right that the earlier version of the compiler did not correctly identify mistakes in parameter types of this sort, and one version checked them, but got it wrong!
If a parameter refers to ROM space (const rom), the version strncpypgm2ram must be used so the correct memory space is accessed. As you have noticed the incorrect call may not be detected, and the resulting code will not work!
A final gotcha is that the default memory model for the project is small code, while the libraries are compiled with large code model which can alos cause problems.

I have developed code for the PIC18 quite extensively, but so far have only used FreeRTOS with ARM chips (so far).


[ 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