Any tips?
1 - post your complete program or a short but complete program that illustrates the problem
2 - increment the variable when the button becomes pressed rather than when it is pressed. Look at the StateChangeDetection example in the IDE
Any tips?
1 - post your complete program or a short but complete program that illustrates the problem
2 - increment the variable when the button becomes pressed rather than when it is pressed. Look at the StateChangeDetection example in the IDE