Skip to content
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

don't reset LEDC channel if it wasn't used by camera #451

Merged
merged 1 commit into from
Sep 23, 2022

Conversation

dhalbert
Copy link
Contributor

@dhalbert dhalbert commented Sep 19, 2022

camera_disable_out_clock is called (as CAMERA_DISABLE_OUT_CLOCK()) in esp_camera_deinit()

camera_disable_out_clock() stops the clock for LEDC channel g_ledc_channel. But if the camera was never enabled, it will stop channel 0, which might be in use by other unrelated things.

This fix detects when there is no clock to stop.

See adafruit#1 for background.

@me-no-dev me-no-dev merged commit de025b8 into espressif:master Sep 23, 2022
@me-no-dev
Copy link
Member

Thanks @dhalbert for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants