in order to measure a buttons hold time you need to either note time button was pressed then the time button was released
the duration is release time - when pressed time, or when button is pressed start a timer and then stop it when button released
you are not doing either of these things
you never start timer1, you never note when the button is released
Bookmarks