Button.Time R/O Property

Top  Previous  Next

Function:

Returns the time (in 0.5 second intervals) elapsed since the button was last pressed or released (whichever happened) later.

Type:

Byte

Value Range:

0-255

See Also:

---

 


Details

It only makes sense to read this property inside the on_button_pressed or on_button_released event handlers. Once the value of this property reaches 255 (127 seconds) it stays at 255 (there is no roll-over to 0). Elapsed time is not counted when the execution of your application is paused.