当前位置:网站首页>Sensor bringup 中的一些问题总结
Sensor bringup 中的一些问题总结
2022-06-12 06:04:00 【一只特立独行的zhu..】
1、背景:
一般我们在调试一款sensor 的效果时,首先要先把他点亮,也叫 sensor bringup,这部分工作大都由驱动工程师来完成,但有时也是需要tuning 工程师来做的,但其实如果顺利的化,在sensor驱动中配置好sensor setting,、i2c地址、sensor的chip_id,就可以出图了,但大多数情况下,往往不会那么顺利,会遇到很多的问题,这里总结一下,整个sensor bringup的流程,以及遇到的一些问题;
2、Sensor bringup 流程:
- 向 sensor 原厂申请所需规格的Sensor setting,如分辨率、平台的Mclk、帧率、输出raw图的位宽、mipi_lane数,必要时说明下不能超过平台所能支持的最大mipi速率;
- 拿到setting后,进行sensor 驱动的配置,先配置好sensor setting、I2C地址、chip_id;
- 拿到主板的原理图,确认硬件相关配置,根据主板原理图在dts中配置mclk、reset、pwrdn、i2c 的引脚控制;
- 如上步骤完成后,硬件没啥问题的话,基本就可以点亮出图了,接着再根据sensor datasheet,详细配置sensor 的曝光时间,模拟增益等寄存器就可以了 ;
3、问题总结:
a、怎么确定 reset、pwrdn、i2c、mclk的引脚 ?
首先得学会看原理图,一开始拿到图看我是很懵的,乱七八糟感觉东西太多了,不知道从哪里看起,其实要关注的地方不是很多,不需要把整张图看懂,因为我们主要就是配置camera,所以找到MIPI_CSI接口部分,如下图a,只关注CM_RST_L (reset)、CM_PWRDN (pwrdn)、CM_I2C_SCL(i2c_clk)、CM_I2C_SDA( i2c_data )、CM_MCLK (mclk)几个控制引脚就可以了,以mclk为例,我们先找到图a的mipi_csi部分的CM_MCLK ——> 图b MCLK_0 ——>图c的 MCLK_0——> 主控的GPIOA_0 ,实际就是依次往上查找,直到主控的引脚上。
b、I2C不通 ?
- i2c地址配的不对:一般i2c有两个地址,电平拉高拉低是不同的,如下图是sc4335p的I2C地址说明,还有如下地址是7bit地址,一般驱动默认配置是8bit地址,所以驱动中配置时要左移1位,变成0x60。

- 查看硬件 电源的问题 AVDD,DVDD,IOVDD,有的硬件的三个电源是常供电,有的三个电源是用软件来控制的 如果是用软件控制的,需要在驱动中添加这个三个电源的控制引脚。
- mclk 引脚配置的不对:可以用示波器量下提供给sensor的时钟是否有,或者时钟是否对,如:24MHz、27MHz。
- i2c引脚配置的不对:一般可查看主控相应 pinmux-pins文件,确认相应的GPIO是否已经定义对了;

- reset、pwrdn引脚控制的不对:首先dts中要配置好相应的reset、pwrdn的引脚,接着sensor 驱动中去控制拉低、拉高,具体根据sensor datasheet的时序图来确认,如下是ov02k10的时序图,只有reset拉高的操作,就可以了,没有pwrdn的操作;

c、不出图或者出图异常;
- ISP这边输指令查下mipi的传输是否有err。
- 可以用示波器量下mipi信号。
- 抓raw图看下是否有异常,如果raw图也有异常一般都是sensor setting的问题,找sensor原厂的人去看。
- 提高增益后有竖条纹(也叫FPN),和sensor相关,一般找sensor 原厂处理;

- 低照度下有横条纹,一般和硬件相关,电源噪声或者器件的干扰;

边栏推荐
- Mysql笔记
- MySQL 主从,6 分钟带你掌握
- Liunx Foundation
- Front desk display LED number (number type on calculator)
- nus_ data_ Handler source code interprets data types such as structure
- Findasync and include LINQ statements - findasync and include LINQ statements
- E-book analysis
- Unity VSCode不能跳转到定义
- Why is the union index the leftmost matching principle?
- Makefile文件编写快速掌握
猜你喜欢

Introduction to redis high availability

A preliminary understanding of function

Annotation configuration of filter

sqlite交叉編譯動態庫

IDEA常用配置

Front desk display LED number (number type on calculator)

Chapter 7 - pointer learning

Execute sh script to prompt "[[: not found" solution. The difference between Bash and sh

Why doesn't the database use binary tree, red black tree, B tree and hash table? Instead, a b+ tree is used

IBL of directx11 advanced tutorial PBR (3)
随机推荐
Json-c common APIs
Leetcode-1512. Number of good pairs
How to split a row of data into multiple rows in Informix database
Directx11 advanced tutorial tiled based deffered shading
Leetcode-1552. Magnetic force between two balls
sqlite交叉编译动态库
How to increase heap size of JVM [duplicate] - how to increase heap size of JVM [duplicate]
IDEA常用配置
Login authentication filter
R language homework (IV): GDP value analysis of Shanghai and Tokyo from 1997 to 2018
Divide a folder image into training set and test set
log4j 1. X upgrade to 2 Solution of X dependency incompatibility
[untitled]
Jackson - how to convert the array string with only one map object to list < map >
Guns framework multi data source configuration without modifying the configuration file
Research Report on truffle fungus industry - market status analysis and development prospect forecast
Oracle EBS interface/api (34) - update vendor API
cv2.fillPoly coco annotator segment坐标转化为mask图像
Poisson disk sampling for procedural placement
[Yu Yue education] basic reference materials of accounting of Nanjing Normal University