Home
last modified time | relevance | path

Searched refs:delay (Results 1 – 25 of 307) sorted by relevance

12345678910>>...13

/Zephyr-latest/samples/subsys/portability/cmsis_rtos_v1/philosophers/src/
Dmain.c98 static void print_phil_state(int id, const char *fmt, int32_t delay) in print_phil_state() argument
112 if (delay) { in print_phil_state()
114 delay < 1000 ? " " : "", delay); in print_phil_state()
130 int32_t delay = (k_uptime_get_32() / 100 * (id + 1)) & 0x1f; in get_random_delay() local
133 int32_t ms = (delay + 1) * period_in_ms; in get_random_delay()
160 int32_t delay; in philosopher() local
167 delay = get_random_delay(my_id, 25); in philosopher()
168 print_phil_state(my_id, " EATING [ %s%d ms ] ", delay); in philosopher()
169 osDelay(delay); in philosopher()
175 delay = get_random_delay(my_id, 25); in philosopher()
[all …]
/Zephyr-latest/samples/subsys/portability/cmsis_rtos_v2/philosophers/src/
Dmain.c128 static void print_phil_state(int id, const char *fmt, int32_t delay) in print_phil_state() argument
139 if (delay) { in print_phil_state()
140 printk(fmt, delay < 1000 ? " " : "", delay); in print_phil_state()
155 int32_t delay = (k_uptime_get_32()/100 * (id + 1)) & 0x1f; in get_random_delay() local
158 int32_t ms = (delay + 1) * period_in_ms; in get_random_delay()
185 int32_t delay; in philosopher() local
192 delay = get_random_delay(my_id, 25); in philosopher()
193 print_phil_state(my_id, " EATING [ %s%d ms ] ", delay); in philosopher()
194 osDelay(delay); in philosopher()
200 delay = get_random_delay(my_id, 25); in philosopher()
[all …]
/Zephyr-latest/samples/philosophers/src/
Dmain.c100 static void print_phil_state(int id, const char *fmt, int32_t delay) in print_phil_state() argument
111 if (delay) { in print_phil_state()
112 printk(fmt, delay < 1000 ? " " : "", delay); in print_phil_state()
127 int32_t delay = (k_uptime_get_32()/100 * (id + 1)) & 0x1f; in get_random_delay() local
130 int32_t ms = (delay + 1) * period_in_ms; in get_random_delay()
160 int32_t delay; in philosopher() local
167 delay = get_random_delay(my_id, 25); in philosopher()
168 print_phil_state(my_id, " EATING [ %s%d ms ] ", delay); in philosopher()
169 k_msleep(delay); in philosopher()
175 delay = get_random_delay(my_id, 25); in philosopher()
[all …]
/Zephyr-latest/samples/posix/philosophers/src/
Dmain.c86 static void print_phil_state(int id, const char *fmt, int32_t delay) in print_phil_state() argument
106 if (delay) { in print_phil_state()
107 printk(fmt, delay < 1000 ? " " : "", delay); in print_phil_state()
118 int32_t delay; in get_random_delay() local
129 delay = (uptime / 100 * (id + 1)) & 0x1f; in get_random_delay()
132 ms = (delay + 1) * period_in_ms; in get_random_delay()
159 int32_t delay; in philosopher() local
166 delay = get_random_delay(my_id, 25); in philosopher()
167 print_phil_state(my_id, " EATING [ %s%d ms ] ", delay); in philosopher()
168 usleep(delay * USEC_PER_MSEC); in philosopher()
[all …]
/Zephyr-latest/tests/unit/net_timeout/
Dmain.c199 uint32_t delay; in ZTEST() local
214 delay = net_timeout_evaluate(&nto, now); in ZTEST()
215 zassert_equal(delay, NET_TIMEOUT_MAX_VALUE, in ZTEST()
229 delay = net_timeout_evaluate(&nto, now + half_max); in ZTEST()
230 zassert_equal(delay, NET_TIMEOUT_MAX_VALUE - half_max, in ZTEST()
244 delay = net_timeout_evaluate(&nto, now + NET_TIMEOUT_MAX_VALUE - 1U); in ZTEST()
245 zassert_equal(delay, 1U, in ZTEST()
260 delay = net_timeout_evaluate(&nto, now); in ZTEST()
261 zassert_equal(delay, NET_TIMEOUT_MAX_VALUE, in ZTEST()
278 delay = net_timeout_evaluate(&nto, now); in ZTEST()
[all …]
/Zephyr-latest/samples/drivers/led/pwm/
DKconfig5 int "Blinking delay for short cycle demo"
8 Specifies the LED on/off delay in milliseconds for short cycle
13 int "Blinking delay for long cycle demo"
16 Specifies the LED on/off delay in milliseconds for long cycle
24 Specifies the delay in milliseconds for the fade demo of the
27 delay elapses.
/Zephyr-latest/drivers/timer/
Darcv2_timer0.c279 uint32_t delay; in sys_clock_set_timeout() local
289 delay = MAX(ticks * CYC_PER_TICK, MIN_DELAY); in sys_clock_set_timeout()
293 timer0_limit_register_set(delay - 1); in sys_clock_set_timeout()
310 uint32_t delay; in sys_clock_set_timeout()
340 delay = ticks * CYC_PER_TICK; in sys_clock_set_timeout()
343 delay += unannounced; in sys_clock_set_timeout()
344 delay = DIV_ROUND_UP(delay, CYC_PER_TICK) * CYC_PER_TICK; in sys_clock_set_timeout()
346 delay -= unannounced; in sys_clock_set_timeout()
347 delay = MAX(delay, MIN_DELAY); in sys_clock_set_timeout()
349 last_load = MIN(delay, MAX_CYCLES); in sys_clock_set_timeout()
Dcortex_m_systick.c269 uint32_t delay; in sys_clock_set_timeout() local
297 delay = ticks * CYC_PER_TICK; in sys_clock_set_timeout()
300 delay += unannounced; in sys_clock_set_timeout()
301 delay = DIV_ROUND_UP(delay, CYC_PER_TICK) * CYC_PER_TICK; in sys_clock_set_timeout()
302 delay -= unannounced; in sys_clock_set_timeout()
303 delay = MAX(delay, MIN_DELAY); in sys_clock_set_timeout()
304 if (delay > MAX_CYCLES) { in sys_clock_set_timeout()
307 last_load = delay; in sys_clock_set_timeout()
/Zephyr-latest/drivers/led_strip/
DKconfig.ws281229 delay. The reset delay has a coarse resolution of ~20us.
54 default $(dt_node_int_prop_int,$(DT_CHOSEN_LED_STRIP_PATH),delay-t1h) \
55 if $(dt_node_has_prop,$(DT_CHOSEN_LED_STRIP_PATH),delay-t1h)
60 …Number of NOP assembly operations to create a delay for a 1 bit, high voltage period (default 700 …
64 default $(dt_node_int_prop_int,$(DT_CHOSEN_LED_STRIP_PATH),delay-t1l) \
65 if $(dt_node_has_prop,$(DT_CHOSEN_LED_STRIP_PATH),delay-t1l)
70 …Number of NOP assembly operations to create a delay for a 1 bit, low voltage period (default 600 n…
74 default $(dt_node_int_prop_int,$(DT_CHOSEN_LED_STRIP_PATH),delay-t0h) \
75 if $(dt_node_has_prop,$(DT_CHOSEN_LED_STRIP_PATH),delay-t0h)
80 …Number of NOP assembly operations to create a delay for a 0 bit, high voltage period (default 350 …
[all …]
/Zephyr-latest/samples/boards/nordic/mesh/onoff_level_lighting_vnd_app/src/mesh/
Ddevice_composition.c124 uint8_t tid, onoff, tt, delay; in gen_onoff_set_unack() local
145 delay = 0U; in gen_onoff_set_unack()
153 delay = net_buf_simple_pull_u8(buf); in gen_onoff_set_unack()
167 ctl->transition->delay = delay; in gen_onoff_set_unack()
193 uint8_t tid, onoff, tt, delay; in gen_onoff_set() local
215 delay = 0U; in gen_onoff_set()
223 delay = net_buf_simple_pull_u8(buf); in gen_onoff_set()
237 ctl->transition->delay = delay; in gen_onoff_set()
333 uint8_t tid, tt, delay; in gen_level_set_unack() local
351 delay = 0U; in gen_level_set_unack()
[all …]
Dtransition.c468 if (ctl->transition->counter == 0U && ctl->transition->delay == 0) { in onoff_handler()
476 K_MSEC(ctl->transition->delay * 5U), in onoff_handler()
482 if (ctl->transition->counter == 0U && ctl->transition->delay == 0) { in level_lightness_handler()
491 K_MSEC(ctl->transition->delay * 5U), in level_lightness_handler()
497 if (ctl->transition->counter == 0U && ctl->transition->delay == 0) { in level_temp_handler()
505 K_MSEC(ctl->transition->delay * 5U), in level_temp_handler()
511 if (ctl->transition->counter == 0U && ctl->transition->delay == 0) { in light_lightness_actual_handler()
520 K_MSEC(ctl->transition->delay * 5U), in light_lightness_actual_handler()
526 if (ctl->transition->counter == 0U && ctl->transition->delay == 0) { in light_lightness_linear_handler()
535 K_MSEC(ctl->transition->delay * 5U), in light_lightness_linear_handler()
[all …]
/Zephyr-latest/drivers/counter/
Dcounter_timer_shell.c102 unsigned long delay = 0; in cmd_timer_oneshot() local
114 delay = shell_strtoul(argv[ARGV_ONESHOT_TIME], 10, &err); in cmd_timer_oneshot()
118 } else if (delay > MAX_DELAY) { in cmd_timer_oneshot()
133 alarm_cfg.ticks = counter_us_to_ticks(timer_dev, (uint64_t)delay); in cmd_timer_oneshot()
155 unsigned long delay = 0; in cmd_timer_periodic() local
166 delay = shell_strtoul(argv[ARGV_PERIODIC_TIME], 10, &err); in cmd_timer_periodic()
170 } else if (delay > MAX_DELAY) { in cmd_timer_periodic()
176 top_cfg.ticks = counter_us_to_ticks(timer_dev, (uint64_t)delay); in cmd_timer_periodic()
/Zephyr-latest/samples/drivers/auxdisplay/boards/
Desp_wrover_kit.overlay21 boot-delay-ms = <100>;
22 enable-line-rise-delay-us = <1000>;
23 enable-line-fall-delay-us = <500>;
/Zephyr-latest/samples/drivers/spi_flash_at45/boards/
Dnrf9160dk_nrf9160.overlay42 enter-dpd-delay = <2000>;
43 exit-dpd-delay = <35000>;
57 enter-dpd-delay = <1000>;
58 exit-dpd-delay = <180000>;
/Zephyr-latest/boards/madmachine/mm_feather/
Dmm_feather.dts112 pcs-sck-delay = <2>;
113 sck-pcs-delay = <2>;
114 transfer-delay = <2>;
119 pcs-sck-delay = <2>;
120 sck-pcs-delay = <2>;
121 transfer-delay = <2>;
/Zephyr-latest/include/zephyr/pm/
Ddevice_runtime.h145 int pm_device_runtime_put_async(const struct device *dev, k_timeout_t delay);
205 k_timeout_t delay)
208 ARG_UNUSED(delay);
/Zephyr-latest/tests/subsys/logging/log_backend_init/src/
Dmain.c23 uint32_t delay; member
77 k_timer_start(&context->timer, K_MSEC(context->delay), K_NO_WAIT); in backend_init()
95 .delay = 500
99 .delay = 1000,
137 k_msleep(context2.delay + 100); in ZTEST()
/Zephyr-latest/tests/drivers/regulator/fixed/dts/
Dtest_common.dtsi11 startup-delay-us = <1000000>;
12 off-on-delay-us = <20000>;
/Zephyr-latest/subsys/net/ip/
Dipv4_acd.c157 uint32_t delay; in ipv4_acd_manage_timeout() local
166 delay = sys_rand32_get(); in ipv4_acd_manage_timeout()
167 delay %= MSEC_PER_SEC * (IPV4_ACD_PROBE_MAX - IPV4_ACD_PROBE_MIN); in ipv4_acd_manage_timeout()
168 delay += MSEC_PER_SEC * IPV4_ACD_PROBE_MIN; in ipv4_acd_manage_timeout()
170 delay = MSEC_PER_SEC * IPV4_ACD_ANNOUNCE_WAIT; in ipv4_acd_manage_timeout()
174 ifaddr->acd_timeout = sys_timepoint_calc(K_MSEC(delay)); in ipv4_acd_manage_timeout()
238 uint32_t delay; in acd_start_timer() local
245 delay = MSEC_PER_SEC * IPV4_ACD_RATE_LIMIT_INTERVAL; in acd_start_timer()
250 delay = sys_rand32_get() % (MSEC_PER_SEC * IPV4_ACD_PROBE_WAIT); in acd_start_timer()
253 ifaddr->acd_timeout = sys_timepoint_calc(K_MSEC(delay)); in acd_start_timer()
/Zephyr-latest/boards/madmachine/mm_swiftio/
Dmm_swiftio.dts126 pcs-sck-delay = <50>;
127 sck-pcs-delay = <50>;
128 transfer-delay = <50>;
133 pcs-sck-delay = <50>;
134 sck-pcs-delay = <50>;
135 transfer-delay = <50>;
/Zephyr-latest/tests/drivers/timer/nrf_rtc_timer/src/
Dmain.c15 uint32_t delay; member
77 zassert_true(diff <= data->delay, in timeout_handler()
95 .delay = ext_window ? 100 : 2, in test_timeout()
154 .delay = 2000, in ZTEST()
324 .delay = 0, in ZTEST()
434 static uint32_t delay; in next_cycle_timeout_handler() local
438 k_busy_wait(delay); in next_cycle_timeout_handler()
439 ++delay; in next_cycle_timeout_handler()
519 for (uint32_t delay = DELAY_MIN; delay <= DELAY_MAX; ++delay) { in ZTEST() local
525 k_busy_wait(delay); in ZTEST()
[all …]
/Zephyr-latest/drivers/dp/
Dswdp_bitbang.c220 #define SW_CLOCK_CYCLE(dev, delay) \ argument
223 pin_delay_asm(delay); \
225 pin_delay_asm(delay); \
228 #define SW_WRITE_BIT(dev, bit, delay) \ argument
232 pin_delay_asm(delay); \
234 pin_delay_asm(delay); \
237 #define SW_READ_BIT(dev, bit, delay) \ argument
240 pin_delay_asm(delay); \
243 pin_delay_asm(delay); \
530 uint32_t delay; in sw_set_clock() local
[all …]
/Zephyr-latest/drivers/wifi/simplelink/
Dsimplelink.c119 int32_t delay; in simplelink_scan_work_handler() local
124 delay = (simplelink_data.num_results_or_err > 0 ? 0 : in simplelink_scan_work_handler()
126 if (delay > 0) { in simplelink_scan_work_handler()
129 k_work_reschedule(&simplelink_data.work, K_MSEC(delay)); in simplelink_scan_work_handler()
160 int32_t delay = (err > 0 ? 0 : SCAN_RETRY_DELAY); in simplelink_mgmt_scan() local
167 k_work_reschedule(&simplelink_data.work, K_MSEC(delay)); in simplelink_mgmt_scan()
/Zephyr-latest/tests/bluetooth/audio/mocks/src/
Dkernel.c33 int k_work_reschedule(struct k_work_delayable *dwork, k_timeout_t delay) in k_work_reschedule() argument
38 dwork->timeout.dticks = delay.ticks; in k_work_reschedule()
60 int k_work_schedule(struct k_work_delayable *dwork, k_timeout_t delay) in k_work_schedule() argument
71 dwork->timeout.dticks = delay.ticks; in k_work_schedule()
/Zephyr-latest/tests/net/socket/socketpair/src/
Dpoll.c12 k_timeout_t delay; member
75 if (!(K_TIMEOUT_EQ(ctx.delay, K_NO_WAIT) in close_fun()
76 || K_TIMEOUT_EQ(ctx.delay, K_FOREVER))) { in close_fun()
77 k_sleep(ctx.delay); in close_fun()
109 ctx.delay = K_MSEC(1000); in ZTEST_F()
147 ctx.delay = K_MSEC(1000); in ZTEST_F()
213 if (!(K_TIMEOUT_EQ(ctx.delay, K_NO_WAIT) in rw_fun()
214 || K_TIMEOUT_EQ(ctx.delay, K_FOREVER))) { in rw_fun()
215 k_sleep(ctx.delay); in rw_fun()
254 ctx.delay = K_MSEC(100); in ZTEST_F()
[all …]

12345678910>>...13