Skip to main content
SimonF
Senior
November 9, 2020
Solved

Bug : Clock widgets do not work with STM32G071 application template [TouchGFX 4.15.0]

  • November 9, 2020
  • 8 replies
  • 4906 views

Hello !

With my TouchGFX designer, the digital widget and the analog clock widget do not work with the STM32G071 application template (at least with the simulator, I can not confirm with the board).

When I say it does not work I mean it is well displayed but the value (or animation) is never updated. The widget is frozen to the original value.

This topic has been closed for replies.
Best answer by Alexandre RENOUX

Hello,

If it's your simulator that is not working correctly then there is nothing related to the G0 board.

Please have a look at the Clock Example UI available in TouchGFX Designer and use it as a reference.

The clock widget will not work by itself. You need to implement handleTickEvent() and change the seconds, minutes accordingly.

When your question is answered, please close this topic by choosing Select as Best.

/Alexandre

8 replies

MM..1
Chief III
November 9, 2020

Can you share your screenview.cpp file?

Alexandre RENOUX
Alexandre RENOUXBest answer
Visitor II
November 10, 2020

Hello,

If it's your simulator that is not working correctly then there is nothing related to the G0 board.

Please have a look at the Clock Example UI available in TouchGFX Designer and use it as a reference.

The clock widget will not work by itself. You need to implement handleTickEvent() and change the seconds, minutes accordingly.

When your question is answered, please close this topic by choosing Select as Best.

/Alexandre

SimonF
SimonFAuthor
Senior
November 10, 2020

Thank you for your help. Indeed, it is not related to the G0 board

As @Alexandre RENOUX​ said, I need to implement my own handler for that (I thought it was automatic when adding this widget because of the default Clock example ^^')

You are right @MM..1​ , this can be implemented in screenview.cpp by adding handleTickEvent(). (an example can be found with the Clock example template in mainView.cpp file)

ALomb.1
Associate III
March 12, 2021

Hello @SimonF​ ,

Analog Clock work fine on the target ?

I have your same hardware (I believe NUCLEO-G071 and X-NUCLEO-GFX01M1).

On the simulator everything is ok.

On the target the digital clock is ok, but the hands of the analog clock are not displayed. Only the clock_background is displayed.

The code is identical to the clock example of Designer.

Alexandre RENOUX
Visitor II
March 15, 2021

Hello @Community member​ ,

Analog Clock utilizes texture mappers for the hands.

But the G0 Application template disables the texture mapper by default for several reasons :

  • Reduces the memory footprint of TouchGFX lib (important with G0 since you have such a small amount)
  • Texture mappers are heavy load widgets that are not meant for low cost solutions (you combine both partial framebuffer and low performance MCU).

You can try re-enabling the texture mapper feature by opening your project in the Designer go to Config -> Framework Features

When enabled, you should see the following :

0693W000008ws4AQAQ.png/Alexandre

ALomb.1
Associate III
March 15, 2021

Hello @Alexandre RENOUX​,

I have enabled the texture mapper. Flash occupancy increased by 50% (from 64k to around 96K) !!

However, the hands are not displayed.

I'm definitely not going to use widgets that require texture mapper on this hardware, but I wanted to point this out.

/Antonello

Alexandre RENOUX
Visitor II
March 15, 2021

Hello ALomb.1,

Please do the following :

  • Enable Texture Mapper features (already done for you)
  • Put the hands images into internal Flash and force them to be ARGB8888 (next step to do)

0693W000008wtPiQAI.pngWhen your question is answered, please close this topic by choosing Select as Best.

/Alexandre

Associate III
February 20, 2024

Thank you. I applied these setting and problem is solved for me. :thumbs_up::folded_hands:

SimonF
SimonFAuthor
Senior
March 15, 2021

Hello @Community member​ ,

First, in my experience, you should open a new ticket to have more visibility.

Then, I can confirm I have the same issue. I have even try to enable all Framework Features (in "Config").

I'm using 4.16.1 version. You should try an older one if you are using the same. And create a new ticket because this can be a bug with this specific hardware.

Simon

ALomb.1
Associate III
March 15, 2021

Hello @Alexandre RENOUX​ ,

putting the hands images into internal Flash and force them to be ARGB8888 solve the problem.

I only tried with the second hand (not much free space in the internal flash).

I can not choose "Select as Best", because I believe I did not open this ticket, but @SimonF​ .

He could do it.

Thank you

/Antonello

SimonF
SimonFAuthor
Senior
March 15, 2021

Hello @Community member​ ,

I cannot select this reply as the best because it is was not my issue.

That's why you should have create a new post.

Anyway, this behaviour should be specified by ST I think because the solution is not obvious.

Simon

Romain DIELEMAN
ST Employee
March 15, 2021

Hi,

I agree and we plan on documenting that. It is specific to the G0, and we wish to further optimize the TouchGFX footprint in order to have more space to store images in internal flash.

/Romain