Method for judging whether burning data of camera module is correctly loaded
Through automatic exposure and AWB parameter settings, combined with machine learning and differentiated burning protocols, the problem of judging camera module burning data is solved, and efficient and accurate image debugging effects are achieved.
Patent Information
- Application Number
- CN202510602107.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-12
- Publication Date
- 2025-09-05
AI Technical Summary
It is difficult to efficiently determine whether the camera module burning data is loaded correctly in the existing technology, which affects the image debugging effect. Differences in personal subjective cognition make it difficult to detect subtle differences.
By automatically exposing and setting AWB parameters, adjusting the G value for different platforms (MTK and Qualcomm), capturing Raw images to determine the color cast of the picture, combining machine learning to assist in determining the color cast effect, and burning LSC parameters through the I2C protocol, using differentiated protocols and binary-to-decimal conversion to ensure image quality standards.
It can effectively judge whether the camera module burning data is loaded correctly, and the image effect is obviously different, which makes it easy to identify color cast and improves the accuracy and efficiency of image debugging.
Smart Images

Figure CN120602637A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of camera module imaging effects, and in particular to a method for determining whether camera module burned data is correctly loaded. Background Art
[0002] OTP programming (or Eeprom programming) plays an increasingly important role in the manufacturing process of modern camera modules and has become one of the key steps affecting the imaging effect of the module.
[0003] Camera module manufacturers use Eeprom to store parameters such as Module Information, AWB, Lens Shading, and AF position. These parameters are typically processed by camera module manufacturers on the production line, a process known in the industry as camera calibration. Camera module manufacturers perform calibration based on the required environment for each parameter, such as light source color temperature, illumination, and test distance. These calibration parameters are then stored in the module's Eeprom. This process is called programming. After powering up the module, the end customer reads the data from the camera module's Eeprom and applies various algorithms to process the image, ultimately presenting a perfect image. Therefore, correctly accessing and applying the data programmed by the camera module manufacturer is crucial to image debugging results. Typically, the success of this programming is determined by directly checking the results on the device. However, sometimes, due to personal oversight or subjective perception, subtle differences can be difficult to detect from the image alone. Summary of the Invention
[0004] In view of the technical defects and technical drawbacks existing in the prior art, the embodiments of the present invention provide a method for determining whether the camera module burning data is correctly loaded to overcome the above problems or at least partially solve the above problems. The specific solution is as follows:
[0005] A method for determining whether camera module burning data is correctly loaded, the method comprising:
[0006] Step 1: After the camera module is turned on, automatically expose it. For the MTK platform, adjust the G value to 160-180. For the Qualcomm platform, adjust the G value to 190-210.
[0007] Step 2: Set the AWB parameters and determine whether the image color has the expected color cast, including:
[0008] For the MTK platform, set the R channel separately and keep the GR, GB, and B channels burning normally, or set the B channel value separately and keep the GR, GB, and R channels burning normally. Capture a Raw image and determine whether the image color reaches the expected color cast. If so, the OTP call is considered successful. Otherwise, the OPT call is considered failed:
[0009] For Qualcomm platforms, set the R / G values separately and keep B / G and Gb / Gr burning normally, or set the B / G values separately and keep R / G and Gb / Gr burning normally (B / G and Gb / Gr are the default values). Capture a Raw image and determine whether the image color meets the expected color cast. If so, the OTP call is considered successful; otherwise, the OPT call is considered failed.
[0010] Step 3: If the OTP call is successful, it means the programming data is loaded correctly.
[0011] Furthermore, for the MTK platform, the R channel is set separately and the GR, GB and B channels are kept burning normally, or the B channel value is set separately and the GR, GB and R channels are kept burning normally, a Raw image is captured, and it is determined whether the color of the image reaches the expected color cast. If so, it is determined that the OTP call is successful, otherwise it is determined that the OPT call fails. Specifically, it includes:
[0012] For MTK platform:
[0013] Set the R channel value to less than 40 and keep the GR, GB, and B channels burning normally (that is, the GR, GB, and B channels are at their default values). Capture a Raw image and check whether the image is reddish. If so, the OTP call is successful. Otherwise, the OPT call fails.
[0014] Alternatively, set the B channel value to less than 40 and keep the GR, GB, and R channels burning normally. Then grab a Raw image and determine whether the image is bluish. If so, the OTP call is successful. Otherwise, the OPT call fails.
[0015] Furthermore, for the Qualcomm platform, the R / G values are set separately and the B / G and Gb / Gr values are kept normal, or the B / G values are set separately and the R / G and Gb / Gr values are kept normal (B / G and Gb / Gr are the default values), a Raw image is captured, and it is determined whether the image color reaches the expected color cast. If so, it is determined that the OTP call is successful, otherwise it is determined that the OPT call fails. Specifically, it includes:
[0016] For Qualcomm platforms:
[0017] Set R / G to 0.04-0.07 and keep B / G and Gb / Gr burning normally (B / G and Gb / Gr are the default values). Capture a Raw image and check whether the image is reddish. If so, the OTP call is successful. Otherwise, the OTP call fails.
[0018] Alternatively, set B / G to 0.04-0.07 and keep R / G and Gb / Gr burning normally, capture a Raw image, and determine whether the image is blue. If so, the OTP call is successful, otherwise the OTP call fails.
[0019] Furthermore, the method further includes: after the camera module is turned on and automatically exposed, setting LSC parameters, specifically including:
[0020] For MTK platform:
[0021] Burn all 5x5 blocks of the upper left of the R channel, the lower left of the B channel, the upper right of the Gr channel, and the lower right of the Gb channel to 8192;
[0022] For Qualcomm platforms:
[0023] Burn all 5x5 blocks of the upper left of the R channel, the lower left of the B channel, the upper right of the Gr channel, and the lower right of the Gb channel to 10.
[0024] Furthermore, the method also includes: using differentiated protocols for the burning parameters of the MTK platform and the Qualcomm platform, wherein the MTK platform burns the 5x5 block of LSC parameters through the I2C protocol; the Qualcomm platform burns the 5x5 block of LSC parameters through the I2C protocol, and the burning value needs to be converted from binary to decimal and adapted.
[0025] Furthermore, when the tooling is used to capture the Raw image, the following operations are performed through an automated script:
[0026] Automatically identify the platform type on which the module is mounted, which includes the MTK platform or the Qualcomm platform;
[0027] Call the corresponding parameter template according to the platform type;
[0028] Perform noise analysis and color gamut distribution detection on the captured Raw images to ensure that the image data meets the preset quality standards.
[0029] Furthermore, the method further includes: if it is detected that the image color does not achieve the expected color cast effect, triggering parameter re-burning or alarm prompting.
[0030] Furthermore, the confirmation of the color cast effect includes the following steps:
[0031] After converting the Raw image to RGB format, calculate the average value of the R / G / B channels in the central area of the image (accounting for ≥70%);
[0032] For red color cast, the R channel mean must be ≥ 150% of the B channel mean;
[0033] For blue color cast, the B channel mean must be ≥ 150% of the R channel mean.
[0034] Furthermore, machine learning is used to assist in determining the color cast effect, including
[0035] Train a convolutional neural network (CNN) model with raw image input and color cast type (red / blue) and confidence level as output;
[0036] When the confidence level is ≥95%, it is judged as qualified, otherwise the manual re-inspection process is triggered.
[0037] Furthermore, the AWB parameter settings include dynamic adjustment strategies:
[0038] After the module is burned for the first time, the noise ratio of the R / G / B channels is calculated in real time based on the captured Raw image;
[0039] If the noise ratio exceeds the threshold (≥20dB), the color cast intensity is automatically reduced (the R or B value is reduced by 10% to 20%). The calculation of the noise ratio in the dynamic adjustment strategy includes:
[0040] Divide the raw image into 9 regions (3x3 grid);
[0041] Calculate the standard deviation of the R / G / B channels of each area respectively, and take the maximum value as the noise ratio judgment value;
[0042] When the noise ratio of any area exceeds the threshold, only the programming parameters corresponding to this area will be adjusted downward.
[0043] The present invention has the following beneficial effects:
[0044] The present invention is for the MTK platform, and independently sets the R channel and keeps the GR, GB and B channels burning normally, or independently sets the value of the B channel and keeps the GR, GB and R channels burning normally; and is for the Qualcomm platform, and independently sets the R / G values and keeps the B / G and Gb / Gr burning normally, or independently sets the B / G values and keeps the R / G and Gb / Gr burning normally, thereby enlarging the effect difference of the image and making the image more obviously different, making it convenient to judge whether the picture color reaches the expected color cast, and thus efficiently judging whether the camera module burning data is correctly loaded. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] Figure 1 A flow chart of a method for determining whether the camera module burning data is loaded correctly is provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0046] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0047] like Figure 1 FIG. 1 is a flowchart of a method for determining whether camera module burning data is correctly loaded according to an embodiment of the present invention, the method comprising:
[0048] Step 1: After the camera module is turned on, automatically expose it. For the MTK platform, adjust the G value to 160-180. For the Qualcomm platform, adjust the G value to 190-210.
[0049] Step 2: Set the AWB parameters and determine whether the image color has the expected color cast, including:
[0050] For the MTK platform, set the R channel separately and keep the GR, GB, and B channels burning normally, or set the B channel value separately and keep the GR, GB, and R channels burning normally. Capture a Raw image and determine whether the image color reaches the expected color cast. If so, the OTP call is considered successful. Otherwise, the OPT call is considered failed:
[0051] For Qualcomm platforms, set the R / G values separately and keep B / G and Gb / Gr burning normally, or set the B / G values separately and keep R / G and Gb / Gr burning normally (B / G and Gb / Gr are the default values). Capture a Raw image and determine whether the image color meets the expected color cast. If so, the OTP call is considered successful; otherwise, the OPT call is considered failed.
[0052] Step 3: If the OTP call is successful, it means the programming data is loaded correctly.
[0053] Among them, for the MTK platform, the R channel is set separately and the GR, GB and B channels are kept burning normally, or the B channel value is set separately and the GR, GB and R channels are kept burning normally, a Raw image is captured, and it is determined whether the color of the picture reaches the expected color cast. If so, it is determined that the OTP call is successful, otherwise it is determined that the OPT call fails. Specifically include:
[0054] For MTK platform:
[0055] Set the R channel value to 35 and keep the GR, GB, and B channels burning normally (that is, the GR, GB, and B channels are set to the default values). Capture a Raw image and determine whether the image is reddish. If so, the OTP call is successful. Otherwise, the OPT call fails.
[0056] Alternatively, set the B channel value to 35 alone and keep the GR, GB, and R channels burning normally, grab a Raw image, and determine whether the image is bluish. If so, the OTP call is successful, otherwise it is determined that the OPT call failed.
[0057] For the Qualcomm platform, set the R / G values separately and keep B / G and Gb / Gr burning normally, or set the B / G values separately and keep R / G and Gb / Gr burning normally (B / G and Gb / Gr are default values), capture a Raw image, and determine whether the image color reaches the expected color cast. If so, the OTP call is judged to be successful, otherwise the OPT call is judged to have failed. Specifically include:
[0058] For Qualcomm platforms:
[0059] Set R / G to 0.04 and keep B / G and Gb / Gr as normal (B / G and Gb / Gr are the default values). Capture a Raw image and check whether the image is reddish. If so, the OTP call is successful. Otherwise, the OPT call fails.
[0060] Alternatively, set B / G to 0.04 and keep R / G and Gb / Gr burning normally, capture a Raw image, and determine whether the image is blue. If so, the OTP call is successful, otherwise the OTP call fails.
[0061] The present invention is for the MTK platform, and independently sets the R channel and keeps the GR, GB and B channels burning normally, or independently sets the value of the B channel and keeps the GR, GB and R channels burning normally; and is for the Qualcomm platform, and independently sets the R / G values and keeps the B / G and Gb / Gr burning normally, or independently sets the B / G values and keeps the R / G and Gb / Gr burning normally, thereby enlarging the effect difference of the image and making the image more obviously different, making it convenient to judge whether the picture color reaches the expected color cast, and thus efficiently judging whether the camera module burning data is correctly loaded.
[0062] In some embodiments, the method further includes: after the camera module is turned on and automatically exposed, setting LSC parameters, specifically including:
[0063] For MTK platform:
[0064] Burn all 5x5 blocks of the upper left of the R channel, the lower left of the B channel, the upper right of the Gr channel, and the lower right of the Gb channel to 8192;
[0065] For Qualcomm platforms:
[0066] Burn all 5x5 blocks of the upper left of the R channel, the lower left of the B channel, the upper right of the Gr channel, and the lower right of the Gb channel to 10.
[0067] In China, differentiated protocols are used for programming parameters of MTK and Qualcomm platforms. The MTK platform programs the 5x5 block of LSC parameters through the I2C protocol; the Qualcomm platform programs the 5x5 block of LSC parameters through the I2C protocol, and the programming values need to be converted from binary to decimal.
[0068] In the embodiment of the present invention, MTK data is divided into 15*15 blocks, and 5*5 is exactly 1 / 3. Too few blocks are not obvious, and too many blocks are unnecessary. 8192 is determined by the rules of the MTK platform, which is equivalent to a standard coefficient. Other data are multiplied by 8192, and 8192 is the minimum value. The same applies to the Qualcomm platform.
[0069] In some embodiments, when a tool is used to capture a Raw image, the tool performs the following operations through an automated script:
[0070] Automatically identify the platform type on which the module is mounted, which includes the MTK platform or the Qualcomm platform;
[0071] Call the corresponding parameter template according to the platform type;
[0072] Perform noise analysis and color gamut distribution detection on the captured Raw images to ensure that the image data meets the preset quality standards.
[0073] In some embodiments, the method further includes: if it is detected that the image color does not achieve the expected color cast effect, triggering parameter re-burning or an alarm prompt.
[0074] The confirmation of the color cast effect includes the following steps:
[0075] After converting the Raw image to RGB format, calculate the average value of the R / G / B channels in the central area of the image (accounting for ≥70%);
[0076] For red color cast, the R channel mean must be ≥ 150% of the B channel mean;
[0077] For blue color cast, the B channel mean must be ≥ 150% of the R channel mean.
[0078] In some embodiments, machine learning is used to assist in determining the color cast effect, specifically including:
[0079] Train a convolutional neural network (CNN) model with raw image input and color cast type (red / blue) and confidence level as output;
[0080] When the confidence level is ≥95%, it is judged as qualified, otherwise the manual re-inspection process is triggered.
[0081] In some embodiments, the setting of AWB parameters includes dynamically adjusting the strategy:
[0082] After the module is burned for the first time, the noise ratio of the R / G / B channels is calculated in real time based on the captured Raw image;
[0083] If the noise ratio exceeds the threshold (≥20dB), the color cast intensity is automatically reduced (the R or B value is reduced by 10% to 20%). The calculation of the noise ratio in the dynamic adjustment strategy includes:
[0084] Divide the Raw image into multiple regions;
[0085] The standard deviation of the R / G / B channels in each area is calculated separately, and the maximum value is taken as the noise ratio judgment value. When the noise ratio of any area exceeds the threshold, only the corresponding burning parameters of this area are adjusted downward.
[0086] The conditions for capturing the Raw image include:
[0087] The light intensity was set at 500 ± 50 lux;
[0088] The exposure time is fixed at 15ms;
[0089] The angle error between the module and the test chart is ≤1°.
[0090] In some embodiments, LSC parameter programming includes multi-module synchronous calibration:
[0091] Connect at least 4 modules simultaneously through the SPI interface;
[0092] The main control end issues programming commands in batches and verifies the programming feedback signals of each module;
[0093] If any module feedback is abnormal, the process will be suspended and an error code will be generated (the error code is associated with the specific module ID).
[0094] In the multi-module synchronous calibration, the master terminal adopts a time slice polling mechanism, including:
[0095] Allocate a 10ms communication time window to each module;
[0096] The check signal contains a 16-bit CRC check code;
[0097] The error code generation rule is: the first 8 digits identify the module ID, and the last 8 digits identify the error type.
[0098] Those skilled in the art will appreciate that the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Furthermore, the present application may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0099] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the steps in the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0100] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0101] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0102] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be covered by the scope of protection of the claims of the present invention.
Claims
1. A method for determining whether the camera module burning data is loaded correctly, characterized in that: The method comprises: Step 1: After the camera module is turned on, automatically expose it. For the MTK platform, adjust the G value to 160-180. For the Qualcomm platform, adjust the G value to 190-210. Step 2: Set the AWB parameters and determine whether the image color has the expected color cast, including: For the MTK platform, set the R channel separately and keep the GR, GB, and B channels burning normally, or set the B channel value separately and keep the GR, GB, and R channels burning normally. Capture a Raw image and determine whether the image color reaches the expected color cast. If so, the OTP call is considered successful. Otherwise, the OPT call is considered failed: For Qualcomm platforms, set the R / G values separately and keep B / G and Gb / Gr burning normally, or set the B / G values separately and keep R / G and Gb / Gr burning normally, capture a Raw image, and determine whether the image color meets the expected color cast. If so, the OTP call is considered successful, otherwise the OPT call is considered failed. Step 3: If the OTP call is successful, it means the programming data is loaded correctly.
2. The method for determining whether the camera module burning data is correctly loaded according to claim 1, wherein: For the MTK platform, the R channel is set separately and the GR, GB and B channels are kept burning normally, or the B channel value is set separately and the GR, GB and R channels are kept burning normally. A Raw image is captured to determine whether the image color reaches the expected color cast. If so, the OTP call is judged to be successful. Otherwise, the OPT call is judged to have failed. Specifically, the following steps are included: For MTK platform: Set the R channel value to less than 40 and keep the GR, GB, and B channels burning normally (that is, the GR, GB, and B channels are at their default values). Capture a Raw image and check whether the image is reddish. If so, the OTP call is successful. Otherwise, the OPT call fails. Alternatively, set the B channel value to less than 40 and keep the GR, GB, and R channels burning normally. Then grab a Raw image and determine whether the image is bluish. If so, the OTP call is successful. Otherwise, the OPT call fails.
3. The method for determining whether the camera module burning data is correctly loaded according to claim 1, wherein: For the Qualcomm platform, set the R / G values separately and keep B / G and Gb / Gr burning normally, or set the B / G values separately and keep R / G and Gb / Gr burning normally, capture a Raw image, and determine whether the image color reaches the expected color cast. If so, it is determined that the OTP call is successful, otherwise it is determined that the OPT call failed. Specifically include: For Qualcomm platforms: Set R / G to 0.04-0.07 and keep B / G and Gb / Gr burning normally. Capture a Raw image and check whether the image is reddish. If so, the OTP call is successful. Otherwise, the OTP call fails. Alternatively, set B / G to 0.04-0.07 and keep R / G and Gb / Gr burning normally, capture a Raw image, and determine whether the image is blue. If so, the OTP call is successful, otherwise the OTP call fails.
4. The method for determining whether the camera module burning data is correctly loaded according to claim 1, wherein: The method further includes: after the camera module is turned on and automatically exposed, setting LSC parameters, specifically including: For MTK platform: Burn all 5x5 blocks of the upper left of the R channel, the lower left of the B channel, the upper right of the Gr channel, and the lower right of the Gb channel to 8192; For Qualcomm platforms: Burn all 5x5 blocks of the upper left of the R channel, the lower left of the B channel, the upper right of the Gr channel, and the lower right of the Gb channel to 10.
5. The method for determining whether the camera module burning data is correctly loaded according to claim 4, wherein: The method also includes: using differentiated protocols for the burning parameters of the MTK platform and the Qualcomm platform, wherein the MTK platform burns the 5x5 block of LSC parameters through the I2C protocol; the Qualcomm platform burns the 5x5 block of LSC parameters through the I2C protocol, and the burning value needs to be converted from binary to decimal and adapted.
6. The method for determining whether the camera module burning data is correctly loaded according to claim 1, wherein: The tooling is used to capture the raw image. When the tooling captures the raw image, the following operations are performed through an automated script: Automatically identify the platform type on which the module is mounted, which includes the MTK platform or the Qualcomm platform; Call the corresponding parameter template according to the platform type; Perform noise analysis and color gamut distribution detection on the captured Raw images to ensure that the image data meets the preset quality standards.
7. The method for determining whether the camera module burning data is correctly loaded according to claim 1, wherein: The method further includes: if it is detected that the image color does not achieve the expected color cast effect, triggering parameter re-burning or alarm prompting.
8. The method for determining whether the camera module burning data is correctly loaded according to claim 7, wherein: Confirmation of the color cast effect includes the following steps: After converting the Raw image to RGB format, calculate the average value of the R / G / B channels in the central area of the image; For red color cast, the R channel mean must be ≥ 150% of the B channel mean; For blue color cast, the B channel mean must be ≥ 150% of the R channel mean.
9. The method for determining whether the camera module burning data is correctly loaded according to claim 8, wherein: Machine learning is used to assist in determining color cast effects, including: Train the convolutional neural network model, with the input being the raw image and the output being the color cast type and confidence level; When the confidence level is ≥95%, it is judged as qualified, otherwise the manual re-inspection process is triggered.
10. The method for determining whether the camera module burning data is correctly loaded according to claim 1, characterized in that The AWB parameter settings include dynamic adjustment strategies: After the module is burned for the first time, the noise ratio of the R / G / B channels is calculated in real time based on the captured Raw image; If the noise ratio exceeds the threshold, the color cast intensity is automatically reduced. The calculation of the noise ratio in the dynamic adjustment strategy includes: Divide the Raw image into multiple regions; Calculate the standard deviation of the R / G / B channels of each area respectively, and take the maximum value as the noise ratio judgment value; When the noise ratio of any area exceeds the threshold, only the programming parameters corresponding to this area will be adjusted downward.