Comments (6)
Hi @raphaelbs ,
I tried it and I had the same outcome.
So it happens when it calls gpio_install_isr_service it changed on 29dec 2019.
We can try/catch this error 409 to bypass it. But since it's a "goto fail" idk if we can do much.
I believe we can't catch it since it's a "goto fail" after and jump all the next code.
from esp32-cam-ai-thinker.
/**
* @brief Initialize the camera driver
*
* @note call camera_probe before calling this function
*
* This function detects and configures camera over I2C interface,
* allocates framebuffer and DMA buffers,
* initializes parallel I2S input, and sets up DMA descriptors.
*
* Currently this function can only be called once and there is
* no way to de-initialize this module.
*
* @param config Camera configuration parameters
*
* @return ESP_OK on success
*/
esp_err_t esp_camera_init(const camera_config_t* config);
So it seems logic that this trick shouldn't work;
esp_camera_deinit();
ESP_ERROR_CHECK(esp_camera_init(&photo_config));
from esp32-cam-ai-thinker.
Hey @thomas-pegot, thanks for reporting this issue!
Looking at the deinit function, it does remove the GPIO handler but this doesn't seems to be enough.
Can you try calling gpio_uninstall_isr_service
after the esp_camera_deinit
?
from esp32-cam-ai-thinker.
Oh I see. That explains why it was working before!
Using the uninstall method should've worked as it sets the gpio_isr_func
to NULL
and the install method only asserts the value of gpio_isr_func
.
I guess we should investigate other methods of re-config the camera.
from esp32-cam-ai-thinker.
The camera driver hosted on this repo is the outdated version:
https://github.com/raphaelbs/esp32-cam-ai-thinker/blob/master/components/ov2640/camera/camera.c#L1165
The build should work with it.
from esp32-cam-ai-thinker.
I mean what are the pros to reset camera ?
This code can work fine without:
esp_camera_deinit(); ESP_ERROR_CHECK(esp_camera_init(&photo_config));
and add esp_camera_fb_return(fb)
at the end of the loop.
Could for example make a different branch to denote version with old esp_camera lib and one with new esp_camera that stay updated.
Just some thought and thank you for your reply.
from esp32-cam-ai-thinker.
Related Issues (20)
- Fail while initializing OV2640
- GPIO 16, PSRAM and Available IO Pin HOT 1
- Reboot and flash through programmer HOT 2
- Adaptando para motion detect HOT 1
- CONFIG_RESET was not declared ? HOT 2
- Motion detection improvement
- 编译 http_jpg报错fatal error: mdns.h: No such file or directory #include <mdns.h HOT 1
- LED flash turn off while taking picture
- Make fails with exit code 2 HOT 2
- Failure to run example with memory error HOT 3
- ai thinker board - status
- I can not connect again (ERR_EMPTY_RESPONSE)
- Guru Meditation Error
- SPI on ESP32-CAM
- Question about OTA possibility HOT 1
- Workspace configuration file not working on UNIX machines
- Cam
- #include <sys/param.h>
- I have error in building the SD_JPG project.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from esp32-cam-ai-thinker.