I’m testing the Random Nerd codes included in the Random Nerds ESPP32-CAM-Projects-eBook to take photos and store it on a Micro SD Card. The code in the Unit 1 Take Photos and Save to MicroSD Card (Time-lapse) works fine. Nevertheless the code in the Unit 4 Take Photo and Save to MicroSD Card with Pushbutton described on page 115 which add the push button feature save just parts of the photo not the complete frame on the MicroSD Card. I checked that both codes and all the camera and MicroSD card setting are identical just the second code includes the debouncing detection process for the push button. I will appreciated any help about this issue. Thanks
Hi.
Can you try these scenarios and see if any of these options solves your problem?
- Decrease the frame size of the photo. For example:
config.frame_size = FRAMESIZE_VGA;
- Decrease the quality (choose a higher number), for example 20:
config.jpeg_quality = 20; //0-63 lower number means higher quality
Do you get any messages on the serial monitor when you press the pushbutton?
Regards.
Sara
Thanks Sara for your answer.
I have changed the picture frame_size and the jpeg_quality to your recommended settings and now all the pictures are completed.
OLD settings:
config.frame_size = FRAMESIZE_UXGA; // FRAMESIZE_ + QVGA|CIF|VGA|SVGA|XGA|SXGA|UXGA
config.jpeg_quality = 10; //0-63 lower number means higher quality
New settings:
config.frame_size = FRAMESIZE_VGA; // FRAMESIZE_ + QVGA|CIF|VGA|SVGA|XGA|SXGA|UXGA
config.jpeg_quality = 20; //0-63 lower number means higher quality
Why is this issue? It’s supposed that the anti bouncing software doesn’t interfere with the TakeSavePhoto routine.
It’s strange that this issue is not present when the anti bouncing code is absent and the rest of the code is identical.
Is there some documentation regarding the esp_camera.h library and the other libraries used in this program?
Thanks!
Felipe
Hi.
I’m not sure why that problem happens. But other readers had the same problem, and changing the settings solved the issue.
I don’t think there is any documentation about those libraries.
You can find the esp_camera.h file here: https://github.com/espressif/esp32-camera/blob/master/driver/include/esp_camera.h
Regards,
Sara
Thanks Sara, now a new issue happened: The micro SD card cannot be recognized by the code. I tried several times with different cards included a new one with the same results:
-> Initializing the microSD card module… Starting SD Card
-> SD Card Mount Failed
It is strange because it works fine before.
Hi gain.
Yes, it is very strange indeed.
Can you try it again with the time lapse code and see if it works?
Just to figure out if it has everything to do with the code.
Regards,
Sara
Hi,
I solved this issue loading again the plain text code in the arduino IDE and compiled again. Now the MicroSD card is mounted correctly.
Regards,
Felipe