Hello everyone,
I have a very simple setup with a main c file that includes the header of a second c file where the tasks are defined (hid_tasks.c).
In the main.c file, the tasks are created and I have the following includes:
FreeRTOS.h
tasks.h
queue.h
hid_Tasks.h
In the hid_tasks.c file, the tasks are defined and I have the following includes:
FreeRTOS.h
tasks.h
queue.h
hid_tasks.h
In the hid_tasks.h file, the tasks are simply declared.
The compiler is chucking out the following errors:
In file included from hid_tasks.c:20:0:
task.h:162:5: error: expected specifier-qualifier-list before ‘configRUN_TIME_COUNTER_TYPE’
task.h:1810:35: error: expected declaration specifiers or ‘…’ before ‘configRUN_TIME_COUNTER_TYPE’
task.h:1957:29: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘ulTaskGetIdleRunTimeCounter’
task.h:1958:29: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘ulTaskGetIdleRunTimePercent’
The errors seem to be pointing to the freeRTOS kernel task.c file.
If I remove the freeRTOS includes from the hid_tasks.c file the errors disappear but, I obviously get other errors because main.c can’t ‘see’ the hid_tasks.c file that cointains the tasks definition.
Has anyone encountered a similar issue?
I seems like a very basic issue to me but, after a few hours investigating, I can’t get my head around fixing it.
Any and all help is very much appreciated.
LuisMF