ModalAI Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Camera orientation parameter

    Ask your questions right here!
    4
    13
    929
    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.
    • Alex KushleyevA
      Alex Kushleyev ModalAI Team
      last edited by

      In order to flip orientation of IMX214 camera (actually it's a 180 degree rotation), you can do this by editing the camera configuration file:

      • edit file /system/etc/camera/camera_config.xml (make sure to create a backup of the config file first)
      • replace <SensorName>imx214_rot180</SensorName> with <SensorName>imx214</SensorName> - there should be several occurrences.
      • this will load a different camera driver, which instructs the camera to flip the image before sending to VOXL
      • actually, the default configuration in camera_config.xml is flipped/rotated for imx214, as you can see, because the way the camera is built, the image would show up flipped if using <SensorName>imx214</SensorName> on standard VOXL Flight Deck

      For stereo cameras, I would suggest go ahead and try to follow this procedure for calibrating: https://docs.modalai.com/calibrate-cameras/#calibrate-stereo-cameras . This will calibrate the ov7251 camera intrinsic parameters and relative translation + rotation of the two stereo cameras in the pair. Hopefully this succeeds (like I said we have not tried rotating both stereo cameras 90 degrees, but in principle it should work). After that, you will also need to adjust the rotation of the stereo pair with respect to the drone itself, if you want to put the depth points in the correct frame. However, even before doing that last step, you can still check if stereo is working by looking at the resulting point cloud.

      1 Reply Last reply Reply Quote 0
      • Alex KushleyevA
        Alex Kushleyev ModalAI Team
        last edited by

        Also, make sure to reboot VOXL after you change camera_config.xml

        A 1 Reply Last reply Reply Quote 0
        • A
          afdrus @Alex Kushleyev
          last edited by

          @Alex-Kushleyev I don't have any camera_config.xml file in the path that you specified, and it does not get created when using voxl-configure-cameras neither. Therefore, how can I change the rotation of the hires/stereos? In voxl-portal they keep being flipped.

          Alex KushleyevA 1 Reply Last reply Reply Quote 0
          • Alex KushleyevA
            Alex Kushleyev ModalAI Team @afdrus
            last edited by

            @afdrus , the original thread was related to VOXL1. Is your question about VOXL1 or VOXL2?

            Alex

            A 1 Reply Last reply Reply Quote 0
            • A
              afdrus @Alex Kushleyev
              last edited by

              @Alex-Kushleyev, sorry, I missed that, my question is about VOXL2

              A 1 Reply Last reply Reply Quote 0
              • A
                afdrus @afdrus
                last edited by

                @Alex-Kushleyev then, how can I change the rotation of the hires/stereos? In voxl-portal they keep being flipped. Is it only possible to rotate the mounting of the cameras?

                Alex KushleyevA 1 Reply Last reply Reply Quote 0
                • Alex KushleyevA
                  Alex Kushleyev ModalAI Team @afdrus
                  last edited by

                  @afdrus please check the bottom of this thread how to rotate the hires (IMX214) camera:

                  https://forum.modalai.com/topic/2422/voxl-streamer-rotation/20

                  @modaltb do we also have rotation option for the stereo cameras (are we building rotated ov7251 drivers?)

                  Alex

                  1 Reply Last reply Reply Quote 0
                  • modaltbM
                    modaltb ModalAI Team
                    last edited by

                    @afdrus,

                    We're trying to improve customizability... our approach now is we're shipping various flavors of sensors/variants/HW locations....

                    TLDR: here's pre-release binaries to try, these go into /usr/lib/camera:

                    https://storage.googleapis.com/modalai_public/forum/2023-08-18-imx214-flip/com.qti.sensor.imx214_flip.so
                    https://storage.googleapis.com/modalai_public/forum/2023-08-18-imx214-flip/com.qti.sensormodule.imx214_flip_0.bin
                    https://storage.googleapis.com/modalai_public/forum/2023-08-18-imx214-flip/com.qti.sensormodule.imx214_flip_2.bin
                    https://storage.googleapis.com/modalai_public/forum/2023-08-18-imx214-flip/com.qti.sensormodule.imx214_flip_3.bin
                    https://storage.googleapis.com/modalai_public/forum/2023-08-18-imx214-flip/com.qti.sensormodule.imx214_flip_4.bin


                    Longer version: we've started docs here: https://docs.modalai.com/voxl2-image-sensors/

                    Starting in SDK1.0, we began to put the sensor MODULE bin options in /usr/share/modalai/chi-cdk.

                    These are the binaries that tie the HW location, and also is in charge of pulling in the appropriate sensor SO in /usr/lib/camera

                    voxl2:/usr/share/modalai/chi-cdk$ ls
                    imx214  imx214-flip  imx335  imx377  imx412  imx678  irs1645  ov7251  ov7251-combo  ov7251-combo-flip  ov7251-fsin  ov7251-fsout  ov9782  ov9782-combo  ov9782-combo-flip
                    

                    For example, this is our preview release, there's imx214-flip.

                    The idea is, you want to find the appropriate bin to use, for example my options:

                    voxl2:/usr/share/modalai/chi-cdk$ ls imx214-flip/
                    com.qti.sensormodule.imx214_flip_0.bin  com.qti.sensormodule.imx214_flip_2.bin  com.qti.sensormodule.imx214_flip_3.bin  com.qti.sensormodule.imx214_flip_4.bin
                    

                    The so that will be used by these bins is /usr/lib/camera/com.qti.sensor.imx214_flip.so.

                    modaltbM 1 Reply Last reply Reply Quote 0
                    • modaltbM
                      modaltb ModalAI Team @modaltb
                      last edited by

                      @afdrus , @Alex-Kushleyev ,

                      Just realizing you asked for STEREO sensors haha, those should be on target already and found under /usr/share/modalai/chi-cdk/ov7251-combo-flip....

                      A 1 Reply Last reply Reply Quote 0
                      • A
                        afdrus @modaltb
                        last edited by

                        @modaltb Thanks, despite the delay, for the response! I only have one last question in this regard: is it possible to rotate the stereo ov7251 by 90 degrees or currently it is only possible to flip them by 180?
                        This info would help me a lot. Thanks!

                        1 Reply Last reply Reply Quote 0
                        • First post
                          Last post
                        Powered by NodeBB | Contributors