ESP32S3 OV3660更改频率无法运行

bifenggang
Posts: 28
Joined: Tue Jul 06, 2021 3:19 am

ESP32S3 OV3660更改频率无法运行

Postby bifenggang » Fri Oct 13, 2023 6:08 am

ESP32S3,OV3660例程XCLK频率全部为20M,我改为24M结果一直无法正常初始化,我看官方说频率与分辨率要对应,下面是程序以及日志:
//XCLK 20MHz or 10MHz for OV2640 double FPS (Experimental)
.xclk_freq_hz = 24000000,
.ledc_timer = LEDC_TIMER_0,
.ledc_channel = LEDC_CHANNEL_0,

.pixel_format = PIXFORMAT_GRAYSCALE,//PIXFORMAT_JPEG, //YUV422,GRAYSCALE,RGB565,JPEG
.frame_size = FRAMESIZE_SVGA ,//FRAMESIZE_VGA, //QQVGA-UXGA Do not use sizes above QVGA when not JPEG

日志[0;32mI (934) s3 ll_cam: DMA Channel=4[0m
[0;32mI (934) cam_hal: cam init ok[0m
[0;32mI (943) sccb: pin_sda 5 pin_scl 4[0m
[0;32mI (944) gpio: GPIO[15]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0 [0m
[0;32mI (986) camera: Detected camera at address=0x3c[0m
[0;32mI (987) camera: Detected OV3660 camera[0m
[0;32mI (987) camera: Camera PID=0x3660 VER=0x00 MIDL=0x00 MIDH=0x00[0m
[0;32mI (1303) s3 ll_cam: node_size: 4000, nodes_per_line: 1, lines_per_node: 5[0m
[0;32mI (1312) s3 ll_cam: dma_half_buffer_min: 4000, dma_half_buffer: 16000, lines_per_half_buffer: 20, dma_buffer_size: 32000[0m
[0;32mI (1312) cam_hal: buffer_size: 32000, half_buffer_size: 16000, node_buffer_size: 4000, node_cnt: 8, total_cnt: 30[0m
[0;32mI (1333) cam_hal: Allocating 480000 Byte frame buffer in PSRAM[0m
[0;32mI (1333) cam_hal: Allocating 480000 Byte frame buffer in PSRAM[0m
[0;31mE (1343) cam_hal: EV-VSYNC-OVF[0m
[0;31mE (1344) cam_hal: FB-SIZE: 0 != 480000[0;31mE (1344) cam_hal: EV-VSYNC-OVF[0m
[0;31mE (1344) cam_hal: EV-VSYNC-OVF[0m
[0;31mE (1344) cam_hal: EV-VSYNC-OVF[0m
[0;31mE (1344) cam_hal: EV-VSYNC-OVF[0m
[0;31mE (1344) cam_hal: EV-VSYNC-OVF[0m
[0;31mE (1344) cam_hal: EV-VSYNC-OVF[0m

ESP_WangYX
Posts: 97
Joined: Mon Jun 28, 2021 12:48 pm

Re: ESP32S3 OV3660更改频率无法运行

Postby ESP_WangYX » Fri Oct 13, 2023 6:18 am

是的,时钟不能设置为 24M,建议使用 10M、20M等可以被 80M 整除的时钟配置。

bifenggang
Posts: 28
Joined: Tue Jul 06, 2021 3:19 am

Re: ESP32S3 OV3660更改频率无法运行

Postby bifenggang » Mon Oct 23, 2023 6:28 am

你好,我换了20M的晶振,还是不能正常运行,以下是日志,麻烦给看下谢谢
[0;32mI (572) camera wifi: wifi init finished.[0m
[0;32mI (577) s3 ll_cam: DMA Channel=4[0m
[0;32mI (581) cam_hal: cam init ok[0m
[0;32mI (584) sccb: pin_sda 5 pin_scl 4[0m
[0;32mI (588) sccb: sccb_i2c_port=1[0m
[0;32mI (592) gpio: GPIO[15]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0 [0m
[0;32mI (633) camera: Detected camera at address=0x3c[0m
[0;32mI (634) camera: Detected OV3660 camera[0m
[0;32mI (634) camera: Camera PID=0x3660 VER=0x00 MIDL=0x00 MIDH=0x00[0m
[0;32mI (947) s3 ll_cam: node_size: 3840, nodes_per_line: 1, lines_per_node: 6[0m
[0;32mI (947) s3 ll_cam: dma_half_buffer_min: 3840, dma_half_buffer: 15360, lines_per_half_buffer: 24, dma_buffer_size: 30720[0m
[0;32mI (955) cam_hal: buffer_size: 30720, half_buffer_size: 15360, node_buffer_size: 3840, node_cnt: 8, total_cnt: 10[0m
[0;32mI (966) cam_hal: Allocating 153600 Byte frame buffer in PSRAM[0m
[0;32mI (972) cam_hal: Allocating 153600 Byte frame buffer in PSRAM[0m
cam_hal: EV-VSYNC-OVF
cam_hal: EV-VSYNC-OVF
cam_hal: EV-VSYNC-OVF
cam_hal: EV-VSYNC-OVF

ESP_WangYX
Posts: 97
Joined: Mon Jun 28, 2021 12:48 pm

Re: ESP32S3 OV3660更改频率无法运行

Postby ESP_WangYX » Tue Nov 07, 2023 2:46 am

当前的帧率太快了,你可以使用大一点的分辨率 VGA 试试。
如果你需要的分辨率很小,应该考虑使用慢一点的时钟,帧率会降低一些,让 MCU 有能力处理的及时。

Who is online

Users browsing this forum: No registered users and 8 guests