cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F746G-DISCO, STM32CubeIDE, GFX INTERACTIONS

ADębs.1
Senior

Hi

I have two screens A and B.

On A ButtonSTART (Toggle).

On B ButtonSTOP (Toggle).

ButtonSTART is to change to screen B and turn on the counter.

ButtonSTOP is to change to screen A and stop the counter.

After changing screen A to B, ButtonSTART should be 0.

After changing screen B to A, ButtonSTOP should be 0.

How to set up GFX INTERACTION?

greetings

Andrzej

1 ACCEPTED SOLUTION

Accepted Solutions

Not sure I get what you are trying to do. but you could set the "buttons" to 0 when you start the animation from a screen to another. You could do it through TouchGFX Designer in the Interactions tab by using the trigger "Screen Transition begins".

/Romain

View solution in original post

6 REPLIES 6
Romain DIELEMAN
ST Employee

Hi,

You could set the counter to 0 in the <nameOfScreen>View.cpp in the <nameOfScreen>::setupScreen function.

/Romain

ADębs.1
Senior

Hi

I am not talking about the operation on the counter but about setting the buttons to 0 after changing the screen.

greetings

Andrzej

What do you mean by settings the buttons to 0 if it is not the counter ?

ADębs.1
Senior

Yes. stop = 0

Not sure I get what you are trying to do. but you could set the "buttons" to 0 when you start the animation from a screen to another. You could do it through TouchGFX Designer in the Interactions tab by using the trigger "Screen Transition begins".

/Romain

ADębs.1
Senior

Hi

I wrote a test program:

1.Press START

1.1 send button state to main.c

1.2 change screen

1.3 start htm3

2.Press STOP

2.1 sending button state to main.c

2.2 screen change 2.3 stop htm3

2.4 I set start = 0 in main.c

2.5 I set the counted pulses total_current = 0 in main.c

3.Press START I want him to change screen and count again.

How to do it?

Andrzej