Function esp_idf_svc::hal::sys::gptimer_new_timer
source · pub unsafe extern "C" fn gptimer_new_timer(
config: *const gptimer_config_t,
ret_timer: *mut *mut gptimer_t,
) -> i32
Expand description
@brief Create a new General Purpose Timer, and return the handle
@note The newly created timer is put in the “init” state.
@param[in] config GPTimer configuration @param[out] ret_timer Returned timer handle @return - ESP_OK: Create GPTimer successfully - ESP_ERR_INVALID_ARG: Create GPTimer failed because of invalid argument - ESP_ERR_NO_MEM: Create GPTimer failed because out of memory - ESP_ERR_NOT_FOUND: Create GPTimer failed because all hardware timers are used up and no more free one - ESP_FAIL: Create GPTimer failed because of other error