Navigation

    VEYE IMAGING Forum

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • Recent
    • Popular
    • Users
    • WIKI
    • veye.cc

    SOLVED how to setup mv-mipi-imx287m on rpi zero 2w?

    VEYE MIPI camera
    2
    8
    997
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • N
      nkos last edited by nkos

      UPD solved

      Hi,

      I'm trying to run mv-mipi-imx287m on rpi zero 2w, following this guide: https://wiki.veye.cc/index.php/V4L2_mode_for_Raspberry_Pi

      My actions:

      #!/bin/bash
      
      set -ex
      
      cd ~/
      rm -rf raspberry*
      
      wget https://github.com/veyeimaging/raspberrypi_v4l2/releases/latest/download/raspberrypi_v4l2.tgz 
      tar xzf raspberrypi_v4l2.tgz
      
      # build driver
      cd ~/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y
      make
      
      # build dtbo
      cd ~/raspberrypi_v4l2/driver_source/dts/rpi-6.6.y
      ./build_dtbo.sh
      
      cd ~/raspberrypi_v4l2/release
      
      # create bin dir for current kernel
      mkdir -p driver_bin/$(uname -r)
      
      cp ~/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/*.ko driver_bin/$(uname -r)/
      cp ~/raspberrypi_v4l2/driver_source/dts/rpi-6.6.y/*.dtbo driver_bin/$(uname -r)/
      
      ls -l driver_bin/$(uname -r)/*.{ko,dtbo}
      
      cd ~/raspberrypi_v4l2/release
      chmod +x *.sh
      yes no | ./uninstall_driver.sh veye_mvcam
      
      sed -i 's/\/boot\/cmdline\.txt/\/boot\/firmware\/cmdline\.txt/g' install_driver.sh
      yes | ./install_driver.sh veye_mvcam
      

      Result:

      user@rpizero:~ $ dmesg | tail -n 10
      [   10.013388] Bluetooth: hci0: BCM43436 37.4MHz Class 1.5 RaspBerry Pi Zero2 [Version: 1017.1042]
      [   10.013428] Bluetooth: hci0: BCM43430A1 (001.002.009) build 1042
      [   10.014738] Bluetooth: hci0: BCM: Using default device address (43:43:a1:12:1f:ac)
      [   10.152275] 8021q: 802.1Q VLAN Support v1.8
      [   10.595384] veye_mvcam: loading out-of-tree module taints kernel.
      [   10.596516] mvcam 10-003b: veye mv series camera driver version: 01.01.06
      [   10.944723] brcmfmac: brcmf_cfg80211_set_power_mgmt: power save enabled
      [   11.165153] mvcam: mvcam_read: Reading register 0x04 failed
      [   11.165219] mvcam 10-003b: failed to read chip id
      [   16.219244] systemd[647]: memfd_create() called without MFD_EXEC or MFD_NOEXEC_SEAL set
      
      user@rpizero:~ $ ls -l /dev/video0
      ls: cannot access '/dev/video0': No such file or directory
      
      user@rpizero:~ $ uname -a
      Linux rpizero 6.6.74+rpt-rpi-v8 #1 SMP PREEMPT Debian 1:6.6.74-1+rpt1 (2025-01-27) aarch64 GNU/Linux
      user@rpizero:~ $ lsb_release -a
      No LSB modules are available.
      Distributor ID:	Debian
      Description:	Debian GNU/Linux 12 (bookworm)
      Release:	12
      Codename:	bookworm
      

      Did anyone try to setup this camera module on rpi zero 2w?

      UPD: I have the same error with rpi5 (used install_driver_rpi5.sh instead of install_driver.sh). I've checked my cable connections and everything looks correct (please correct me if I'm wrong)

      UPD2: SOLVED. The problem was that I've tried to put ribbon cable under brown plastic thing. Ribbon should go above it, and contacts should be faced up, not to the board. Like this:

      photo_2025-02-20_22-38-47.jpg

      And this is wrong:

      photo_2025-02-20_22-34-47.jpg

      veye_xumm 1 Reply Last reply Reply Quote 0
      • veye_xumm
        veye_xumm @nkos last edited by

        @nkos 👍

        N 1 Reply Last reply Reply Quote 0
        • N
          nkos @veye_xumm last edited by nkos

          @veye_xumm do you know what framerate can be achieved on rpi zero 2w with imx287?

          I'm getting ~320 fps + ~80 frames drops per second when using v4l2-ctl

          $ v4l2-ctl --stream-mmap --stream-count=-1 -d /dev/video0 --stream-to=/dev/null
          <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 319.87 fps, dropped buffers: 79
          

          and ~240 fps + ~80 frame drops per second when using my C program (V4L2_BUF_TYPE_VIDEO_CAPTURE + V4L2_MEMORY_MMAP, used 3 buffers)

          VIDIOC_DQBUF takes ~4000 microseconds in my case

          fps: 252 dropped: 77 dq: 3996
          fps: 250 dropped: 71 dq: 4031
          fps: 247 dropped: 74 dq: 4041
          fps: 248 dropped: 75 dq: 4033
          

          I've set camera fps using this command

          v4l2-ctl --set-ctrl frame_rate=523
          

          the interesting thing is that I have frame drops even if I set very low fps, e.g. 10

          <<<<<<< 6.67 fps, dropped buffers: 2
          <<<< 7.50 fps, dropped buffers: 3
          <<<<<< 6.87 fps, dropped buffers: 1
          

          as well as using v4l2 C interface (dq is dequeue time in microseconds)

          fps: 7 dropped: 0 dq: 170145
          fps: 6 dropped: 1 dq: 166645
          fps: 5 dropped: 2 dq: 299999
          fps: 3 dropped: 2 dq: 366619
          fps: 8 dropped: 0 dq: 124991
          

          and after setting fps to 2000, roi to 264x64, expmode=0 and metime=18 I have this:

          $ ./test_fps.sh 2>&1 | awk '{ print $2" "$3" "$4" "$5" "$6 }'
          1179.27 fps, dropped buffers: 309
          1190.98 fps, dropped buffers: 311
          1211.59 fps, dropped buffers: 313
          1194.65 fps, dropped buffers: 309
          1179.99 fps, dropped buffers: 322
          1205.69 fps, dropped buffers: 315
          1208.82 fps, dropped buffers: 315
          1199.75 fps, dropped buffers: 328
          

          I had no issues with ov9281 cams from different vendors when using v4l2 C interface on rpi zero 2w, these cams have 1280x800 resolution, 8-bits per pixel and 144 max fps for this format (I'm not sure about rpi zero 2w capabilities though, it seems at least ~385 fps should be possible (?) with imx287:

          (704×544×523) == 191 Mb/s (ideal)
          (1280×800×144) == 140Mb/s
          704×544×250 == 91 Mb/s
          (264*64*1200) == 19 Mb/s
          

          According to driver output CSI speed is limited to 178 Mb/s (per lane?):

          [   11.153106] mvcam: mvcam_get_mipifeature: lane num 2, datarate 1500000000 bps
          [   11.153141] mvcam 10-003b: Success to get mvcam endpoint data lanes, dts uses 2 lanes,will set to camera
          

          can these drops be related to veye driver? Do you have any ideas where I can start from to debug it?

          Here mca312 had similar problem

          https://forum.veye.cc/topic/469/imx287-fps

          and you suggested to use the latest firmware, it seems I have the latest one (MV-MIPI-IMX287M_C1.43_L2.07_upgrade_20240910.bin.zip) :

          $ ./mv_mipi_i2c_new.sh -r version
          version is C 01.43 and L 02.07
          $ dmesg | grep mvcam | grep firmware
          [   11.148332] mvcam 10-003b: firmware version: 0x1430207
          

          I've saved fps=523 to camera memory and defined DEBUG_PRINTK in veye_mvcam.c, so I have the following dmesg (last lines come from v4l2-ctrl stream command mentioned above)

          [    0.054968] /soc/csi@7e801000: Fixed dependency cycle(s) with /soc/i2c0mux/i2c@1/veyemvcam@3b
          [    0.055063] /soc/i2c0mux/i2c@1/veyemvcam@3b: Fixed dependency cycle(s) with /soc/csi@7e801000
          [    0.061709] /soc/csi@7e801000: Fixed dependency cycle(s) with /soc/i2c0mux/i2c@1/veyemvcam@3b
          [    0.062030] /soc/i2c0mux/i2c@1/veyemvcam@3b: Fixed dependency cycle(s) with /soc/csi@7e801000
          [    8.318547] /soc/csi@7e801000: Fixed dependency cycle(s) with /soc/i2c0mux/i2c@1/veyemvcam@3b
          [    8.319204] /soc/i2c0mux/i2c@1/veyemvcam@3b: Fixed dependency cycle(s) with /soc/csi@7e801000
          [   10.560822] veye_mvcam: loading out-of-tree module taints kernel.
          [   10.561878] mvcam 10-003b: veye mv series camera driver version: 01.01.06
          [   11.146706] mvcam_power_on
          [   11.147538] mvcam 10-003b: camera is: MV_MIPI_IMX287M
          [   11.148332] mvcam 10-003b: firmware version: 0x1430207
          [   11.149903] mvcam: mvcam_identify_module: max width 720; max height 544;min width 264; mini height 64
          [   11.149914] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvcam_enum_pixformat 1008 
          [   11.150702] mvcam: mvcam_enum_pixformat: format count: 3; format cap 0x7
          [   11.150713] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvdatatype_to_mbus_code 968 
          [   11.150719] mvcam: mvcam_enum_pixformat support format index 0 mbuscode 8193 datatype: 0
          [   11.150727] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvdatatype_to_mbus_code 968 
          [   11.150733] mvcam: mvcam_enum_pixformat support format index 1 mbuscode 8202 datatype: 1
          [   11.150740] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvdatatype_to_mbus_code 968 
          [   11.150746] mvcam: mvcam_enum_pixformat support format index 2 mbuscode 8211 datatype: 2
          [   11.151533] mvcam: mvcam_enum_pixformat: cur format: 0
          [   11.153106] mvcam: mvcam_get_mipifeature: lane num 2, datarate 1500000000 bps
          [   11.153141] mvcam 10-003b: Success to get mvcam endpoint data lanes, dts uses 2 lanes,will set to camera
          [   11.154719] mvcam: mvcam_probe: max width 720; max height 544
          [   11.157865] mvcam: mvcam_getroi:get roi(0,0,704,544)
          [   11.158664] mvcam: mvcam_v4l2_ctrl_init:default trigger mode 0
          [   11.159456] mvcam: mvcam_v4l2_ctrl_init:default trigger source 1
          [   11.161025] mvcam: mvcam_v4l2_ctrl_init:default framerate 523 , max fps 523 
          [   11.161039] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvcam_enum_controls 1298 
          [   11.161106] mvcam: mvcam_s_ctrl: cid = (0x9E0902), value = (166).
          [   11.161116] mvcam: mvcam_s_ctrl: cid = (0x9E0901), value = (16).
          [   11.161122] mvcam: mvcam_s_ctrl: cid = (0x980911), value = (16).
          [   11.161129] mvcam: mvcam_s_ctrl: cid = (0x9E0903), value = (16).
          [   11.161135] mvcam: mvcam_s_ctrl: cid = (0x981901), value = (0).
          [   11.161142] mvcam write 0x404 val 0x0
          [   11.162448] mvcam: mvcam_s_ctrl: cid = (0x981902), value = (1).
          [   11.162465] mvcam write 0x408 val 0x1
          [   11.163151] mvcam: mvcam_s_ctrl: cid = (0x981904), value = (523).
          [   11.163160] mvcam write 0x814 val 0xcc4c
          [   11.163840] mvcam: mvcam_s_ctrl: cid = (0x981905), value = (0).
          [   11.163849] mvcam: set roi_x 0 round to 0.
          [   11.163856] mvcam: mvcam_s_ctrl: cid = (0x981906), value = (0).
          [   11.163863] mvcam: set roi_y 0 round to 0.
          [   11.163870] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvcam_enum_controls 1333 
          [   11.163882] mvcam 10-003b: mvcam_enum_controls success
          [   11.163889] mvcam write 0x400 val 0x0
          [   11.164567] mvcam write 0x83c val 0x2
          [   11.165315] mvcam 10-003b: mvcam_csi2_get_fmt: width: (704) height: (544) code: (0x2001)
          [   11.165327] mvcam 10-003b: mvcam_csi2_get_fmt: width: (704) height: (544) code: (0x2001)
          [   19.981817] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.981855] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x2001), index = (0)
          [   19.981881] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x2001), index = (2)
          [   19.981894] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.981906] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.981919] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.981926] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.981938] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x200A), index = (0)
          [   19.981959] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x200A), index = (2)
          [   19.981971] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.981978] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.981985] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (2) mbus code (2013)
          [   19.981996] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.982003] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.982010] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (2) mbus code (2013)
          [   19.982021] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x2013), index = (0)
          [   19.982041] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x2013), index = (2)
          [   19.982052] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.982060] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.982066] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (2) mbus code (2013)
          [   19.989868] mvcam: mvcam_g_volatile_ctrl: cid = (0x981901), value = (0).
          [   19.990730] mvcam: mvcam_g_volatile_ctrl: cid = (0x981902), value = (1).
          [   19.991634] mvcam: mvcam_g_volatile_ctrl: cid = (0x981904), value = (523).
          [   19.992678] mvcam: mvcam_g_volatile_ctrl: cid = (0x981901), value = (0).
          [   19.993534] mvcam: mvcam_g_volatile_ctrl: cid = (0x981902), value = (1).
          [   19.994396] mvcam: mvcam_g_volatile_ctrl: cid = (0x981904), value = (523).
          [   19.994665] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.994690] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x2001), index = (0)
          [   19.994736] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x2001), index = (2)
          [   19.994748] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.994755] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.994768] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.994776] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.994788] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x200A), index = (0)
          [   19.994809] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x200A), index = (2)
          [   19.994820] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.994827] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.994834] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (2) mbus code (2013)
          [   19.994845] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.994852] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.994859] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (2) mbus code (2013)
          [   19.994870] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x2013), index = (0)
          [   19.994890] mvcam 10-003b: mvcam_csi2_enum_framesizes: code = (0x2013), index = (2)
          [   19.994901] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (0) mbus code (2001)
          [   19.994908] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (1) mbus code (200a)
          [   19.994915] mvcam 10-003b: mvcam_csi2_enum_mbus_code: index = (2) mbus code (2013)
          [  101.857898] mvcam 10-003b: mvcam_csi2_get_fmt: width: (704) height: (544) code: (0x2001)
          [  101.860285] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvcam_set_stream 1134 
          [  101.860320] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvcam_start_streaming 1088 
          [  101.860327] mvcam_start_streaming 
          [  101.860331] mvcam write 0x400 val 0x1
          [  101.861056] mvcam 10-003b: mvcam_csi2_get_fmt: width: (704) height: (544) code: (0x2001)
          [  105.460732] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvcam_set_stream 1134 
          [  105.460759] /home/user/raspberrypi_v4l2/driver_source/cam_drv_src/rpi-6.6.y/veye_mvcam.c mvcam_stop_streaming 1107 
          [  105.460767] mvcam write 0x400 val 0x0
          [  105.461465] mvcam_stop_streaming 
          

          Unfortunately I cannot test it with rpi5 since something is not working with rpi5:

          user@rpi5:~/raspberrypi_v4l2/rpi5_scripts $ ./media_setting_rpi5.sh mvcam 
          This is a Raspberry Pi 5.
          Kernel version is 6.6.74, do not support unpacked format.
          Kernel version is 6.6.74, use i2c-10 for CAM0 and i2c-11 for CAM1.
          camera name mvcam; roi_x 0; roi_y 0;width 1280; height 1024; media_fmt Y8_1X8; pixel_fmt GREY
          mvcam 11 NOT FOUND
          CAM0 probed:  media device is  /dev/media1
          set CAM0 finish, plese get frame from /dev/video0 and use /dev/v4l-subdev2 for camera setting
          user@rpi5:~/raspberrypi_v4l2/rpi5_scripts $ v4l2-ctl --stream-mmap --stream-count=-1 -d /dev/video0 --stream-to=/dev/null
          		VIDIOC_STREAMON returned -1 (Broken pipe)
          user@rpi5:~/raspberrypi_v4l2/rpi5_scripts $ uname -a
          Linux rpi5 6.6.74+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.74-1+rpt1 (2025-01-27) aarch64 GNU/Linux
          user@rpi5:~/raspberrypi_v4l2/rpi5_scripts $ dmesg | grep -E "rp1|cam"
          [    0.889753] /axi/pcie@120000/rp1: Fixed dependency cycle(s) with /axi/pcie@120000/rp1
          [    0.897628] /axi/pcie@120000/rp1/i2c@80000/veyemvcam@3b: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/csi@128000
          [    0.908463] /axi/pcie@120000/rp1/i2c@88000/veyemvcam@3b: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/csi@110000
          [    0.919310] /axi/pcie@120000/rp1/csi@110000: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@88000/veyemvcam@3b
          [    0.930143] /axi/pcie@120000/rp1/csi@128000: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/veyemvcam@3b
          [    0.951482] /axi/pcie@120000/rp1: Fixed dependency cycle(s) with /axi/pcie@120000/rp1
          [    0.959356] /axi/pcie@120000/rp1/i2c@80000/veyemvcam@3b: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/csi@128000
          [    0.970192] /axi/pcie@120000/rp1/i2c@88000/veyemvcam@3b: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/csi@110000
          [    0.981040] /axi/pcie@120000/rp1/csi@110000: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@88000/veyemvcam@3b
          [    0.991874] /axi/pcie@120000/rp1/csi@128000: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/veyemvcam@3b
          [    2.094202] rp1 0000:01:00.0: bar0 len 0x4000, start 0x1f00410000, end 0x1f00413fff, flags, 0x40200
          [    2.103288] rp1 0000:01:00.0: bar1 len 0x400000, start 0x1f00000000, end 0x1f003fffff, flags, 0x40200
          [    2.112551] rp1 0000:01:00.0: enabling device (0000 -> 0002)
          [    2.118840] rp1 0000:01:00.0: chip_id 0x20001927
          [    2.127268] /axi/pcie@120000/rp1/i2c@80000/veyemvcam@3b: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/csi@128000
          [    2.138171] /axi/pcie@120000/rp1/i2c@88000/veyemvcam@3b: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/csi@110000
          [    2.149346] genirq: irq_chip rp1_irq_chip did not update eff. affinity mask of irq 100
          [    2.186472] /axi/pcie@120000/rp1/i2c@88000/veyemvcam@3b: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/csi@110000
          [    2.197319] /axi/pcie@120000/rp1/csi@110000: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@88000/veyemvcam@3b
          [    2.208238] /axi/pcie@120000/rp1/i2c@80000/veyemvcam@3b: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/csi@128000
          [    2.219089] /axi/pcie@120000/rp1/csi@128000: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/veyemvcam@3b
          [    2.977111] rp1-pio 1f00178000.pio: error -ENOENT: failed to contact RP1 firmware
          [    2.985152] rp1-pio: probe of 1f00178000.pio failed with error -2
          [    8.298688] rp1-firmware rp1_firmware: RP1 Firmware version eb39cfd516f8c90628aa9d91f52370aade5d0a55
          [    9.308331] rp1-cfe 1f00110000.csi: bcm2712_iommu_of_xlate: MMU 1000005280.iommu
          [    9.310361] rp1-cfe 1f00110000.csi: DW dphy Host HW v1.20
          [    9.310370] rp1-cfe 1f00110000.csi: PiSP FE HW v0.1
          [    9.310407] rp1-cfe 1f00110000.csi: found subdevice /axi/pcie@120000/rp1/i2c@88000/veyemvcam@3b
          [    9.310541] rp1-cfe 1f00128000.csi: bcm2712_iommu_of_xlate: MMU 1000005280.iommu
          [    9.310844] rp1-cfe 1f00128000.csi: DW dphy Host HW v1.20
          [    9.310851] rp1-cfe 1f00128000.csi: PiSP FE HW v0.1
          [    9.310889] rp1-cfe 1f00128000.csi: found subdevice /axi/pcie@120000/rp1/i2c@80000/veyemvcam@3b
          [    9.460081] veye_mvcam: loading out-of-tree module taints kernel.
          [    9.461064] mvcam 11-003b: veye mv series camera driver version: 01.01.06
          [   10.076168] mvcam: mvcam_read: Reading register 0x04 failed
          [   10.076174] mvcam 11-003b: failed to read chip id
          [   10.076312] mvcam 10-003b: veye mv series camera driver version: 01.01.06
          [   10.580424] mvcam 10-003b: camera is: MV_MIPI_IMX287M
          [   10.581213] mvcam 10-003b: firmware version: 0x1430207
          [   10.585920] mvcam 10-003b: Success to get mvcam endpoint data lanes, dts uses 2 lanes,will set to camera
          [   10.595802] mvcam 10-003b: mvcam_enum_controls success
          [   10.597180] rp1-cfe 1f00110000.csi: Using sensor mvcam 10-003b for capture
          [   10.597254] rp1-cfe 1f00110000.csi: Registered [rp1-cfe-csi2_ch0] node id 0 successfully as /dev/video0
          [   10.597279] rp1-cfe 1f00110000.csi: Registered [rp1-cfe-embedded] node id 1 successfully as /dev/video1
          [   10.597299] rp1-cfe 1f00110000.csi: Registered [rp1-cfe-csi2_ch2] node id 2 successfully as /dev/video2
          [   10.597320] rp1-cfe 1f00110000.csi: Registered [rp1-cfe-csi2_ch3] node id 3 successfully as /dev/video3
          [   10.597345] rp1-cfe 1f00110000.csi: Registered [rp1-cfe-fe_image0] node id 4 successfully as /dev/video4
          [   10.597364] rp1-cfe 1f00110000.csi: Registered [rp1-cfe-fe_image1] node id 5 successfully as /dev/video5
          [   10.597388] rp1-cfe 1f00110000.csi: Registered [rp1-cfe-fe_stats] node id 6 successfully as /dev/video6
          [   10.597407] rp1-cfe 1f00110000.csi: Registered [rp1-cfe-fe_config] node id 7 successfully as /dev/video7
          [  240.263269] rp1-cfe 1f00110000.csi: Failed to start media pipeline: -32
          

          Thanks in advance

          veye_xumm 1 Reply Last reply Reply Quote 0
          • veye_xumm
            veye_xumm @nkos last edited by

            @nkos

            Please try this on rpi5:

            
            export WIDTH=704
            export HEIGHT=544
            export FPS=319
            
            ./media_setting_rpi5.sh mvcam -fmt RAW8 -x 8 -y 8 -w $WIDTH -h $HEIGHT
            
            v4l2-ctl --set-ctrl roi_x=8 -d /dev/v4l-subdev2
            
            v4l2-ctl --set-ctrl roi_y=8 -d /dev/v4l-subdev2
            
            v4l2-ctl --set-fmt-video=width=$WIDTH,height=$HEIGHT
            
            v4l2-ctl --set-ctrl frame_rate=$FPS  -d /dev/v4l-subdev2
            
            v4l2-ctl -d /dev/video0 --set-fmt-video=width=$WIDTH,height=$HEIGHT,pixelformat=GREY --stream-mmap --stream-count=-1 --stream-to=/dev/null 
            
            N 2 Replies Last reply Reply Quote 0
            • N
              nkos @veye_xumm last edited by nkos

              works, thanks. fps is fine as well, 522.65

              1 Reply Last reply Reply Quote 0
              • N
                nkos @veye_xumm last edited by nkos

                @veye_xumm could you please also tell how to use mv_mipi_i2c_new.sh with rpi5?

                I'm getting an error:

                user@rpi5:~/raspberrypi_v4l2/mv_tools_rpi $ ./mv_mipi_i2c_new.sh -r trgsrc
                ./mv_mipi_i2c_new.sh: line 788: Failed to set I2C address: syntax error in expression (error token is "to set I2C address")
                
                // read_version
                user@rpi5:~/raspberrypi_v4l2/mv_tools_rpi $ ./i2c_4read 10 0x3b 0x0010
                Failed to set I2C address
                

                I've tried to build i2c_cmd

                user@rpi5:~/raspberrypi_v4l2/i2c_cmd $ ./i2c_read 10 0x3b 0x0010 
                Using i2C device /dev/i2c-10
                ====I2C read:<0x3b> <0x10> <0x1>====
                Failed to set I2C address
                
                veye_xumm 1 Reply Last reply Reply Quote 0
                • veye_xumm
                  veye_xumm @nkos last edited by

                  @nkos
                  Please enter this directory and run ./make.sh.
                  mv_tools_rpi/sources

                  N 1 Reply Last reply Reply Quote 0
                  • N
                    nkos @veye_xumm last edited by

                    @veye_xumm now it works, thanks

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post