Lines Matching full:time
10 * - A real time clock
11 * - A one shot HW timer which can be used to awake the CPU at a given time
15 * About time in native_posix
18 * Real time clock
22 #include <time.h>
39 * Helper function to convert a 64 bit time in microseconds into a string.
45 static char *us_time_to_str(char *dest, uint64_t time) in us_time_to_str() argument
47 if (time != NEVER) { in us_time_to_str()
53 hour = (time / 3600U / 1000000U) % 24; in us_time_to_str()
54 minute = (time / 60U / 1000000U) % 60; in us_time_to_str()
55 second = (time / 1000000U) % 60; in us_time_to_str()
56 us = time % 1000000; in us_time_to_str()
91 * Ratio of the simulated clock to the real host time
92 * For ex. a clock_ratio = 1+100e-6 means the simulated time is 100ppm faster
93 * than real time
99 * Offset of the simulated time vs the real host time due to drift/clock ratio
100 * until "last_radj_*time"
102 * A positive value means simulated time is ahead of the host time
111 * "simu_time" == simulated time which starts at 0 on boot
115 /* Last host/real time when the ratio was adjusted */
117 /* Last simulated time when the ratio was adjusted */
251 * The timer HW will awake the CPU (without an interrupt) at least when <time>
254 * If there was a previous request for an earlier time, the old one will prevail
258 void hwtimer_wake_in_time(uint64_t time) in hwtimer_wake_in_time() argument
260 if (hw_timer_awake_timer > time) { in hwtimer_wake_in_time()
261 hw_timer_awake_timer = time; in hwtimer_wake_in_time()
283 * During boot set the real time clock simulated time not start
284 * from the real host time
292 * Set a time offset (microseconds) of the RTC simulated time
301 * Set the ratio of the simulated time to host (real) time.
310 * Increase or decrease the RTC simulated time by offset_delta
318 * Adjust the ratio of the simulated time by a factor
324 /* Accumulated real time drift time since last adjustment: */ in hwtimer_adjust_rt_ratio()
353 * Return the current simulated RTC time in microseconds
362 * Return a version of the host time which would have drifted as if the host
363 * real time clock had been running from the native_posix clock, and adjusted
366 * Note that this time may be significantly ahead of the simulated time
367 * (the time the Zephyr kernel thinks it is).
369 * faster than real time.
377 * time split in us and ns. So we keep the full precision for 500 odd in hwtimer_get_pseudohost_rtc_time()
388 * where st = simulated time in hwtimer_get_pseudohost_rtc_time()
389 * rt = real time in hwtimer_get_pseudohost_rtc_time()
390 * last_rt_adj_time = time (real) when the last ratio in hwtimer_get_pseudohost_rtc_time()
392 * last_st_adj_time = time (simulated) when the last ratio in hwtimer_get_pseudohost_rtc_time()
394 * ratio = ratio between simulated time and real time in hwtimer_get_pseudohost_rtc_time()
493 "Slow down the execution to the host real time, " in native_add_time_options()
499 "Do NOT slow down the execution to real time, but advance " in native_add_time_options()
500 "Zephyr's time as fast as possible and decoupled from the host " in native_add_time_options()
501 "time"}, in native_add_time_options()
506 "Drift of the simulated clock relative to the host real time. " in native_add_time_options()
509 "This option has no effect in non real time mode" in native_add_time_options()
515 "Relative speed of the simulated time vs real time. " in native_add_time_options()
516 "For ex. set to 2 to have simulated time pass at double the " in native_add_time_options()
517 "speed of real time. " in native_add_time_options()
521 "This option has no effect in non real time mode" in native_add_time_options()
533 "Start the simulated real time clock at 0. Otherwise it starts " in native_add_time_options()
534 "matching the value provided by the host real time clock"}, in native_add_time_options()
537 "stop_at", "time", 'd', in native_add_time_options()