Ubiquitous/RT_Thread/:update the ov2640 driver

1.can choose the output format:rgb565 or jpeg
2.resolution and window size can be configured directly
3.add the test that the lcd can show rgb565 image in time
This commit is contained in:
chunyexixiaoyu
2022-01-18 15:58:33 +08:00
parent 1c5047f47a
commit 0dee89982a
5 changed files with 130 additions and 50 deletions

View File

@@ -46,8 +46,8 @@ void k210_detect(char *json_file_path)
printf("open ov2640 fail !!");
return;
}
_ioctl_set_dvp_reso set_dvp_reso = {detect_params.sensor_output_size[1], detect_params.sensor_output_size[0]};
ioctl(g_fd, IOCTRL_CAMERA_SET_DVP_RESO, &set_dvp_reso);
_ioctl_set_reso set_dvp_reso = {detect_params.sensor_output_size[1], detect_params.sensor_output_size[0]};
ioctl(g_fd, IOCTRL_CAMERA_OUT_SIZE_RESO, &set_dvp_reso);
showbuffer =
(unsigned char *)rt_malloc_align(detect_params.sensor_output_size[0] * detect_params.sensor_output_size[1] * 2, 64);
if (NULL == showbuffer) {