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

OV2640 standby support #672

Closed
jksemple opened this issue Jul 30, 2024 · 5 comments
Closed

OV2640 standby support #672

jksemple opened this issue Jul 30, 2024 · 5 comments

Comments

@jksemple
Copy link

This issue revisits #101 which was closed due to inactivity.
However, @me-no-dev commented that he 'will implement this very soon' - which was 4 years ago.

This is still a problem and effectively prevents ESP32 Camera being used in any low power / battery role.

@jksemple
Copy link
Author

For those struggling with this I have tested OV3660, which does cope with software standby:
sensor->set_reg(sensor, 0x3008, 0x40, enable ? 0x40 : 0x00);

Current drawn by a Xiao ESP32S3 Sense equipped with OV3660 instead of OV2640 drops to less than 5mA in deep sleep after putting the camera into standby mode as above. It is also possible to put the camera into standby mode between pictures which reduces current draw by about 60mA while not in use.

It is likely this code will work with OV5640 too as it has the same registers.

@jksemple
Copy link
Author

jksemple commented Sep 1, 2024

sensor_t* sensor = esp_camera_sensor_get();
sensor->set_reg(sensor, 0x3008, 0x40, enable ? 0x40 : 0x00);

@wormyrocks
Copy link

hi,
I managed to put an OV2640 into standby with the following:

// i=1: sleep, i=0: wake
void camera_deep_sleep(int i)
{
  sensor_t *s = esp_camera_sensor_get();
  s->set_reg(s, 0x109, 0x10, i ? 0x10 : 0);
}

let me know if you find any way to wake it back up :)

@jksemple
Copy link
Author

Putting it to sleep is not the issue. Getting it to wake up again is where we all get stuck. It appears to be a hardware design flaw. The only workaround is to cut power and restart.

Copy link

This issue appears to be stale. Please close it if its no longer valid.

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

No branches or pull requests

2 participants