cancel
Showing results for 
Search instead for 
Did you mean: 

TouchGFX 4.13.0 project with CMSISv2 ??

Aplou.1
Associate III

Hello everyone,

I am currently working on a project with touchGFX (4.13.0) and I want to use CMSISv2 functions and calls. Since the default configuration from touchGFX is CMSISv1, I open the cubeMX project created by touchGFX and changed the CMSIS version in the FreeRTOS config menu. I generated files from cubeMX, then generated files from touchGFX. And when I "Run Target" I get this error :

Run Target
    Generate
        Done
    Generate Assets
        make -f simulator/gcc/Makefile assets -j8
        Done
    Post Generate
        touchgfx update_project --project-file=simulator/msvs/Application.vcxproj
        Done
    Post Generate Target
        touchgfx update_project --project-file=../STM32F7508-DK.ioc --platform=m7
        Done
    Compile
        make -f ../gcc/Makefile -j8
        Generating TouchGFX/generated/texts/src/Texts.cpp
        Generating TouchGFX/generated/texts/src/LanguageGb.cpp
        Compiling TouchGFX/generated/fonts/src/Font_verdana_40_4bpp_0.cpp
        Compiling TouchGFX/generated/fonts/src/Kerning_verdana_40_4bpp.cpp
        Compiling TouchGFX/generated/fonts/src/Kerning_verdana_20_4bpp.cpp
        Compiling TouchGFX/generated/fonts/src/Kerning_verdana_10_4bpp.cpp
        Compiling TouchGFX/generated/fonts/src/Table_verdana_10_4bpp.cpp
        Compiling TouchGFX/generated/fonts/src/Table_verdana_40_4bpp.cpp
        Compiling TouchGFX/generated/fonts/src/Font_verdana_20_4bpp_0.cpp
        Compiling TouchGFX/generated/fonts/src/Font_verdana_10_4bpp_0.cpp
        Compiling TouchGFX/generated/fonts/src/Table_verdana_20_4bpp.cpp
        Compiling TouchGFX/generated/texts/src/LanguageGb.cpp
        Compiling TouchGFX/generated/texts/src/Texts.cpp
        Compiling TouchGFX/target/generated/TouchGFXGeneratedHAL.cpp
        Compiling TouchGFX/target/generated/STM32DMA.cpp
        Compiling TouchGFX/target/generated/TouchGFXConfiguration.cpp
        Compiling TouchGFX/target/TouchGFXHAL.cpp
        Compiling TouchGFX/target/generated/OSWrappers.cpp
        TouchGFX/target/generated/OSWrappers.cpp:21:10: fatal error: cmsis_os2.h: No such file or directory
         #include <cmsis_os2.h>
                  ^~~~~~~~~~~~~
        compilation terminated.
        gcc/Makefile:327: recipe for target 'TouchGFX/build/STM32F7508-DK/TouchGFX/target/generated/OSWrappers.o' failed
        make[2]: *** [TouchGFX/build/STM32F7508-DK/TouchGFX/target/generated/OSWrappers.o] Error 1
        make[2]: *** Waiting for unfinished jobs....
        Compiling TouchGFX/target/TouchGFXGPIO.cpp
        make[1]: *** [generate_assets] Error 2
        gcc/Makefile:294: recipe for target 'generate_assets' failed
        ../gcc/Makefile:47: recipe for target 'all' failed
        make: *** [all] Error 2
        Failed
    Failed

So when touchGFX compiles, it does not find CMSISv2 files. I tried messing around with some includes or paths but I could not come up with something useful...

I appreciate any help you could give me!

Thanks in advance!

Alex

1 ACCEPTED SOLUTION

Accepted Solutions
Aplou.1
Associate III

Hello,

I was able to fix my issues, turns out that the main problem was that the make file was note correctly generated (had to changed CMSISv1 refference to CMSISv2). The rest were some coding errors on my part.

Some thing strange tho, I had a screen with a big image (bigger resolution than the screen I am displaying on) that work perfectly on CMSISv1. When I switched to CMSISv2, the image display operation crashed the TouchGFX thread... I don't know why. The fix was simply to reduce the resolution of the image to match the screen.

Thank you for all the help!!

Alex

View solution in original post

11 REPLIES 11
VBurs
Associate II

I got the same issue...can someone help?

Aplou.1
Associate III

Okay so i figured that the makefile has some hardcoded paths to CMSIS in line 93 and 97. But it is still not working... What am I missing ?

Hi,

Which board and application template version are you using? The default configuration is not always CMSIS v1, as we have updated most of the ATs to CMSIS v2.

/Romain

Hi Romain,

Thank You for your response !

This is the application template I chose :

0693W000003Ocq0QAC.png

Alex

Alexandre RENOUX
Principal

Hello,

Can you try deleting your Middlewares/ folder, regenerate with CubeMX and then with TouchGFX Designer ?

This is to make sure that CubeMX will generate it correctly. If it does not solve the issue even if the CMSIS_RTOS_V2 folder is generated, then look again to the include paths.

Also, if you changed the CMSIS version in the FreeRTOS config menu, make sure it is also changed in the TouchGFX Generator config menu.

/Alexandre

Hello Alexandre,

I have deleted and regenerated like you recomended, but my problem persists... I can compile and flash but I get a black screen on my devboard (Before the change it worked).

As per the touchGFX config menu, I am not sure what menu you are talking about, is this the one ?

0693W000003Oe8eQAC.png

Thank You ,

Alex

Aplou.1
Associate III

!!Update!!

I was able to compile and flash my code to my dev board, now the proble is that I have a black screen on boot... But I created a task to print a message on the serial port and I get the message on my computer trough USB. So freeRTOS is running and the task is running, So there is a problem with starting the touchGFX task...

Also I tried to set a different page as a startup screen, and it worked !! the bad news is that is means that first page has a problem of some sort. Since I there is a big image on that screen I assume it could be a problem with the RAM size of stack size ?

Thanks A Lot!

Alex

Hello,

No the compilation problem has been resolved and now you have another problem 🙂

At least you are one step further now.

Yes I was talking about this config menu.

We noticed sometimes that CMSIS v2 does not work on some board but v1 works and vice versa. This is also probably why we haven't changed to v2 for this board.

Also, æake sure that the FreeRTOS v2 is well configured: For instance, your touchgfx task need a certain size to work correctly. Please have a look at the CubeMX config of the L4R9-Disco Application Template that uses CMSIS v2 for reference.

/Alexandre

Hi,

I got CMSISv2 working, but as mentioned earlier, I have a problem with the applicaiton not starting when entering a page with a big image... Can this be a Stack or ram issue ?