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

    Record video with from two OV9782 cameras in stereo

    VOXL SDK
    3
    7
    583
    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.
    • R
      restore
      last edited by

      Hi

      I am running on the VOXL2 and have two of these OV9782 cameras with a stereo flex cable. I am trying to get a simple video recording working. I ran voxl-camera-server and then voxl-record-video and get the following error.

      waiting for server at / run/mpa/stereo_grey/ error, can only record pipes with type h264 or h265
      

      Stereo_grey is the name of the pipe when I list the pipes.

      Eric KatzfeyE Alex KushleyevA 2 Replies Last reply Reply Quote 0
      • Eric KatzfeyE
        Eric Katzfey ModalAI Team @restore
        last edited by

        @restore There are other ways to record video depending on what you are trying to accomplish. voxl-logger can log those outputs and save them as individual png images. This can then be replayed using voxl-replay and viewed in voxl-portal. Or you can stream using voxl-streamer and record the stream using vlc or similar.

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

          @restore , voxl-record-video is designed to record encoded streams. Can you please describe your use case in more detail, I can help you. Specifically, do you want to record raw images or h264/h265, do you want the recordings to be separate for left and right camera or in a single video? Is this just for debugging purposes or you want a stable solution that will be used to recording the video in your project?

          1 Reply Last reply Reply Quote 0
          • R
            restore
            last edited by

            @Alex-Kushleyev I was able to get both cameras recorded using voxl-streamer and VLC.

            For our project, we would like to record video on each camera separately during flight. How do I set up the cameras to be visible/accessible in QGroundControl? Is there a way to configure it to save videos in 2 minute clips or something similar?

            Thank you!

            Alex KushleyevA Eric KatzfeyE 2 Replies Last reply Reply Quote 0
            • Alex KushleyevA
              Alex Kushleyev ModalAI Team @restore
              last edited by

              @restore , I am personally not an expert in QGroundControl and whether you can view multiple camera streams there..

              It seems you figured out how to do what you need using voxl-streamer (did you encoded one double image or two separate h264/5 streams?)

              we don't have ability to break up the video into chunks, but you could modify the voxl-record-video tool to do this.

              BTW, when you record video using voxl-record-video, the resulting video is not in a media container, so it will not play in VLC, but you can fix it using ffmpeg (adjust arguments accordingly):

              ffmpeg -r 30 -i voxl-record-video.h264 -codec copy videofile.mp4
              

              If you are asking whether it is possible to have QGroundControl to save videos in 2 minute chunks, that I also do not know (maybe check px4 forums)

              1 Reply Last reply Reply Quote 0
              • Eric KatzfeyE
                Eric Katzfey ModalAI Team @restore
                last edited by

                @restore The way to view multiple cameras on QGC is to use multiple instances of voxl-streamer, each streaming one camera to a dedicated port. Then use voxl-mavcam-manager to advertise each of those cameras using the Mavlink camera protocol. Then, in QGC you can choose which camera you want to see and start recording, take snapshots, etc. But voxl-mavcam-manager is still under development so not the easiest to work with right now.

                1 Reply Last reply Reply Quote 0
                • R
                  restore
                  last edited by

                  Thank you - I was able to make it work for one camera with the following changes.

                  etc/modalai/voxl-camera-server.conf

                  • changed "camera_id_second": to -1 to get just one camera,
                  • changed "en_preview": to false,
                  • Added:
                    "en_small_video":	true,
                    "small_video_width":	1280,
                    "small_video_height":	800,
                    
                  • restart voxl-camera-server service

                  etc/modalai/voxl-streamer.conf

                  • "input-pipe": "stereo_small_encoded"

                  etc/modalai/voxl-mavcam-manager.conf

                  • "video_record_pipe_name": "stereo_small_encoded",
                  1 Reply Last reply Reply Quote 0
                  • First post
                    Last post
                  Powered by NodeBB | Contributors