Firefly开源社区

打印 上一主题 下一主题

RK3288使用MIPI 05695 camera proting问题

21

积分

0

威望

0

贡献

技术小白

积分
21

RK3288使用MIPI 05695 camera proting问题

发表于 2017-10-18 14:32:24      浏览:11587 | 回复:6        打印      只看该作者   [复制链接] 楼主
大家好,我是第一次接触RK平台,现需要在RK3288平台上使用MIPI接口的OV5695 camera,在7.1的代码中在“hardware/rockchip/camera/SiliconImage/isi/drv/”中找到了ov5695的driver,但是在配置cam_board_rk3288.xml时遇到了问题,我们power使用的与公版不一样,AVDD 2.8V使用的是PMUGPIO0_C1_d, DOVDD 1.8V使用的是VCC18_DVP
,DVDD 1.2V使用的是PMUGPIO0_B6_d,请问这种情况在cam_board_rk3288.xml中还是添NC吗?
                    <SensorAvdd name="NC" min="28000000" max="28000000" delay="0"></SensorAvdd>                     <SensorDvdd name="NC" min="12000000" max="12000000" delay="0"></SensorDvdd>                     <SensorDovdd name="NC" min="18000000" max="18000000" delay="5000"></SensorDovdd>

   另外除了hardware文件夹下的内容还需要在kernel中修改吗,请各位大神帮忙解惑。



回复

使用道具 举报

1570

积分

3

威望

0

贡献

中级创客

Rank: 4

积分
1570

突出贡献

QQ
发表于 2017-10-19 11:41:44        只看该作者  沙发
有个porting 文档,,,看看群文件
回复

使用道具 举报

21

积分

0

威望

0

贡献

技术小白

积分
21
发表于 2017-10-20 11:08:08        只看该作者  板凳
RK平台MIPI camera应该不需要改到DTS文件吧,我现在只是修改了XML文件,menuconfig或者defconfig之类的文件还需要修改吗?  以下是我改的xml

                                <Sensor>
                                        <SensorName name="OV5695" ></SensorName>
                                        <ModuleName name="NC" ></ModuleName>
                                        <SensorLens name="CHT-842B-MD"></SensorLens>
                                        <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>                               
                                        <SensorAvdd name="NC" min="0" max="0" delay="0"></SensorAvdd>
                                        <SensorDvdd name="NC" min="0" max="0" delay="0"></SensorDvdd>
                                        <SensorDovdd name="NC" min="18000000" max="18000000" delay="5000"></SensorDovdd>
                                        <SensorMclk mclk="24000000" delay="1000"></SensorMclk>
                                        <SensorGpioPwen ioname="RK30_PIN0_PC1" active="1" delay="1000"></SensorGpioPwen>
                                        <SensorGpioRst ioname="NC" active="1" delay="1000"></SensorGpioRst>
                                        <SensorGpioPwdn ioname="RK30_PIN2_PB6" active="0" delay="2000"></SensorGpioPwdn>
                                        <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="2"  phyIndex="0" sensorFmt="CamSys_Fmt_Raw_10b"></SensorPhy>
                                </Sensor>
回复

使用道具 举报

21

积分

0

威望

0

贡献

技术小白

积分
21
发表于 2017-10-20 15:01:29        只看该作者  地板
VDD 1.2V使用的是PMUGPIO0_B6_d,按照下面的格式配置dts设正确的吗?

        isp: isp@ff910000 {
                compatible = "rockchip,rk3288-isp", "rockchip,isp";
                ...............
                rockchip,gpios = <&gpio0 GPIO_B6 GPIO_ACTIVE_HIGH>;
                rockchip,isp,iommu_enable = <1>;
                iommus = <&isp_mmu>;
                status = "disabled";
        };
回复

使用道具 举报

21

积分

0

威望

0

贡献

技术小白

积分
21
发表于 2017-10-20 15:50:19        只看该作者  5#
以下是Kernel log,从log里看是request gpio fail,什么情况会出现request gpio fail

[  142.350342] cpu cpu0: _set_opp_voltage: failed to set voltage (900000 900000 900000 mV): -110
[  142.350659] cpufreq: __target_index: Failed to change cpu frequency: -110
[  142.490657] gpio-17 (sysfs): gpiod_request: status -16
[  142.490666] E:camsys_extdev_register(257): Request RK30_PIN0_PC1(17) failed
[  142.490726] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.490740] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.490744] gpio-15 (camsys_gpio): gpiod_request: status -16
[  142.503459] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.503628] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.537207] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.537226] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.537231] gpio-15 (camsys_gpio): gpiod_request: status -16
[  142.549938] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.550117] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.583607] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.583625] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.583630] gpio-15 (camsys_gpio): gpiod_request: status -16
[  142.596339] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.596512] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.633650] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.633669] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.633675] gpio-15 (camsys_gpio): gpiod_request: status -16
[  142.646374] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.646542] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.679783] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.679802] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.679807] gpio-15 (camsys_gpio): gpiod_request: status -16
[  142.692553] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.692725] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.725947] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.725965] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  142.725970] gpio-15 (camsys_gpio): gpiod_request: status -16
[  142.738674] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  142.738843] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  143.428665] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  143.428684] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  143.428690] gpio-15 (camsys_gpio): gpiod_request: status -16
[  143.441459] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  143.441633] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  143.473028] rk3x-i2c ff650000.i2c: timeout, ipd: 0x00, state: 1
[  143.475181] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  143.475198] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  143.475203] gpio-15 (camsys_gpio): gpiod_request: status -16
[  143.488022] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  143.488200] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  143.521820] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  143.521839] of_get_named_gpiod_flags: parsed 'rockchip,gpios' property of node '/isp@ff910000[0]' - status (0)
[  143.521844] gpio-15 (camsys_gpio): gpiod_request: status -16
[  143.534560] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  143.534731] E:camsys_i2c_write(83): i2c write dev(addr:0x6c) failed!,err = -6
[  144.472997] rk3x-i2c ff650000.i2c: timeout, ipd: 0x00, state: 1
[  144.473028] cpu cpu0: _set_opp_voltage: failed to set voltage (1200000 1200000 1200000 mV): -110
[  144.473127] cpufreq: __target_index: Failed to change cpu frequency: -110
回复

使用道具 举报

21

积分

0

威望

0

贡献

技术小白

积分
21
发表于 2017-10-20 17:22:47        只看该作者  6#
DTS文件中的status要添什么是okay还是disabled,现在的情况是request gpio都是fail

        isp: isp@ff910000 {
                compatible = "rockchip,rk3288-isp", "rockchip,isp";
                reg = <0x0 0xff910000 0x0 0x4000>;
                interrupts = <GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>;
                power-domains = <&power RK3288_PD_VIO>;
                clocks =
                        <&cru ACLK_ISP>, <&cru HCLK_ISP>, <&cru SCLK_ISP>,
                        <&cru SCLK_ISP_JPE>, <&cru PCLK_ISP_IN>,
                        <&cru SCLK_VIP_OUT>, <&cru SCLK_MIPIDSI_24M>,
                        <&cru SCLK_VIP_OUT>, <&cru PCLK_MIPI_CSI>;
                clock-names =
                        "aclk_isp", "hclk_isp", "clk_isp",
                        "clk_isp_jpe", "pclkin_isp", "clk_cif_out",
                        "clk_mipi_24m", "clk_cif_pll", "hclk_mipiphy1";
                pinctrl-names =
                        "default", "isp_dvp8bit2", "isp_dvp10bit",
                        "isp_dvp12bit", "isp_dvp8bit0", "isp_mipi_fl",
                        "isp_mipi_fl_prefl", "isp_flash_as_gpio",
                        "isp_flash_as_trigger_out";
                pinctrl-0 = <&isp_mipi>;
                pinctrl-1 = <&isp_mipi &isp_dvp_d2d9>;
                pinctrl-2 = <&isp_mipi &isp_dvp_d2d9 &isp_dvp_d0d1>;
                pinctrl-3 = <&isp_mipi &isp_dvp_d2d9 &isp_dvp_d0d1
                                        &isp_dvp_d10d11>;
                pinctrl-4 = <&isp_mipi &isp_dvp_d0d7>;
                pinctrl-5 = <&isp_mipi>;
                pinctrl-6 = <&isp_mipi &isp_prelight>;
                pinctrl-7 = <&isp_flash_trigger_as_gpio>;
                pinctrl-8 = <&isp_flash_trigger>;
                rockchip,isp,mipiphy = <2>;
                rockchip,isp,cifphy = <1>;
                rockchip,isp,mipiphy1,reg = <0xff968000 0x4000>;
                rockchip,grf = <&grf>;
                rockchip,cru = <&cru>;
                rockchip,gpios = <&gpio0 14 GPIO_ACTIVE_HIGH>;
                rockchip,isp,iommu_enable = <1>;
                iommus = <&isp_mmu>;
                status = "disabled";
        };
回复

使用道具 举报

21

积分

0

威望

0

贡献

技术小白

积分
21
发表于 2017-11-2 14:23:56        只看该作者  7#
楼主找到原因了没?怎么解决呀
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

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