MTK MT6735 platform Debug camera driver record

Source: Internet
Author: User

Camera Driver related files:

1, PROJECTCONFIG.MK configuration related information, define the main sub-camera. and other information

2, kd_imgsensor.h definition sensor_id information files, kernel and vendor need to have a copy

3, kd_camera_hw.c kd_camera_hw.h control camera up and down, macros defined in Kd_camera_hw.h

4, Kd_sensorlist.h sensorlist.cpp These two files are defined to add a sensor module, the order of two files must be the same, and the sensor sorting should be from large to small sort. Otherwise error prone.


The following information is slightly chaotic, originally had the chart, the company prohibits the map, also does not bother to tidy up,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,


DWS files need to be opened using software Drgen.exe.

The Drgen.exe file is in the KERNEL-3.10\TOOLS\DCT directory. Use this tool to open the DWS file, modify the configuration, you can set gpio,pmic and so on.

The Enitmode option indicates an interrupt,

Defmode represents the default mode,

Inpull En control can pull high pull low

Inpull Selhigh Select Pull-High pull low.

VarName determines the name used by the macro. These names are used in the code.

Project-related DWS files are in the KERNEL-3.10\DRIVERS\MISC\MEDIATEK\MACH\MT6735\K35V1_64_OP01Q_PRE\DCT\DCT directory.

Effect file in Vendor directory: vendor/mediate/proprietary/custom/mt6735/hal/d1/imgsensor/

Adding drivers requires kd_sensorlist.h to add information to the file. Such as

File in Directory

The front and back information in MTK needs to be kernel-3.10\arch\arm64\configs\

The catalog is added in the project Defconfig file as shown in:

PROJECTCONFIG.MK files in the directory device/mediate/${project}/

The required files and directories are available upon request. It is configured below.

1, configure the Projectconfig.mk file.

Custom_hal_imgsensor = S5k3l2_mipi_raw

Custom_kernel_imgsensor= S5k3l2_mipi_raw

Custom_hal_sub_imgsensor = S5k5e2_mipi_raw

Custom_hal_main_imgsensor = S5k3l2_mipi_raw custom_kernel_main_imgsensor= S5k3l2_mipi_raw

Custom_kernel_sub_imgsensor = S5k5e2_mipi_raw

Custom_kernel_imgsensor= S5k3l2_mipi_raw

2, modify Cmaera related information, such as motor information, if there is no use dummy_lens substitution.

Custom_hal_lens = Dummy_lens

Custom_kernel_lens = Dummy_lens

Custom_hal_main_lens = Dummy_lens

Custom_hal_sub_lens = Dummy_lens

Custom_kernel_main_lens = Dummy_lens

Custom_kernel_sub_lens = Dummy_lens

3, modify the Kd_imgsensor.h

#define S5K3L2_SENSOR_ID 0x20

#define SENSROR _drvname_ s5k3l2 _mipi_raw "S5k3l2mipiraw"

4, modify the KD_CAMERA_HW.C

In this file, there are power-up timings, and clock control

Set Gpio

Power-On

Kd_camera_hw.h to modify the macros used in KD_CAMERA_HW.C.

The definition of what these macros point to is generated by DrvGen.exe under this directory.

Open Codegen.dws file for editing via DrvGen.exe

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

MTK MT6735 platform Debug camera driver record

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.