This module provides simple loop-based delay routines for those applications requiring a brief wait during execution.
Common for API ver. 2.
Modules | |
Related Project(s) | |
In this section you can find all the projects related to the Busy-Wait Delay Routines. | |
Macros | |
#define | delay_ms(delay) ((delay) ? cpu_delay_ms(delay) : cpu_delay_us(1)) |
Delay in at least specified number of milliseconds. More... | |
#define | delay_s(delay) ((delay) ? cpu_delay_s(delay) : cpu_delay_us(1)) |
Delay in at least specified number of seconds. More... | |
#define | delay_us(delay) ((delay) ? cpu_delay_us(delay) : cpu_delay_us(1)) |
Delay in at least specified number of microseconds. More... | |
Functions | |
void | delay_init (void) |
Initialize the delay driver. More... | |
#define delay_ms | ( | delay | ) | ((delay) ? cpu_delay_ms(delay) : cpu_delay_us(1)) |
Delay in at least specified number of milliseconds.
delay | Delay in milliseconds |
Referenced by anp_custom_event(), ble_critical_alert(), ble_observer_custom_event(), bno055_delay_msek(), bno055_reset(), enddevice_cpc_execute_command(), getchar_timeout(), HAL_TCXOPowerOn(), hid_service_dbreg(), hr_sensor_app_custom_event(), ksz8851snl_hard_reset(), led_toggle_indication(), main(), nm_bsp_sleep(), platform_send_sync(), platform_sleep(), Radio_WriteMode(), retry_smtp_server(), run_ac_callback_mode_test(), run_ac_single_shot_test(), run_ac_window_mode_test(), run_adc_average_mode_test(), run_adc_callback_mode_test(), run_adc_polled_mode_test(), run_adc_window_mode_test(), run_cbc_mode_test(), run_cfb128_mode_test(), run_ctr_mode_test(), run_dac_event_control_test(), run_ecb_mode_test(), run_ecb_mode_test_dma(), run_extint_polled_mode_test(), run_ofb_mode_test(), run_rtc_count_interrupt_test(), run_rtc_count_test(), run_test_downstream(), run_test_downstream_disconnection(), run_wdt_early_warning_test(), setup_adc_window_mode_test(), SystemBlockingWaitMs(), tip_app_custom_event(), and wait_for_wdt_reset().
#define delay_s | ( | delay | ) | ((delay) ? cpu_delay_s(delay) : cpu_delay_us(1)) |
Delay in at least specified number of seconds.
delay | Delay in seconds |
Referenced by main(), run_rtc_calendar_interrupt_test(), and run_rtc_calendar_test().
#define delay_us | ( | delay | ) | ((delay) ? cpu_delay_us(delay) : cpu_delay_us(1)) |
Delay in at least specified number of microseconds.
delay | Delay in microseconds |
Referenced by app_alert(), PHY_RandomReq(), and sal_aes_wrrd().
void delay_init | ( | void | ) |
Initialize the delay driver.
This must be called during start up to initialize the delay routine with the current used main clock. It must run any time the main CPU clock is changed.
Not used in cycle mode.
References cycles_per_ms, cycles_per_us, and system_gclk_gen_get_hz().
Referenced by ksz8851snl_init(), main(), nm_bsp_init(), sdmmc_mem_init(), and ssd1306_init().