Function esp_idf_svc::sys::gptimer_disable
source · pub unsafe extern "C" fn gptimer_disable(timer: *mut gptimer_t) -> i32
Expand description
@brief Disable GPTimer
@note This function will transit the timer state from “enable” to “init”.
@note This function will disable the interrupt service if it’s installed.
@note This function will release the PM lock if it’s acquired in the gptimer_enable
.
@note Disable a timer doesn’t mean to stop it. See also gptimer_stop
for how to make the timer stop counting.
@param[in] timer Timer handle created by gptimer_new_timer
@return
- ESP_OK: Disable GPTimer successfully
- ESP_ERR_INVALID_ARG: Disable GPTimer failed because of invalid argument
- ESP_ERR_INVALID_STATE: Disable GPTimer failed because the timer is not enabled yet
- ESP_FAIL: Disable GPTimer failed because of other error