Duplicate button events


#1

I have a piston that sends a slack message when a ST button is pressed. This piston was working perfectly for many months until recently, when I added another if statement to check the button temperature daily.

The piston should send one slack message per button press. However, something has changed so that it sends 3 slack messages per press. The webcore logs show three button events during each physical press. The ST IDE shows one button event per physical press. How can I troubleshoot this?

Capture