/Zephyr-Core-3.6.0/kernel/ |
D | timeout.c | 65 * scheduled relatively to the currently firing timeout's original tick in elapsed() 216 * timeouts and confuse apps), just increment the tick count in sys_clock_announce() 297 timepoint.tick = UINT64_MAX; in sys_timepoint_calc() 299 timepoint.tick = 0; in sys_timepoint_calc() 304 timepoint.tick = Z_TICK_ABS(dt); in sys_timepoint_calc() 306 timepoint.tick = sys_clock_tick_get() + MAX(1, dt); in sys_timepoint_calc() 317 if (timepoint.tick == UINT64_MAX) { in sys_timepoint_timeout() 320 if (timepoint.tick == 0) { in sys_timepoint_timeout() 325 remaining = (timepoint.tick > now) ? (timepoint.tick - now) : 0; in sys_timepoint_timeout() 330 void z_impl_sys_clock_tick_set(uint64_t tick) in z_impl_sys_clock_tick_set() argument [all …]
|
/Zephyr-Core-3.6.0/dts/bindings/timer/ |
D | st,stm32-lptim.yaml | 30 and consequently higher core sleep durations, but impacts the tick precision. 32 CONFIG_SYS_CLOCK_TICKS_PER_SEC could be used to tune tick duration and gain precision, 37 Using CONFIG_SYS_CLOCK_TICKS_PER_SEC = 4096, tick = 0.24 ms, LPTIM precision is 4 ticks. 38 Using CONFIG_SYS_CLOCK_TICKS_PER_SEC = 1024, tick = 0.97 ms, LPTIM precision is 1 ticks.
|
/Zephyr-Core-3.6.0/tests/boards/native_sim/cpu_wait/src/ |
D | main.c | 62 #error "This test will not work with this system tick period" 88 /* Sleep until next tick in thread_entry() 90 * be given just after the previous tick boundary in thread_entry() 105 * For native_posix it works, with a tick of 10ms. In general this test will 106 * probably give problems if the tick time is not a relatively even number 115 k_sleep(Z_TIMEOUT_TICKS(1)); /* Wait until tick boundary */ in ZTEST() 134 k_sleep(Z_TIMEOUT_TICKS(1)); /* Wait until tick boundary */ in ZTEST() 154 k_sleep(Z_TIMEOUT_TICKS(1)); /* Wait until tick boundary */ in ZTEST() 172 k_sleep(Z_TIMEOUT_TICKS(1)); /* Wait until tick boundary */ in ZTEST() 194 * Replacement system tick timer interrupt handler which wastes time [all …]
|
/Zephyr-Core-3.6.0/include/zephyr/drivers/timer/ |
D | system_timer.h | 38 * every tick and implement this function as a noop), the requirement 39 * is that one tick announcement should occur within one tick BEFORE 41 * the next tick", this convention was chosen to match legacy usage). 44 * next tick announcement as soon as possible. 53 * for ticks if it wants to preserve the uptime tick count but doesn't 64 * serialized by the driver such that a given tick is announced 69 * @param ticks Timeout in tick units 96 * latency limitations) to tick boundaries. 125 * counter as well as the tick announcements. This function is
|
/Zephyr-Core-3.6.0/boards/arm/qemu_cortex_m0/ |
D | nrf_timer_timer.c | 76 * next tick. Reconfigure CC to future (now tick is the furthest in prevent_false_prev_evt() 77 * future). If CC was set to next tick we need to wait for up to 0.5us in prevent_false_prev_evt() 78 * (half of 1M tick) and clean potential event. After that time there in prevent_false_prev_evt() 96 /* If settings is next tick from now, function attempts to set next tick. If 97 * counter progresses during that time it means that 1 tick elapsed and 104 /* already expired, tick elapsed but event might not be in handle_next_tick_case() 114 * +1 tick case. 189 /* Get the cycles from last_count to the tick boundary after in sys_clock_set_timeout()
|
/Zephyr-Core-3.6.0/include/zephyr/ |
D | sys_clock.h | 37 * @brief Tick precision used in timeout APIs 41 * timeout length (or equivalently minimum tick duration). Note that 144 /* added tick needed to account for tick in progress */ 186 * @brief Return the lower part of the current system tick count 188 * @return the current system tick count 195 * @brief Return the current system tick count 197 * @return the current system tick count 219 typedef struct { uint64_t tick; } k_timepoint_t; member 266 return tp.tick; in sys_clock_timeout_end_calc() 281 if (a.tick == b.tick) { in sys_timepoint_cmp() [all …]
|
/Zephyr-Core-3.6.0/tests/subsys/portability/cmsis_rtos_v2/src/ |
D | kernel.c | 12 uint32_t tick; variable 94 tick = osKernelGetTickCount(); in delay_until() 95 tick += 50U; in delay_until() 97 status_val = osDelayUntil(tick); in delay_until() 103 zassert_true(tick <= osKernelGetTickCount()); in ZTEST()
|
/Zephyr-Core-3.6.0/tests/benchmarks/latency_measure/boards/ |
D | frdm_k22f.conf | 3 # system clock tick period in 1 sec, make system clock tick to 0.1 sec
|
D | arduino_due.conf | 3 # system clock tick period in 1 sec, make system clock tick to 0.1 sec
|
D | atsame54_xpro.conf | 3 # system clock tick period in 1 sec, make system clock tick to 0.1 sec
|
D | frdm_k82f.conf | 3 # system clock tick period in 1 sec, make system clock tick to 0.1 sec
|
D | qemu_cortex_m3.conf | 3 # system clock tick period in 1 sec, make system clock tick to 0.1 sec
|
D | twr_ke18f.conf | 3 # system clock tick period in 1 sec, make system clock tick to 0.1 sec
|
/Zephyr-Core-3.6.0/tests/kernel/timer/timer_behavior/src/ |
D | tick_timer_train.c | 58 * @brief Test timers can be scheduled 1 tick apart without issues 60 * Schedules timers with absolute scheduling with a 1 tick 69 TC_PRINT("Initializing %u Timers, Tick Rate %uHz, Expecting %u callbacks in %u ms\n", in ZTEST() 78 int64_t tick = k_uptime_ticks(); in ZTEST() local 81 timers[i].last_scheduled = tick + i; in ZTEST() 124 TC_PRINT("One Tick Timer Train Done, took %u ms, busy loop ran %u times\n", in ZTEST() 156 /* On some platforms, where the tick period is short, like on nRF in ZTEST() 164 "Expected thread to run while 1 tick timers are firing"); in ZTEST()
|
/Zephyr-Core-3.6.0/drivers/timer/ |
D | gecko_burtc_timer.c | 60 /* Number of hw_cycles clocks per 1 kernel tick */ 66 /* Value of BURTC counter when the previous kernel tick was announced */ 100 * announce the very next tick - in that case we skip one and in burtc_isr() 122 * calculate 'ticks' value that specifies which tick to announce, in sys_clock_set_timeout() 124 * 0 - announce upcoming tick itself in sys_clock_set_timeout() 138 /* Which tick to announce (counting from the last announced one) */ in sys_clock_set_timeout() 151 * the very next tick - in that case we skip one and announce the one in sys_clock_set_timeout() 212 "%u cycle-long tick is too short to be scheduled " in burtc_init() 232 /* Start the timer and announce 1 kernel tick */ in burtc_init()
|
D | mcux_gpt_timer.c | 104 * Since rollover occurs on a tick boundary, we don't in mcux_imx_gpt_isr() 143 /* Clamp ticks. We subtract one since we round up to next tick */ in sys_clock_set_timeout() 151 /* Adjustment value, used to ensure next capture is on tick boundary */ in sys_clock_set_timeout() 156 * The following section rounds the capture value up to the next tick in sys_clock_set_timeout() 192 * Enable the hw timer, setting its tick period, and setup its interrupt 224 * over on a tick boundary. in sys_clock_driver_init() 229 /* Set initial trigger value to one tick worth of cycles */ in sys_clock_driver_init() 236 /* For a tickful kernel, just roll the counter over every tick */ in sys_clock_driver_init()
|
D | native_posix_timer.c | 22 static uint64_t tick_period; /* System tick period in microseconds */ 23 /* Time (microseconds since boot) of the last timer tick interrupt */ 72 * @param ticks Timeout in tick units 124 * Enable the hw timer, setting its tick period, and setup its interrupt
|
/Zephyr-Core-3.6.0/doc/kernel/services/timing/ |
D | clocks.rst | 35 "tick" is the internal count in which the kernel does all its internal 37 delivered on tick boundaries to the extent practical, and no 38 fractional ticks are tracked. The choice of tick rate is configurable 50 "us" (microseconds), "tick", or "cyc" can be converted to any other. 127 being 32 bits. Large uptime counts in non-tick units will experience 156 guaranteed at the tick level no matter how many events exist or how 168 Kernel timing at the tick level is driven by a timer driver with a 176 interrupt latency interactions) that they occur near tick boundaries 177 (i.e. not "halfway through" a tick), and most importantly that they 190 fractional tick gets "reset" incorrectly and causes clock skew. [all …]
|
/Zephyr-Core-3.6.0/boards/posix/native_posix/ |
D | Kconfig.board | 11 An interrupt controller, timer (system tick), and redirects kernel prints to 23 An interrupt controller, timer (system tick), and redirects kernel prints to
|
/Zephyr-Core-3.6.0/tests/bluetooth/controller/mock_ctrl/include/hal/ |
D | ticker_vendor_hal.h | 25 /* Macro to translate microseconds to tick units. 35 /* Macro to translate microseconds to tick units. 45 /* Macro to translate tick units to microseconds. */
|
/Zephyr-Core-3.6.0/tests/kernel/timer/timer_behavior/ |
D | Kconfig | 35 # Use 13% on nRF platforms using the RTC timer because one tick there is 36 # ~122 us (see SYS_CLOCK_TICKS_PER_SEC configuration above) and one tick 38 # example if a new tick elapses right after the kernel gets the number
|
/Zephyr-Core-3.6.0/drivers/lora/ |
D | hal_common.c | 86 /* For us, 1 tick = 1 milli second. So no need to do any conversion here */ 102 uint32_t RtcTick2Ms(uint32_t tick) in RtcTick2Ms() argument 104 return tick; in RtcTick2Ms()
|
/Zephyr-Core-3.6.0/subsys/bluetooth/controller/ll_sw/openisa/hal/RV32M1/ |
D | ticker.h | 31 /* Macro to translate microseconds to tick units. 41 /* Macro to translate microseconds to tick units. 51 /* Macro to translate tick units to microseconds. */
|
/Zephyr-Core-3.6.0/tests/kernel/sleep/src/ |
D | usleep.c | 20 * shortest possible tick timeout. That's generally 1, but in some 55 /* It should never iterate faster than the tick rate. However the 56 * app, sleep, and timeout layers may each add a tick alignment with 57 * fast tick rates, and cycle layer may inject another to guarantee
|
/Zephyr-Core-3.6.0/tests/kernel/context/ |
D | README.txt | 35 CPU to be woken up by tick timer. Thus, after each call, the tick count 36 should have advanced by one tick. 39 - 1. Count the number of calls to _tick_get_32() before a tick expires. 41 with interrupts locked. Check that the tick count remains unchanged. 44 - Continuation irq_lock: unlock interrupts, loop and verify the tick
|