pcnt_del_unit() function
Delete the PCNT unit handle
Arguments
unit
PCNT unit handle created by `pcnt_new_unit()`
Return value
- ESP_OK: Delete the PCNT unit successfully - ESP_ERR_INVALID_ARG: Delete the PCNT unit failed because of invalid argument - ESP_ERR_INVALID_STATE: Delete the PCNT unit failed because the unit is not in init state or some PCNT channel is still in working - ESP_FAIL: Delete the PCNT unit failed because of other error
Notes
A PCNT unit can't be in the enable state when this function is invoked. See also `pcnt_unit_disable()` for how to disable a unit.
pcnt_del_unit() calls 3 functions:
![]()
pcnt_del_unit()
pcnt_del_unit() reads 12 variables:
![]()
pcnt_del_unit()