Skip to content

Conversation

@janos-raul
Copy link

-added html page to view camera stream and configure settings
-saving camera and wifi settings to SPIFFS
-simple ftp server for uploading and managing webpage

janos-raul and others added 24 commits April 6, 2025 11:45
-added camera deinitialization before OTA updates to prevent incorect settings after restart
-added deinit function
-added cam.deinit();
50ms key debounce to prevent unintentional behavior
This commit resolves the task watchdog timeout errors that were causing
the ESP32-CAM to reset after ~30 seconds of operation.

Changes:
- Added esp_task_wdt.h include for watchdog management
- Configured watchdog with 30-second timeout in setup()
- Added watchdog monitoring to all RTOS tasks (mjpegCB, camCB, streamCB)
- Added multiple watchdog resets in each task loop to prevent timeout
- Replaced task suspension with delays to keep tasks responsive
- Increased stack sizes: cam/stream tasks 6KB→8KB, mjpeg task 4KB→6KB
- Adjusted task priorities: cam/stream 6→5, mjpeg 6→4
- Added non-blocking wait with watchdog reset in streamCB initialization
- Added dynamic FPS validation to prevent division by zero
- Added main loop to watchdog monitoring

These changes ensure stable operation without watchdog resets while
maintaining proper resource management when no clients are connected.

🤖 Generated with Claude Code

Co-Authored-By: Claude <noreply@anthropic.com>
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