(Created page with "A '''timer''' is a device that increments or decrements a counter at a fixed frequency. Computer timers are often used to check against some set value; when the counte...") |
|||
Line 1: | Line 1: | ||
− | A '''timer''' is a device that increments or decrements a [[counter]] at a fixed [[frequency]]. Computer timers are often used to check against some set value; when the counter's value matches that value some specific action is taken. Most | + | A '''timer''' is a device that increments or decrements a [[counter]] at a fixed [[frequency]]. Computer timers are often used to check against some set value; when the counter's value matches that value some specific action is taken. Most systems typically have at least one hardware timer that's used to implement a larger set of software timers. |
+ | |||
+ | == Overview == | ||
+ | {{Empty section}} | ||
+ | |||
+ | === Hardware timers === | ||
+ | {{empty section}} | ||
+ | |||
+ | === Software timers === | ||
+ | {{empty section}} | ||
+ | |||
+ | == Alternatives == | ||
+ | {{Empty section}} | ||
+ | |||
+ | == API support == | ||
+ | {{main|List of timer APIs}} | ||
+ | |||
+ | Timers play a crucial rule in many applications for a variety of jobs such as periodical checking of information. Many [[programming languages]] provide easy ways of scheduling timer [[tasks]]. Most [[operating systems]] also offer a way of setting up timer tasks. For example, on [[POSIX]] systems one could setup an [[alarm - POSIX|alarm]] which would generate the [[SIGALRM]] [[POSIX signals|signal]] after a specified number of seconds. Likewise, on [[Windows]], the SetTimer [[Win32 API]] function can be used to call a [[callback]] function after a specific amount of time. | ||
+ | |||
+ | == See also == | ||
+ | * [[Sleep]] | ||
+ | * [[Counter]] | ||
+ | |||
[[Category:Counters]] | [[Category:Counters]] |
Revision as of 02:43, 10 April 2014
A timer is a device that increments or decrements a counter at a fixed frequency. Computer timers are often used to check against some set value; when the counter's value matches that value some specific action is taken. Most systems typically have at least one hardware timer that's used to implement a larger set of software timers.
Overview
This section is empty; you can help add the missing info by editing this page. |
Hardware timers
This section is empty; you can help add the missing info by editing this page. |
Software timers
This section is empty; you can help add the missing info by editing this page. |
Alternatives
This section is empty; you can help add the missing info by editing this page. |
API support
- Main article: List of timer APIs
Timers play a crucial rule in many applications for a variety of jobs such as periodical checking of information. Many programming languages provide easy ways of scheduling timer tasks. Most operating systems also offer a way of setting up timer tasks. For example, on POSIX systems one could setup an alarm which would generate the SIGALRM signal after a specified number of seconds. Likewise, on Windows, the SetTimer Win32 API function can be used to call a callback function after a specific amount of time.