Skip to content

fix jpeg eoi check for psram_mode (DMA) #777

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

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

RubenKelevra
Copy link
Contributor

@RubenKelevra RubenKelevra commented Jul 22, 2025

Description

This patch required #776 and thus contains the commit of this PR.

  • Added a configurable probe length for PSRAM JPEG validation via CAM_EOI_PROBE_BYTES
  • For PSRAM mode, CAM_EOI_PROBE_BYTES is copied from the first DMA block into a
    stack buffer and validated by cam_verify_jpeg_eoi() to verify that it's a valid
    jpeg image.
  • Reading from PSRAM directly with cam_verify_jpeg_eoi() is here avoided due to
    latency of small operations done by cam_verify_jpeg_eoi().

Related

Related #775, #776

Checklist

Before submitting a Pull Request, please ensure the following:

  • 🚨 This PR does not introduce breaking changes.
  • All CI checks (GH Actions) pass.
  • Documentation is updated as needed.
  • Tests are updated or added as necessary.
  • Code is well-commented, especially in complex areas.
  • Git history is clean — commits are squashed to the minimum necessary.

- Added a configurable probe length for PSRAM JPEG validation via CAM_SOI_PROBE_BYTES
- For PSRAM mode, CAM_SOI_PROBE_BYTES is copied from the first DMA block into a
  stack buffer and validated by cam_verify_jpeg_soi() to verify that it's a valid
  jpeg image before continuing the capture.
- Reading from PSRAM directly with cam_verify_jpeg_soi() is here avoided due to
  latency of small operations done by cam_verify_jpeg_soi().
- Added a configurable probe length for PSRAM JPEG validation via CAM_EOI_PROBE_BYTES
- For PSRAM mode, CAM_EOI_PROBE_BYTES is copied from the first DMA block into a
  stack buffer and validated by cam_verify_jpeg_eoi() to verify that it's a valid
  jpeg image.
- Reading from PSRAM directly with cam_verify_jpeg_eoi() is here avoided due to
  latency of small operations done by cam_verify_jpeg_eoi().
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.

1 participant