
Data Structures | |
| struct | MICRO |
Macros | |
| #define | current_msec() current_time() |
Typedefs | |
| typedef enum _EL_CLOCK_BASE | EL_CLOCK_BASE |
| Enum used to configure the behaviour of the time functions. | |
Enumerations | |
| enum | _EL_CLOCK_BASE { SR_CLOCK_BASE_APPLICATION_LOCAL =0, SR_CLOCK_BASE_MACHINE_LOCAL =1 } |
| Enum used to configure the behaviour of the time functions. More... | |
Functions | |
| void | eyelink_set_clock_base (EL_CLOCK_BASE clock_base) |
| EL_CLOCK_BASE | eyelink_get_clock_base (void) |
| UINT32 | current_time (void) |
| UINT32 | current_micro (MICRO FARTYPE *m) |
| UINT32 | current_usec (void) |
| void | msec_delay (UINT32 n) |
| double | current_double_usec (void) |
| INT16 | eyelink_reset_clock (INT16 enable) |
These functions are used to access display time
| #define current_msec | ( | ) | current_time() |
See current_time()
| enum _EL_CLOCK_BASE |
Enum used to configure the behaviour of the time functions.
| double current_double_usec | ( | void | ) |
Returns the current microsecond as double (56 bits) since the initialization. Equivalent to current_micro() and current_usec().
Example: See current_usec()
\sa \c current_micro(), \c current_usec(), \c current_msec(), \c current_time() and \c msec_delay()
Returns the current microsecond since the initialization. Equivalent to current_usec() and current_double_usec().
| m | Pointer to MICRO structure. |
MICRO structure if the pointer is not NULL.Example: See current_usec()
current_usec(), current_double_usec(), current_msec(), current_time() and msec_delay() | UINT32 current_time | ( | void | ) |
Returns the current millisecond since the initialization.
close_eyelink_system() is called at the end. The call to current_msec() is always equivalent to current_time(). Example:
Output:
| UINT32 current_usec | ( | void | ) |
Returns the current microsecond since the initialization. Equivalent to current_micro() and current_double_usec().
current_usec() is equivalent to current_micro(NULL). The function is very platform dependent. Platforms such as windows 95, 98, ME may not return usec properly. Ie. It may return current_time() * 1000. Example:
Output:
current_micro(), current_double_usec(), current_msec(), current_time() and msec_delay() | EL_CLOCK_BASE eyelink_get_clock_base | ( | void | ) |
Returns the clock base for the local time access.
Initializes the high frequency clock.
With TSR interface under msdos, Start/stop timing resources.
| enable | Usually <enable> is 1. However, in MS-DOS passing 0 will cleanup the timing resources. In other platforms passing 0 has no effect. |
| void eyelink_set_clock_base | ( | EL_CLOCK_BASE | clock_base | ) |
Sets the clock base for the local time access. This changes the behaviour of the time functions.
eg.
Output:
Now look at the difference in the output where the first call to current_double_usec() returns much smaller value when the time base is SR_CLOCK_BASE_APPLICATION_LOCAL
Output:
open_eyelink_connection().Example:
Output: when executing multiple instance of the above program
| void msec_delay | ( | UINT32 | n | ) |
Does a unblocked delay using current_time().
| n | n milliseconds to delay. |
Example:
Output:
current_msec() and pump_delay()