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

about camera init error #14

Open
shenzhenjinma opened this issue Dec 16, 2021 · 1 comment
Open

about camera init error #14

shenzhenjinma opened this issue Dec 16, 2021 · 1 comment

Comments

@shenzhenjinma
Copy link

shenzhenjinma commented Dec 16, 2021

Hi,i unable to use camera feature,how do i use this feature?can tell me ?thanks

camera.init()
I (437234) sccb: pin_sda 26 pin_scl 27

E (437234) i2c: i2c driver install error
I (437234) gpio: GPIO[32]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0
E (437304) camera: Detected camera not supported.
E (437304) camera: Camera probe failed with error 0x20004
E (437304) camera: Camera Init Failed
False

I want to know how to fix it. I used the esp32-cam by Taobao which is usually used. Could you please put a firmware of this kind? I think most users in China would use this one.

Originally posted by @ywz978020607 in #5 (comment)

@sylvesternumski
Copy link

sylvesternumski commented Feb 21, 2022

This code depends on esp32-camera component from esp-idf. There have been many updates recently but if you replace the line:
gpio_install_isr_service(ESP_INTR_FLAG_LEVEL1 | ESP_INTR_FLAG_IRAM);

in esp32-camera/target/esp32/ll_cam.c with:
esp_err_t err = gpio_install_isr_service(ESP_INTR_FLAG_LEVEL1 | ESP_INTR_FLAG_IRAM);
if (err != ESP_OK) {
if (err != ESP_ERR_INVALID_STATE) {
ESP_LOGE(TAG, "gpio_install_isr_service failed (%x)", err);
}
else {
ESP_LOGW(TAG, "gpio_install_isr_service already installed");
}
}

The gpio service install will still fail but will allow the driver to continue and be successful.

This was suggested here: #5 (comment)
But because of all the updates, that patch doesn't line up correctly, and the location of where to update with this logic is different in the more recent esp32-camera source. (update ll_cam.c as opposed to camera.c - which is no longer there). I'm surprised that this logic has not been put into the main esp32-camera component but I'm sure there's a specific reason (it might be "board" specific and should be done only with a specific configuration and I don't want to hunt around to see about enabling it - maybe I will later if I get further)

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

No branches or pull requests

2 participants