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

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 ]    [ 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