cancel
Showing results for 
Search instead for 
Did you mean: 

TouchGFX: CubeIDE Compiler Error when New Screen Added via TouchGFX Designer

KMew
Senior III

Hello,

I generated code from the TouchGFX Designer 4.20.0 application, then added custom code afterwards to do the functions I required. I compile the code via the CubeIDE (NOT the TouchGFX Designer compiler) and it works without issue. All functions are working.

After this, I decided to add a new screen via the TouchGFX Designer. It's a simple start-up screen that just shows our company logo then transitions to the previous screen that I was working with. When I do that and hit the "Run Target" (to compile and run the code with the new screen), it works without issue. Both screens are there, my custom code that I put in the IDE still worked.

However, if I then jump to the IDE and try to compile/run it via the IDE, I get a compiler error that "Screen2View" does not exist. Specifically:

"undefined reference to `Screen2View::Screen2View()"

0693W00000WHTniQAH.png 

I'm unsure what the difference is. Can anyone help explain what's happening?

5 REPLIES 5
MM..1
Chief III

Try in IDE right mouse click on project and choice Refresh ...

I did try this. Same issue occurred.

Then yourr project was created in TouchGFX and then imported into IDE and you found next bug ...

Projects created in IDE dont have this issue, and too dont have Run Target button active.

Sorry, I'm not sure what you mean, but I'll try to answer.

  1. I created my project in TouchGFX Designer.
  2. Once generated, I went into CubeIDE and made changes to my code. That worked without any issue at all. It compiled as intended.
  3. After I made the modifications, my boss asked me to add a second screen. So I made that 2nd screen in TouchGFX.
  4. I hit "Generate Code" in the TouchGFX Designer and there's no issues.
  5. I then returned to my CubeIDE and compiled it again to see the second screen and I got the compiler error with the error shown in the original post
  6. Trying to debug it, I hit "Run Target" in the TouchGFX with the new screen. That compiled with no issues and it ran on the LCD display, with the new screen working as intended.

I hope this clarifies what my issue is.

Yes all clean, but normal steps for custom board and project is

  1. Create new project in IDE or MX and add touchgfx software package
  2. Once generated code open touchgfx part file

And for solve your issue simply solve missing or problem in IDE config, For example your error say in MVP... try add include screen2.hpp ... Or show how you change startus screen ...