Firefly开源社区

12
发表新贴

RK3288-reload MIPI 摄像头问题 无图像黑屏

118

积分

0

威望

0

贡献

技术小白

积分
118
发表于 2017-11-18 16:53:10     
RK3288-reload开发板调试MIPI摄像头打开黑色画面(I2C通信也正常,MIPI0 数据线上通过示波器看也有数据),串口直接输出以及日志记录如下,这是什么情况呢?
[   67.981763] rk_iommu ff914000.isp_mmu: rockchip_iommu_attach_device: Attached new IOMMU with pgtable 0x1eacb000
[   67.982304] D1:camsys_mrv_iommu_cb(276): map fd 17 ,client fd 48
[   67.982304]
[   67.982330] rk_iommu ff914000.isp_mmu: (isp_mmu) Already enabled
[   67.982780] D1:camsys_mrv_iommu_cb(276): map fd 19 ,client fd 48
[   67.982780]
[   67.982792] rk_iommu ff914000.isp_mmu: (isp_mmu) Already enabled
[   67.985774] D1:camsys_mrv_iommu_cb(276): map fd 53 ,client fd 48
[   67.985774]
[   67.985791] rk_iommu ff914000.isp_mmu: (isp_mmu) Already enabled
[   67.986266] D1:camsys_rk3288_mipihpy_cfg(104): mipi phy 0 standby!
[   67.986278] W:camsys_phy_ops(479): mipiphy->phy_index(-1223991276) != extdev->phy.info.mipi.phy_index(0)!
[   67.986486] D1:camsys_rk3288_mipihpy_cfg(219): mipi phy(0) turn on(lane: 0x1  bit_rate: 528Mbps)
[   68.052270] D1:camsys_irq_connect(543): Thread(pid: 1476) connect camsys_marvin irq success! mis: 0x5c4 icr: 0x5c8
[   68.052340] D1:camsys_irq_connect(543): Thread(pid: 1477) connect camsys_marvin irq success! mis: 0x1500 icr: 0x1504

[   68.057151]  rockchip_ion_cma: Fail to allocate(eb000) buffer
[   68.059334]  rockchip_ion_cma: Fail to allocate(eb000) buffer
[   68.062825]  rockchip_ion_cma: Fail to allocate(eb000) buffer
[   68.066596]  rockchip_ion_cma: Fail to allocate(eb000) buffer





============================LOGCAT===============================
130|shell@firefly:/ # logcat -s CameraHal
--------- beginning of system
--------- beginning of main
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
I/CameraHal(  156): camera_device_open(500): camera_device open
D/CameraHal(  156): gCameraHalLogLevel: 0
D/CameraHal(  156): CameraHal(159): it is a isp  camera
D/CameraHal(  156): Writetxt(80): /data/rotation_flag open success!
D/CameraHal(  156): Calling process is: /system/bin/mediaserver
E/CameraHal(  156): disconnectCamera(1784): getFocusLimits failed!
E/CameraHal(  156): setupPreview(258): >>>>>>>width_sensor=0,height_sensor=0,preview_w=640,preview_h=480
D/CameraHal(  156): setupPreview(306): isp out put format is YUV420SP.
D/CameraHal(  156): initDefaultParameters(981): ------mHardInfo.mVcmInfo.mVcmDrvName in not NC-----
D/CameraHal(  156): Calling process is: /system/bin/mediaserver
D/CameraHal(  156): enableSensor(213): orientation = 0xb702c0f0 (MPL accel)
D/CameraHal(  156): commandThread(1010): commandThread(1010): receive CMD_PREVIEW_CAPTURE_CANCEL
D/CameraHal(  156): commandThread(1018): commandThread(1018): CMD_PREVIEW_CAPTURE_CANCEL out
D/CameraHal(  156): cancelPicture(588): cancel picture OK.
D/CameraHal(  156): commandThread(938): commandThread(938):receive CMD_PREVIEW_STOP
D/CameraHal(  156): commandThread(959): commandThread(959): CMD_PREVIEW_STOP out
D/CameraHal(  156): stopPreview(389): stop preview OK.
D/CameraHal(  156): camera_device_close(451): camera_device_close
D/CameraHal(  156): disableSensor(237): orientation = 0xb702c0f0 (MPL accel)
D/CameraHal(  156): ~SensorListener(110): Kill looper thread
D/CameraHal(  156): ~SensorListener(122): Kill looper
D/CameraHal(  156): ~SensorListener(128): SensorListener destroyed
D/CameraHal(  156): displayThread(622): displayThread(622): receive CMD_DISPLAY_STOP
D/CameraHal(  156): cameraDisplayBufferDestory(399): cameraDisplayBufferDestory(399): mANativeWindow is NULL, destory is ignore
D/CameraHal(  156): encProcessThread(1632): encProcessThread(1632): receive CMD_ENCPROCESS_EXIT
D/CameraHal(  156): commandThread(1122): commandThread(1122): receive CMD_EXIT
D/CameraHal(  156): ~CameraHal(320): CameraHal destory success
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
I/CameraHal(  156): camera_device_open(500): camera_device open
D/CameraHal(  156): gCameraHalLogLevel: 0
D/CameraHal(  156): CameraHal(159): it is a isp  camera
D/CameraHal(  156): Writetxt(80): /data/rotation_flag open success!
D/CameraHal(  156): Calling process is: com.android.camera2
E/CameraHal(  156): disconnectCamera(1784): getFocusLimits failed!
E/CameraHal(  156): setupPreview(258): >>>>>>>width_sensor=0,height_sensor=0,preview_w=640,preview_h=480
D/CameraHal(  156): setupPreview(306): isp out put format is YUV420SP.
E/CameraHal(  156): cameraCreate(137): sensor name OV2685
D/CameraHal(  156): initDefaultParameters(981): ------mHardInfo.mVcmInfo.mVcmDrvName in not NC-----
D/CameraHal(  156): Calling process is: com.android.camera2
D/CameraHal(  156): enableSensor(213): orientation = 0xb702c0f0 (MPL accel)
D/CameraHal(  156): commandThread(1010): commandThread(1010): receive CMD_PREVIEW_CAPTURE_CANCEL
D/CameraHal(  156): commandThread(1018): commandThread(1018): CMD_PREVIEW_CAPTURE_CANCEL out
D/CameraHal(  156): cancelPicture(588): cancel picture OK.
D/CameraHal(  156): commandThread(938): commandThread(938):receive CMD_PREVIEW_STOP
D/CameraHal(  156): commandThread(959): commandThread(959): CMD_PREVIEW_STOP out
D/CameraHal(  156): stopPreview(389): stop preview OK.
D/CameraHal(  156): camera_device_close(451): camera_device_close
D/CameraHal(  156): disableSensor(237): orientation = 0xb702c0f0 (MPL accel)
D/CameraHal(  156): ~SensorListener(110): Kill looper thread
D/CameraHal(  156): ~SensorListener(122): Kill looper
D/CameraHal(  156): ~SensorListener(128): SensorListener destroyed
D/CameraHal(  156): displayThread(622): displayThread(622): receive CMD_DISPLAY_STOP
D/CameraHal(  156): cameraDisplayBufferDestory(399): cameraDisplayBufferDestory(399): mANativeWindow is NULL, destory is ignore
D/CameraHal(  156): encProcessThread(1632): encProcessThread(1632): receive CMD_ENCPROCESS_EXIT
D/CameraHal(  156): commandThread(1122): commandThread(1122): receive CMD_EXIT
D/CameraHal(  156): ~CameraHal(320): CameraHal destory success
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
I/CameraHal(  156): camera_device_open(500): camera_device open
D/CameraHal(  156): gCameraHalLogLevel: 0
D/CameraHal(  156): CameraHal(159): it is a isp  camera
D/CameraHal(  156): Writetxt(80): /data/rotation_flag open success!
D/CameraHal(  156): Calling process is: com.android.camera2
E/CameraHal(  156): disconnectCamera(1784): getFocusLimits failed!
E/CameraHal(  156): setupPreview(258): >>>>>>>width_sensor=0,height_sensor=0,preview_w=640,preview_h=480
D/CameraHal(  156): setupPreview(306): isp out put format is YUV420SP.
E/CameraHal(  156): cameraCreate(137): sensor name OV2685
D/CameraHal(  156): initDefaultParameters(981): ------mHardInfo.mVcmInfo.mVcmDrvName in not NC-----
D/CameraHal(  156): Calling process is: com.android.camera2
D/CameraHal(  156): enableSensor(213): orientation = 0xb702c0f0 (MPL accel)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): commandThread(1108): commandThread(1108): receive CMD_AF_CANCEL
D/CameraHal(  156): commandThread(964): commandThread(964):receive CMD_SET_PREVIEW_WINDOW
D/CameraHal(  156): commandThread(980): commandThread(980): CMD_SET_PREVIEW_WINDOW out
D/CameraHal(  156): commandThread(859): commandThread(859):receive CMD_PREVIEW_START
D/CameraHal(  156): stop(1859): m_camDevice->stopPreview success!
E/CameraHal(  156): setupPreview(258): >>>>>>>width_sensor=800,height_sensor=600,preview_w=800,preview_h=600
D/CameraHal(  156): setupPreview(306): isp out put format is YUV420SP.
D/CameraHal(  156): start(1814): m_camDevice->startPreview success
D/CameraHal(  156): displayThread(596): displayThread(596): receive CMD_DISPLAY_START
D/CameraHal(  156): cameraDisplayBufferDestory(399): cameraDisplayBufferDestory(399): mANativeWindow is NULL, destory is ignore
D/CameraHal(  156): commandThread(932): commandThread(932): CMD_PREVIEW_START out
D/CameraHal(  156): commandThread(1108): commandThread(1108): receive CMD_AF_CANCEL
D/CameraHal(  156): commandThread(1010): commandThread(1010): receive CMD_PREVIEW_CAPTURE_CANCEL
D/CameraHal(  156): commandThread(1018): commandThread(1018): CMD_PREVIEW_CAPTURE_CANCEL out
D/CameraHal(  156): cancelPicture(588): cancel picture OK.
D/CameraHal(  156): commandThread(938): commandThread(938):receive CMD_PREVIEW_STOP
D/CameraHal(  156): displayThread(610): displayThread(610): receive CMD_DISPLAY_PAUSE
D/CameraHal(  156): stop(1859): m_camDevice->stopPreview success!
D/CameraHal(  156): commandThread(959): commandThread(959): CMD_PREVIEW_STOP out
D/CameraHal(  156): stopPreview(389): stop preview OK.
D/CameraHal(  156): commandThread(1010): commandThread(1010): receive CMD_PREVIEW_CAPTURE_CANCEL
D/CameraHal(  156): commandThread(1018): commandThread(1018): CMD_PREVIEW_CAPTURE_CANCEL out
D/CameraHal(  156): cancelPicture(588): cancel picture OK.
D/CameraHal(  156): commandThread(938): commandThread(938):receive CMD_PREVIEW_STOP
D/CameraHal(  156): commandThread(959): commandThread(959): CMD_PREVIEW_STOP out
D/CameraHal(  156): stopPreview(389): stop preview OK.
D/CameraHal(  156): commandThread(964): commandThread(964):receive CMD_SET_PREVIEW_WINDOW
D/CameraHal(  156): pauseDisplay(159): pauseDisplay(159): display thread is already stop
D/CameraHal(  156): commandThread(980): commandThread(980): CMD_SET_PREVIEW_WINDOW out
D/CameraHal(  156): camera_device_close(451): camera_device_close
D/CameraHal(  156): disableSensor(237): orientation = 0xb702c0f0 (MPL accel)
D/CameraHal(  156): ~SensorListener(110): Kill looper thread
D/CameraHal(  156): ~SensorListener(122): Kill looper
D/CameraHal(  156): ~SensorListener(128): SensorListener destroyed
D/CameraHal(  156): displayThread(622): displayThread(622): receive CMD_DISPLAY_STOP
D/CameraHal(  156): cameraDisplayBufferDestory(399): cameraDisplayBufferDestory(399): mANativeWindow is NULL, destory is ignore
D/CameraHal(  156): encProcessThread(1632): encProcessThread(1632): receive CMD_ENCPROCESS_EXIT
D/CameraHal(  156): commandThread(1122): commandThread(1122): receive CMD_EXIT
D/CameraHal(  156): ~CameraHal(320): CameraHal destory success
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
I/CameraHal(  156): camera_device_open(500): camera_device open
D/CameraHal(  156): gCameraHalLogLevel: 0
D/CameraHal(  156): CameraHal(159): it is a isp  camera
D/CameraHal(  156): Writetxt(80): /data/rotation_flag open success!
D/CameraHal(  156): Calling process is: com.android.camera2
E/CameraHal(  156): disconnectCamera(1784): getFocusLimits failed!
E/CameraHal(  156): setupPreview(258): >>>>>>>width_sensor=0,height_sensor=0,preview_w=640,preview_h=480
D/CameraHal(  156): setupPreview(306): isp out put format is YUV420SP.
E/CameraHal(  156): cameraCreate(137): sensor name OV2685
D/CameraHal(  156): initDefaultParameters(981): ------mHardInfo.mVcmInfo.mVcmDrvName in not NC-----
D/CameraHal(  156): Calling process is: com.android.camera2
D/CameraHal(  156): enableSensor(213): orientation = 0xb702c0f0 (MPL accel)
D/CameraHal(  156): camera_get_camera_info(1337): camera_get_camera_info(1337): camera_0 facing(1), orientation(0)
D/CameraHal(  156): commandThread(1108): commandThread(1108): receive CMD_AF_CANCEL
D/CameraHal(  156): commandThread(964): commandThread(964):receive CMD_SET_PREVIEW_WINDOW
D/CameraHal(  156): commandThread(980): commandThread(980): CMD_SET_PREVIEW_WINDOW out
D/CameraHal(  156): commandThread(859): commandThread(859):receive CMD_PREVIEW_START
D/CameraHal(  156): stop(1859): m_camDevice->stopPreview success!
E/CameraHal(  156): setupPreview(258): >>>>>>>width_sensor=800,height_sensor=600,preview_w=800,preview_h=600
D/CameraHal(  156): setupPreview(306): isp out put format is YUV420SP.
D/CameraHal(  156): start(1814): m_camDevice->startPreview success
D/CameraHal(  156): displayThread(596): displayThread(596): receive CMD_DISPLAY_START
D/CameraHal(  156): cameraDisplayBufferDestory(399): cameraDisplayBufferDestory(399): mANativeWindow is NULL, destory is ignore
D/CameraHal(  156): commandThread(932): commandThread(932): CMD_PREVIEW_START out




回复

使用道具 举报

1837

积分

16

威望

18

贡献

中级创客

Rank: 4

积分
1837
QQ
发表于 2017-11-21 11:18:10     
请先确认对应的xml phyIndex 是否配对
回复

使用道具 举报

118

积分

0

威望

0

贡献

技术小白

积分
118
发表于 2017-11-21 11:34:29     
jpchen 发表于 2017-11-21 11:18
请先确认对应的xml phyIndex 是否配对

我配置的lane 为1 的 因为而且也只有MIPI0 有输出的,I2C里面配置也是1lane (1通道的)

<BoardFile>
                <BoardXmlVersion version="v0.0xd.0">
                </BoardXmlVersion>
                <CamDevie>
                        <HardWareInfo>
                                <Sensor>
                                        <SensorName name="OV2685"></SensorName>
                                        <SensorDevID IDname="CAMSYS_DEVID_SENSOR_1B"></SensorDevID>
                                        <SensorHostDevID busnum="CAMSYS_DEVID_MARVIN" ></SensorHostDevID>
                                        <SensorI2cBusNum busnum="3"></SensorI2cBusNum>
                                        <SensorI2cAddrByte byte="2"></SensorI2cAddrByte>
                                        <SensorI2cRate rate="100000"></SensorI2cRate>
                                        <SensorMclk mclk="24000000"></SensorMclk>
                                        <SensorAvdd name="NC" min="28000000" max="28000000"></SensorAvdd>
                                        <SensorDovdd name="NC" min="18000000" max="18000000"></SensorDovdd>
                                        <SensorDvdd name="NC" min="18000000" max="18000000"></SensorDvdd>
                                        <SensorGpioPwdn ioname="RK30_PIN2_PB6" active="0"></SensorGpioPwdn>
                                        <SensorGpioRst ioname="RK30_PIN2_PB7" active="0"></SensorGpioRst>
                                        <SensorGpioPwen ioname="RK30_PIN0_PB3" active="1"></SensorGpioPwen>
                                        <SensorFacing facing="front"></SensorFacing>
                                        <SensorInterface interface="MIPI"></SensorInterface>
                                        <SensorMirrorFlip mirror="0"></SensorMirrorFlip>
                                        <SensorOrientation orientation="0"></SensorOrientation>
                                        <SensorPowerupSequence seq="1234"></SensorPowerupSequence>                                       
                                        <SensorFovParemeter h="60.0" v="60.0"></SensorFovParemeter>
                                        <SensorAWB_Frame_Skip fps="15"></SensorAWB_Frame_Skip>                                       
                                        <SensorPhy phyMode="CamSys_Phy_Mipi" lane="1"  phyIndex="1" sensorFmt="CamSys_Fmt_Raw_10b"></SensorPhy>
回复

使用道具 举报

1837

积分

16

威望

18

贡献

中级创客

Rank: 4

积分
1837
QQ
发表于 2017-11-21 16:48:02     
camsys_phy_ops(479): mipiphy->phy_index(-1223991276) != extdev->phy.info.mipi.phy_index(0)
这个log和你配置的phyIndex="1"不一样
回复

使用道具 举报

118

积分

0

威望

0

贡献

技术小白

积分
118
发表于 2017-11-22 10:18:32     
jpchen 发表于 2017-11-21 16:48
camsys_phy_ops(479): mipiphy->phy_index(-1223991276) != extdev->phy.info.mipi.phy_index(0)
这个log ...

这个警告配置不一致的时候,会重新赋值的呀
if (mipiphy->phy_index != extdev->phy.info.mipi.phy_index) {
                camsys_warn("mipiphy->phy_index(%d) != extdev->phy.info.mipi.phy_index(%d)!",
                    mipiphy->phy_index,extdev->phy.info.mipi.phy_index);
                mipiphy->phy_index = extdev->phy.info.mipi.phy_index;
               
            }
回复

使用道具 举报

118

积分

0

威望

0

贡献

技术小白

积分
118
发表于 2017-11-22 10:46:25     
jpchen 发表于 2017-11-21 16:48
camsys_phy_ops(479): mipiphy->phy_index(-1223991276) != extdev->phy.info.mipi.phy_index(0)
这个log ...

而且这个记录是之前的,现在我改成1了
[  100.860430] rk_iommu ff914000.isp_mmu: rockchip_iommu_attach_device: Attached new IOMMU with pgtable 0x1eacb000
[  100.861046] D1:camsys_mrv_iommu_cb(276): map fd 21 ,client fd 43
[  100.861046]
[  100.861060] rk_iommu ff914000.isp_mmu: (isp_mmu) Already enabled
[  100.861581] D1:camsys_mrv_iommu_cb(276): map fd 22 ,client fd 43
[  100.861581]
[  100.861593] rk_iommu ff914000.isp_mmu: (isp_mmu) Already enabled
[  100.865662] D1:camsys_mrv_iommu_cb(276): map fd 55 ,client fd 43
[  100.865662]
[  100.865695] rk_iommu ff914000.isp_mmu: (isp_mmu) Already enabled
[  100.866799] D1:camsys_rk3288_mipihpy_cfg(109): mipi phy 1 standby!
[  100.866812] W:camsys_phy_ops(490): mipiphy->phy_index(-1224521372) != extdev->phy.info.mipi.phy_index(1)!
[  100.867022] D1:camsys_rk3288_mipihpy_cfg(219): mipi phy(1) turn on(lane: 0x1  bit_rate: 528Mbps)
[  100.868587] W:camsys_i2c_write(61): buf===01,i2cinfo->reg_addr=100
回复

使用道具 举报

118

积分

0

威望

0

贡献

技术小白

积分
118
发表于 2017-11-23 11:00:25     
MIPI 摄像头调试
  1、首先确定电压、
  2、其次I2C 通信 不成功还是确定电压以及时序问题
  3I2C通信正常,是否成功配置成功 也需要确定下
  4、前面三个步骤成功了 还是没图像,这步骤很关键、确定下MIPI 数据线是否有数据输出,示波器输出波形是否达标
   比如我这边遇到过I2C通信不成功 I2C通信成功图像出不来,再看下MIPI数据输波形是否正常,比如我这次就是因为接触问题,电压幅度不够正常,挤压就能够出现图像 XX.png
                              

点评

能否加下联系方式;我的qq:739004960  发表于 2018-11-22 16:57
回复

使用道具 举报

1837

积分

16

威望

18

贡献

中级创客

Rank: 4

积分
1837
QQ
发表于 2017-11-24 17:12:09     
可以提供上层的log,还有尝试把排线改短试试
回复

使用道具 举报

196

积分

0

威望

0

贡献

技术小白

积分
196
发表于 2017-11-25 16:20:15     
Rockchip没有支持OV2685摄像头
回复

使用道具 举报

118

积分

0

威望

0

贡献

技术小白

积分
118
发表于 2017-11-25 16:54:40     
おのみどり 发表于 2017-11-25 16:20
Rockchip没有支持OV2685摄像头

驱动成功了
回复

使用道具 举报

返回列表
12
*滑块验证:
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

友情链接 : 爱板网 电子发烧友论坛 云汉电子社区 粤ICP备14022046号-2
快速回复 返回顶部 返回列表