Bootstrap

CAMERA调试

一. 此处以Kernel4.19,添加后摄像头GC5035为例,介绍配置路径:
1. 内核配置文件与HAL配置文件:
1.1. kernel-4.19\arch\arm\configs\k39tv1_bsp_1g_k419_debug_defconfig 与 kernel-4.19\arch\arm\configs\k39tv1_bsp_1g_k419_defconfig
CONFIG_CUSTOM_KERNEL_IMGSENSOR="gc5035mipi_raw"
1.2.device\mediateksample\k39tv1_bsp_k419\ProjectConfig.mk --- 假设此处使用k39tv1_bsp_k419配置
CUSTOM_HAL_IMGSENSOR =  gc5035mipi_raw
CUSTOM_HAL_MAIN_IMGSENSOR = gc5035mipi_raw 
CUSTOM_KERNEL_IMGSENSOR =  gc5035mipi_raw
CUSTOM_KERNEL_MAIN_IMGSENSOR =  gc5035mipi_raw

2. 驱动实现主代码如下位置:
kernel-4.19\drivers\misc\mediatek\imgsensor\src\common\v1\gc5035mipi_raw

3. 定义NAME和ID,需添加如下两个文件:
3.1. ./device/mediatek/common/kernel-headers/kd_imgsensor.h
#define GC5035MIPI_SENSOR_ID                        0x5035
#define SENSOR_DRVNAME_GC5035MIP

;