cancel
Showing results for 
Search instead for 
Did you mean: 

TouchGFX: Error using FreeRTOS Events

berkerdemoglu
Visitor

Task Description:

I'm trying to update a text on the screen when a button is pressed. I want to achieve this using the event functionality in FreeRTOS.

The control flow is more or less like this:
Button pressed -> External Interrupt -> Callback function sets event flag -> Task waiting on the event flag 'wakes up', sends a message to the GUI using a message queue. -> Model::tick() polls queue and sees message -> Model updates its state, notifies Listener -> Listener notifies view to update the text -> View prints new text, invalidates text area to be redrawn

Problem
TouchGFX/build/STM32H7B3I_DISCO/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS_V2/cmsis_os2.o: In function `osEventFlagsNew':
d:\tum\tufast\learning\FSMDemoNew/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS_V2/cmsis_os2.c:1135: undefined reference to `xEventGroupCreateStatic'
d:\tum\tufast\learning\FSMDemoNew/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS_V2/cmsis_os2.c:1141: undefined reference to `xEventGroupCreate'
TouchGFX/build/STM32H7B3I_DISCO/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS_V2/cmsis_os2.o: In function `osEventFlagsWait':
d:\tum\tufast\learning\FSMDemoNew/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS_V2/cmsis_os2.c:1249: undefined reference to `xEventGroupWaitBits'
collect2.exe: error: ld returned 1 exit status
make[2]: *** [TouchGFX/build/bin/target.elf] Error 1
gcc/Makefile:346: recipe for target 'TouchGFX/build/bin/target.elf' failed
gcc/Makefile:342: recipe for target 'generate_assets' failed
make[1]: *** [generate_assets] Error 2
../gcc/Makefile:52: recipe for target 'all' failed
make: *** [all] Error 2
Failed

My problem is the code generation and the includes. First of all, I get another error in the Stm32CubeIDE which may be relevant: Invalid project path:
Invalid project path: Include path not found (D:\tum\tufast\learning\FSMDemo\Middlewares\Third_Party\FreeRTOS\Source\CMSIS_RTOS). FSMDemo pathentry Path Entry Problem
This path actually does not exist, so no wonder I get an error notification. This may be a migration error (from CMSIS V1 to CMSIS V2).
When I CTRL-click on the functions in STM32CubeIDE, I find the definitions for xEvent...() functions. This means that they should be in the include path, but I don't understand why the compiler cannot find them.

Board and Version Info:
I have STM32H7B3I-DK and I generated a TouchGFX project for this board using TouchGFXDesigner 4.24.2 (latest one). The STM32CubeIDE version is 1.17.0 (latest one). Stm32CubeMX downloaded on my PC (I think it's irrelevant?) is version 6.12.1

Possible Solution?
I actually saw another post on the forum from a few days ago that also had this problem, but the solution suggested there does not apply to mine (different boards could be the reason I believe).

Thanks in advance!

0 REPLIES 0