2020
2121LOG_MODULE_REGISTER (mega_camera , CONFIG_VIDEO_LOG_LEVEL );
2222
23- /* Info default settings */
24- #define SUPPORT_RESOLUTION_5M 7894
25- #define SUPPORT_RESOLUTION_3M 7638
26-
2723/* Configure camera contrast level */
2824enum mega_contrast_level {
2925 MEGA_CONTRAST_LEVEL_NEGATIVE_3 = 6 ,
@@ -236,7 +232,6 @@ struct arducam_mega_ctrls {
236232 };
237233 struct video_ctrl focus_auto ;
238234 /* Read only registers */
239- struct video_ctrl support_resolution ;
240235 struct video_ctrl linkfreq ;
241236};
242237
@@ -792,8 +787,6 @@ static int arducam_mega_check_connection(const struct device *dev)
792787 2592 , 1944 , VIDEO_PIX_FMT_JPEG );
793788 fmts [26 ] = (struct video_format_cap )ARDUCAM_MEGA_VIDEO_FORMAT_CAP (
794789 2592 , 1944 , VIDEO_PIX_FMT_YUYV );
795-
796- drv_data -> ctrls .support_resolution .val = SUPPORT_RESOLUTION_5M ;
797790 drv_data -> features |= MEGA_HAS_FOCUS | MEGA_HAS_COLORFX ;
798791 break ;
799792 case ARDUCAM_SENSOR_3MP_1 :
@@ -804,7 +797,6 @@ static int arducam_mega_check_connection(const struct device *dev)
804797 2048 , 1536 , VIDEO_PIX_FMT_JPEG );
805798 fmts [26 ] = (struct video_format_cap )ARDUCAM_MEGA_VIDEO_FORMAT_CAP (
806799 2048 , 1536 , VIDEO_PIX_FMT_YUYV );
807- drv_data -> ctrls .support_resolution .val = SUPPORT_RESOLUTION_3M ;
808800 drv_data -> features |= MEGA_HAS_SHARPNESS | MEGA_HAS_COLORFX ;
809801 break ;
810802 case ARDUCAM_SENSOR_5MP_2 :
@@ -814,7 +806,6 @@ static int arducam_mega_check_connection(const struct device *dev)
814806 2592 , 1936 , VIDEO_PIX_FMT_JPEG );
815807 fmts [26 ] = (struct video_format_cap )ARDUCAM_MEGA_VIDEO_FORMAT_CAP (
816808 2592 , 1936 , VIDEO_PIX_FMT_YUYV );
817- drv_data -> ctrls .support_resolution .val = SUPPORT_RESOLUTION_5M ;
818809 drv_data -> features |= MEGA_HAS_FOCUS | MEGA_HAS_COLORFX ;
819810 break ;
820811 default :
@@ -1241,13 +1232,6 @@ static int arducam_mega_init_controls(const struct device *dev)
12411232 }
12421233 }
12431234 /* Read only controls */
1244- ret = video_init_ctrl (
1245- & ctrls -> support_resolution , dev , VIDEO_CID_ARDUCAM_SUPP_RES ,
1246- (struct video_ctrl_range ){.min = 0 , .max = 65535 , .step = 1 , .def = 0 });
1247- ctrls -> support_resolution .flags |= VIDEO_CTRL_FLAG_READ_ONLY ;
1248- if (ret < 0 ) {
1249- return ret ;
1250- }
12511235 ret = video_init_int_menu_ctrl (
12521236 & ctrls -> linkfreq , dev , VIDEO_CID_LINK_FREQ , ARDUCAM_MEGA_640_480_LINK_FREQ_ID ,
12531237 arducam_mega_link_frequency , ARRAY_SIZE (arducam_mega_link_frequency ));
0 commit comments