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


Submitting Modifications

Posted by Richard Damon on October 28, 2007
What is the procedure for submitting ideas/code for minor updates?

I am using FreeRTOS in a project using C++ and to get it to compile as a C routine, I need to add

#ifdef __cplusplus
extern "C" {


#ifdef __cplusplus

bracketing the definitions in include files.

In addition I change a few of the opaque type from

typedef void * xQueueHandle


typedef struct QueueDefinition * xQueueHandle;

which gets around some warnings on inconsistent types, while still keeping the definition opaque (since the struct definition is still not visable).

I would think these are reasonable changes to make in the code base for a future release.

RE: Submitting Modifications

Posted by Richard on October 29, 2007
Hi Richard,

Thanks for your suggestions.

With reference to the 'extern "C"' inclusion. I will add this into the next release (due in a couple of weeks or so). Could you send me your modified files so I get their positioning correct - I think they just need to be placed at the top and bottom of the header files but as I don't have any C++ projects setup I cannot test this. Please send the files to r _dot_ barry (at) freertos.org.

With reference to the void * used for the queue and task handles. You are right - this is a pain. Unfortunately it has to be done this way because it is the only method I have found that will happily go through all the various compilers that FreeRTOS.org is built with. The method suggested by yourself breaks the build with at least one compiler - from memory I think this is the C18 compiler from Microchip.

Thanks and regards.

[ 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