Single Double Click and Long Press Detection

Solving Approach

How do you plan to solve it?

 I've connected pin 1A(pin 2) and 2B(Ground) to the Arduino UNO board. While we are taking specific time periods to recognise each press. If single click, then a cartain time is considered, if double click that has to be in  a certain time, the long press has to happen for specific time. This will make us realize, which is being pressed. Therefore, through loop, we can recognize which press is being happened.
 

 

 

 

Code

/*Paste your code here*/

 

 

 

Output

Video

Add a video of the output (know more)

 

 

 

 

Upvote
Downvote

Submit Your Solution

Note: Once submitted, your solution goes public, helping others learn from your approach!