-
Notifications
You must be signed in to change notification settings - Fork 652
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
16.0.0 RC2: Camera not detected #3300
Comments
@SybexX Sorry, this was a misinformation. My module seems to be OV2640. Since it's working with 15.7.0 and the highlighted line also exists in tag 15.7.0 this should not be the issue. |
This is a "normal" startup with 15.7.0. [0d00h00m00s] 2024-10-05T12:52:25 <INF> [MAIN] =================================================
[0d00h00m00s] 2024-10-05T12:52:25 <INF> [MAIN] ==================== Start ======================
[0d00h00m00s] 2024-10-05T12:52:25 <INF> [MAIN] =================================================
[0d00h00m00s] 2024-10-05T12:52:25 <INF> [MAIN] PSRAM size: 8388608 byte (8MB / 64MBit)
[0d00h00m00s] 2024-10-05T12:52:25 <INF> [MAIN] Total heap: 4380067 byte
[0d00h00m04s] 2024-10-05T12:52:30 <INF> [MAIN] Camera info: PID: 0x26, VER: 0x42, MIDL: 0x7f, MIDH: 0xa2
[0d00h00m04s] 2024-10-05T12:52:30 <INF> [SDCARD] Basic R/W check started...
[0d00h00m04s] 2024-10-05T12:52:30 <INF> [SDCARD] Basic R/W check successful
[0d00h00m04s] 2024-10-05T12:52:30 <INF> [SNTP] TimeServer not defined, using default: pool.ntp.org
[0d00h00m04s] 2024-10-05T12:52:30 <INF> [SNTP] Configuring NTP Client...
[0d00h00m04s] 2024-10-05T14:52:30 <INF> [SNTP] Time zone set to CET-1CEST,M3.5.0,M10.5.0/3
[0d00h00m04s] 2024-10-05T14:52:30 <INF> [SNTP] time zone: +0200 Delta to UTC: 7200 seconds
[0d00h00m04s] 2024-10-05T14:52:30 <INF> [SNTP] Time is already set: 2024-10-05 14:52:30
[0d00h00m04s] 2024-10-05T14:52:30 <INF> [MAIN] CPU frequency: 240 MHz
[0d00h00m04s] 2024-10-05T14:52:30 <INF> [SDCARD] Folder/file presence check started...
[0d00h00m04s] 2024-10-05T14:52:30 <INF> [SDCARD] Folder/file presence check successful
[0d00h00m04s] 2024-10-05T14:52:30 <INF> [MAIN] Tag: 'v15.7.0', Release: v15.7.0 (Commit: 0d0b018+), Date/Time: 2024-02-17 00:15, Web UI: Release: v15.7.0 (Commit: 0d0b018+)
[0d00h00m04s] 2024-10-05T14:52:30 <INF> [MAIN] Reset reason: Via esp_restart
[0d00h00m05s] 2024-10-05T14:52:30 <INF> [WLANINI] SSID: luftnetz-domotics
[0d00h00m05s] 2024-10-05T14:52:30 <INF> [WLANINI] Password: XXXXXXXX
[0d00h00m05s] 2024-10-05T14:52:30 <INF> [WLANINI] Hostname: water-meter
[0d00h00m05s] 2024-10-05T14:52:30 <INF> [WLANINI] RSSIThreshold: -75
[0d00h00m05s] 2024-10-05T14:52:30 <INF> [MAIN] WLAN config loaded, init WIFI...
[0d00h00m05s] 2024-10-05T14:52:30 <INF> [WIFI] Automatic interface config --> Use DHCP service
[0d00h00m05s] 2024-10-05T14:52:30 <INF> [WIFI] Set hostname to: water-meter
[0d00h00m05s] 2024-10-05T14:52:30 <INF> [WIFI] Init successful
[0d00h00m07s] 2024-10-05T14:52:33 <INF> [WIFI] Connected to: luftnetz-domotics, RSSI: -56
[0d00h00m08s] 2024-10-05T14:52:34 <INF> [WIFI] Assigned IP: 10.3.0.19
[0d00h00m10s] 2024-10-05T14:52:35 <INF> [SNTP] Time is synced with NTP Server pool.ntp.org: 2024-10-05 14:52:35
[0d00h00m11s] 2024-10-05T14:52:36 <INF> [MAIN] Device info: CPU cores: 2, Chip revision: 301
[0d00h00m11s] 2024-10-05T14:52:36 <INF> [MAIN] SD card info: Name: SD32G, Capacity: 30436MB, Free: 30407MB
[0d00h00m13s] 2024-10-05T14:52:38 <INF> [MAIN] Initialization completed successfully
[0d00h00m15s] 2024-10-05T14:52:41 <INF> [LOGFILE] Set log level to ERROR |
Have you tried unplugging the ESP from power and then plugging it back in? |
Seemed to be an OTA update issue. I decreased the AutoTimer Interval from 1 to 10 and OTAed again. The update process took longer and the device is now working. I guess the OTA has issues when a roundtrip is in progress. |
Stumbled upon it again. I'm now trying to decrase CPUFrequency. |
I don't think the interval or OTA has an impact! |
Okay, it's quite random, did not find any pattern to reproduce so far. :-/ |
Then it also could be hardware related. We updated the ESP framework since 15.7.0, so maybe this triggers an issue. |
Tested with another ESP32-CAM with OV2640 camera. Same behavior. It happens after rebooting the device. Sometimes. Cross-testet with 15.7.0 and the behaviour is not reproducable. It definitely has something to do with the new version. |
Same with a 2A power supply. [0d00h00m00s] 2024-10-06T12:25:01 <INF> [MAIN] =================================================
[0d00h00m00s] 2024-10-06T12:25:01 <INF> [MAIN] ==================== Start ======================
[0d00h00m00s] 2024-10-06T12:25:01 <INF> [MAIN] =================================================
[0d00h00m00s] 2024-10-06T12:25:01 <INF> [MAIN] PSRAM size: 8388608 byte (8MB / 64MBit)
[0d00h00m00s] 2024-10-06T12:25:01 <INF> [MAIN] Total heap: 4382779 byte
[0d00h00m02s] 2024-10-06T12:25:03 <WRN> [MAIN] Camera init failed (0xffffffff), retrying...
[0d00h00m04s] 2024-10-06T12:25:05 <ERR> [MAIN] Camera init failed (0x105)! Check camera module and/or proper electrical connection
[0d00h00m04s] 2024-10-06T12:25:05 <ERR> [HELPER] New System Status: 0x00000004
[0d00h00m04s] 2024-10-06T12:25:05 <INF> [SDCARD] Basic R/W check started...
[0d00h00m04s] 2024-10-06T12:25:05 <INF> [SDCARD] Basic R/W check successful
[0d00h00m04s] 2024-10-06T12:25:05 <INF> [SNTP] TimeServer not defined, using default: pool.ntp.org
[0d00h00m04s] 2024-10-06T12:25:05 <INF> [SNTP] Configuring NTP Client...
[0d00h00m04s] 2024-10-06T14:25:05 <INF> [SNTP] Time zone set to CET-1CEST,M3.5.0,M10.5.0/3
[0d00h00m04s] 2024-10-06T14:25:05 <INF> [SNTP] time zone: +0200 Delta to UTC: 7200 seconds
[0d00h00m04s] 2024-10-06T14:25:05 <INF> [SNTP] Time is already set: 2024-10-06 14:25:05
[0d00h00m04s] 2024-10-06T14:25:05 <INF> [MAIN] CPU frequency: 240 MHz
[0d00h00m04s] 2024-10-06T14:25:06 <INF> [SDCARD] Folder/file presence check started...
[0d00h00m04s] 2024-10-06T14:25:06 <INF> [SDCARD] Folder/file presence check successful
[0d00h00m04s] 2024-10-06T14:25:06 <INF> [MAIN] Tag: 'v16.0.0-RC3', Release: v16.0.0-RC3 (Commit: a0333d9+), Date/Time: 2024-10-05 21:10, Web UI: Release: v16.0.0-RC3 (Commit: a0333d9+)
[0d00h00m04s] 2024-10-06T14:25:06 <INF> [MAIN] Reset reason: Via esp_restart
[0d00h00m04s] 2024-10-06T14:25:06 <INF> [WLANINI] SSID: luftnetz-domotics
[0d00h00m04s] 2024-10-06T14:25:06 <INF> [WLANINI] Password: XXXXXXXX
[0d00h00m04s] 2024-10-06T14:25:06 <INF> [WLANINI] Hostname: water-meter
[0d00h00m04s] 2024-10-06T14:25:06 <INF> [WLANINI] RSSIThreshold: -75
[0d00h00m05s] 2024-10-06T14:25:06 <INF> [MAIN] WLAN config loaded, init WIFI...
[0d00h00m05s] 2024-10-06T14:25:06 <INF> [WIFI] Automatic interface config --> Use DHCP service
[0d00h00m05s] 2024-10-06T14:25:06 <INF> [WIFI] Set hostname to: water-meter
[0d00h00m05s] 2024-10-06T14:25:06 <INF> [WIFI] Init successful
[0d00h00m07s] 2024-10-06T14:25:09 <INF> [WIFI] Connected to: luftnetz-domotics, RSSI: -61
[0d00h00m08s] 2024-10-06T14:25:10 <INF> [WIFI] Assigned IP: 10.3.0.19
[0d00h00m08s] 2024-10-06T14:25:10 <INF> [SNTP] Time is synced with NTP Server pool.ntp.org: 2024-10-06 14:25:10
[0d00h00m09s] 2024-10-06T14:25:10 <INF> [MAIN] Device info: CPU cores: 2, Chip revision: 301
[0d00h00m09s] 2024-10-06T14:25:10 <INF> [MAIN] SD card info: Name: SD32G, Capacity: 30436MB, Free: 30405MB
[0d00h00m11s] 2024-10-06T14:25:12 <ERR> [MAIN] Initialization failed. Flow task start aborted. Loading reduced web interface...
[0d00h00m43s] 2024-10-06T14:25:44 <ERR> [FLOWCTRL] ClassFlowControll::GetJPGStream: alg_roi.jpg cannot be served -> alg.jpg is going to be served!
[0d00h00m48s] 2024-10-06T14:25:49 <ERR> [MAIN SERVER] We have a critical error, not serving main page! |
@dandjo If you want you can try the following firmware versions: testfirmware.zip (Simply unpack and update the firmware.bin via OTA) |
@SybexX Tried both versions, couldn't reproduce the error. What's the difference in there? |
For the second version I used esp32-camera-master instead of esp32-camera @ dba8da9. |
This could be a good clue. Do you have any idea why this is happening? And why is especially this commit used? |
It was the last official release of that component when we updated it last time, see https://github.com/espressif/esp32-camera/releases/tag/v2.0.6 |
Hm okay, something seems to fix the issue between 2.0.6 and 2.0.13 (or master). Did check the issues there, but I'm not really familiar with cam stuff. Is updating to latest esp32-camera an option? |
@dandjo If both versions now work without problems, then this should be the fix for it: ClassControllCamera.cpp esp_err_t CCamera::InitCam(void)
{
ESP_LOGD(TAG, "Init Camera");
TickType_t cam_xDelay = 100 / portTICK_PERIOD_MS; <<<<<<<<<<<<<<<<<<<<<<<<<<
CCstatus.ImageQuality = camera_config.jpeg_quality;
CCstatus.ImageFrameSize = camera_config.frame_size;
// De-init in case it was already initialized
esp_camera_deinit();
vTaskDelay(cam_xDelay); <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
// initialize the camera
esp_err_t err = esp_camera_init(&camera_config);
vTaskDelay(cam_xDelay); <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
if (err != ESP_OK) {
ESP_LOGE(TAG, "Camera Init Failed");
return err;
}
CCstatus.CameraInitSuccessful = true;
// Get a reference to the sensor
sensor_t *s = esp_camera_sensor_get();
if (s != NULL) {
CCstatus.CamSensor_id = s->id.PID;
// Dump camera module, warn for unsupported modules.
switch (CCstatus.CamSensor_id)
{
case OV2640_PID:
ESP_LOGI(TAG, "OV2640 camera module detected");
break;
case OV3660_PID:
ESP_LOGI(TAG, "OV3660 camera module detected");
break;
case OV5640_PID:
ESP_LOGI(TAG, "OV5640 camera module detected");
break;
default:
ESP_LOGE(TAG, "Camera module is unknown and not properly supported!");
CCstatus.CameraInitSuccessful = false;
}
}
if (CCstatus.CameraInitSuccessful) {
return ESP_OK;
}
else {
return ESP_FAIL;
}
} |
I usually try to use the latest release since it could contain bug fixes. So yes, we should update it. |
@caco3 I assume that the camera needs some time to start/reset |
Currently testing commit from @SybexX. LGTM so far. [0d00h00m00s] 2024-10-06T20:31:07 <INF> [MAIN] =================================================
[0d00h00m00s] 2024-10-06T20:31:07 <INF> [MAIN] ==================== Start ======================
[0d00h00m00s] 2024-10-06T20:31:07 <INF> [MAIN] =================================================
[0d00h00m00s] 2024-10-06T20:31:07 <INF> [MAIN] PSRAM size: 8388608 byte (8MB / 64MBit)
[0d00h00m00s] 2024-10-06T20:31:07 <INF> [MAIN] Total heap: 4382779 byte
[0d00h00m02s] 2024-10-06T20:31:09 <INF> [MAIN] Camera info: PID: 0x26, VER: 0x42, MIDL: 0x7f, MIDH: 0xa2
[0d00h00m02s] 2024-10-06T20:31:09 <INF> [SDCARD] Basic R/W check started...
[0d00h00m02s] 2024-10-06T20:31:09 <INF> [SDCARD] Basic R/W check successful
[0d00h00m02s] 2024-10-06T20:31:09 <INF> [SNTP] TimeServer not defined, using default: pool.ntp.org
[0d00h00m02s] 2024-10-06T20:31:09 <INF> [SNTP] Configuring NTP Client...
[0d00h00m02s] 2024-10-06T22:31:09 <INF> [SNTP] Time zone set to CET-1CEST,M3.5.0,M10.5.0/3
[0d00h00m02s] 2024-10-06T22:31:09 <INF> [SNTP] time zone: +0200 Delta to UTC: 7200 seconds
[0d00h00m02s] 2024-10-06T22:31:09 <INF> [SNTP] Time is already set: 2024-10-06 22:31:09
[0d00h00m02s] 2024-10-06T22:31:09 <INF> [MAIN] CPU frequency: 240 MHz
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [SDCARD] Folder/file presence check started...
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [SDCARD] Folder/file presence check successful
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [MAIN] Development-Branch: HEAD (Commit: 8c8f30b+), Date/Time: 2024-10-06 20:10, Web UI: Development-Branch: HEAD (Commit: 8c8f30b+)
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [MAIN] Reset reason: Via esp_restart
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [WLANINI] SSID: luftnetz-domotics
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [WLANINI] Password: XXXXXXXX
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [WLANINI] Hostname: water-meter
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [WLANINI] RSSIThreshold: -75
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [MAIN] WLAN config loaded, init WIFI...
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [WIFI] Automatic interface config --> Use DHCP service
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [WIFI] Set hostname to: water-meter
[0d00h00m03s] 2024-10-06T22:31:10 <INF> [WIFI] Init successful
[0d00h00m05s] 2024-10-06T22:31:13 <INF> [WIFI] Connected to: luftnetz-domotics, RSSI: -61
[0d00h00m06s] 2024-10-06T22:31:14 <INF> [WIFI] Assigned IP: 10.3.0.19
[0d00h00m11s] 2024-10-06T22:31:18 <INF> [SNTP] Time is synced with NTP Server pool.ntp.org: 2024-10-06 22:31:18
[0d00h00m11s] 2024-10-06T22:31:18 <INF> [MAIN] Device info: CPU cores: 2, Chip revision: 301
[0d00h00m11s] 2024-10-06T22:31:18 <INF> [MAIN] SD card info: Name: SD32G, Capacity: 30436MB, Free: 30405MB
[0d00h00m13s] 2024-10-06T22:31:20 <INF> [MAIN] Initialization completed successfully
[0d00h00m15s] 2024-10-06T22:31:22 <INF> [TFLITE] Trying to load the model. If it crashes here, it ist most likely due to a corrupted model!
[0d00h00m15s] 2024-10-06T22:31:23 <INF> [TFLITE] Trying to load the model. If it crashes here, it ist most likely due to a corrupted model!
[0d00h00m16s] 2024-10-06T22:31:23 <INF> [LOGFILE] Set log level to ERROR |
The Problem
Updated from 15.7.0 to 16.0.0 RC2 today. Since then the camera is not working.
I'm using this module (OV2640): https://www.amazon.de/dp/B08P1NMPLL
Version
16.0.0-RC2 (Commit: 3708698+)
Logfile
Expected Behavior
No response
Screenshots
No response
Additional Context
My config before:
The text was updated successfully, but these errors were encountered: