API Reference Manual
1.46.0
|
Periodic timer start parameters. More...
#include <timer_types.h>
Data Fields | |
uint64_t | first_tick |
First expiration time. More... | |
uint64_t | freq_multiplier |
Base frequency multiplier. More... | |
odp_event_t | tmo_ev |
Timeout event. More... | |
Periodic timer start parameters.
A periodic timer pool can be thought as a wall clock, where the base frequency (odp_timer_pool_param_t::base_freq_hz) defines how many times per second a pointer travels around the clock face. When a timer (see "Timer A" in the figure) is started with the base frequency multiplier (odp_timer_periodic_start_t::freq_multiplier) of one, a single reference to it is placed into the clock face. When a timer (see "Timer B") is started with the multiplier value of two, two references to it is placed into opposite sides of the clock face, etc. When the pointer reaches a timer reference, the timer expires and a timeout event is sent to the destination queue. The maximum base frequency multiplier (odp_timer_pool_param_t::max_multiplier) defines the maximum number of references a timer can have on the clock face. The first expiration time parameter (odp_timer_periodic_start_t::first_tick) is used to tune timer reference placement on the clock face against the current time (the current pointer location).
Definition at line 465 of file api/spec/timer_types.h.
uint64_t odp_timer_periodic_start_t::first_tick |
First expiration time.
The first expiration time in absolute timer ticks. When zero, the first expiration time is one period after the current time, or as close to that as the implementation can achieve. After the first expiration, timer expiration continues with the defined frequency. The tick value must be less than one timer period after the current time.
Definition at line 473 of file api/spec/timer_types.h.
uint64_t odp_timer_periodic_start_t::freq_multiplier |
Base frequency multiplier.
Periodic timer expiration frequency is defined as a multiple of the timer pool base frequency: timer frequency (Hz) = base_freq_hz * freq_multiplier. Valid values range from 1 to timer pool parameter 'max_multiplier'.
Depending on the implementation, a multiplier value that is a divisor of 'max_multiplier' may improve timer expiration accuracy: max_multiplier = k * freq_multiplier, where k is an integer.
Definition at line 485 of file api/spec/timer_types.h.
odp_event_t odp_timer_periodic_start_t::tmo_ev |
Timeout event.
This event is enqueued to the destination queue when the timer expires. The event type must be ODP_EVENT_TIMEOUT.
Definition at line 492 of file api/spec/timer_types.h.