-
Notifications
You must be signed in to change notification settings - Fork 7.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide ulp_adc_deinit() API to fix ADC1 handle leakage (IDFGH-11673) #12785
Conversation
👋 Hello kutukvpavel, we appreciate your contribution to this project! 📘 Please review the project's Contributions Guide for key guidelines on code, documentation, testing, and more. 🖊️ Please also make sure you have read and signed the Contributor License Agreement for this project. Click to see more instructions ...
Review and merge process you can expect ...
|
Thanks for adding this @kutukvpavel! LGTM, i'll pull it into our internal gitlab for review, test and merge. |
sha=8596d46774d65171b4540288918037c43e3debb4 |
Fix for #12766. Also restructured error handling in
ulp_adc_init(...)
so that it returns an error code instead of callingabort()
fromESP_ERROR_CHECK(...)
.Tested against
ulp_riscv_adc
example (deep sleep case) as well as our own custom app (light sleep case).P.S. Right now
ulp_adc
driver is remarkably similar tooneshot
driver itself, it mostly duplicates configuration API, introducing little new functionality. While I think this PR should be merged and backported to v5.1 branch ASAP to enable customers (like us) to use ULP ADC with Light Sleep, it's probably worth integrating ULP-related initialization code intooneshot
driver itself in future releases. After all,adc_oneshot_unit_init_cfg_t::ulp_mode
is already there.