Skip to main content

ticks

Function ticks 

Source
pub fn ticks(ctx: &ServiceContext) -> u64
Expand description

The counter itself, in its own units.

For code that MEASURES in counter ticks rather than waits on them: a benchmark that reports cycles, or a domain library that takes a timestamp (the SDK’s key repeat, godspeed_sdk::hid::KeyRepeat). A wait is never written on this. A loop that compares two of these against a hand-converted budget is the copy Deadline exists to replace, and it disagrees with it on exactly the machine that matters - one whose clock is uncalibrated, where this still counts but ticks_per_10ms is 0.