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

    problems cloning MAVSDK Python docker from Gitlab

    Ask your questions right here!
    3
    16
    823
    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.
    • P
      parbat101
      last edited by parbat101

      Hi,
      I am trying to run MAVSDK Python on a Docker using the instructions posted on:
      https://docs.modalai.com/mavsdk/
      and
      https://gitlab.com/voxl-public/voxl-docker-images/voxl-docker-mavsdk-python.
      I am having a following issue:

      Cloning into 'voxl-docker-mavsdk-python'...
      git@gitlab.com: Permission denied (publickey).
      fatal: Could not read from remote repository.
      Please make sure you have the correct access rights
      and the repository exists.

      Please let me know how can I access the file or clone it

      1 Reply Last reply Reply Quote 0
      • tomT
        tom admin
        last edited by tom

        @parbat101 Are you able to clone via. https?:
        git clone https://gitlab.com/voxl-public/voxl-docker-images/voxl-docker-mavsdk-python.git

        1 Reply Last reply Reply Quote 1
        • P
          parbat101
          last edited by

          Yes it worked. Thank you so much!

          1 Reply Last reply Reply Quote 0
          • tomT
            tom admin
            last edited by

            @parbat101 You may need to generate an SSH key before Gitlab allows you to clone via. ssh: https://docs.gitlab.com/ee/user/ssh.html#generate-an-ssh-key-pair

            1 Reply Last reply Reply Quote 1
            • P
              parbat101
              last edited by

              Hi Tom,
              Using your link I was able to clone the files. I generated the SSH key for Gitlab to clone via ssh, it didnot work. Is there any difference between the outcome of the file and their storage location while using https vs ssh?

              I proceeded forward with using MAVSDK in python using Docker container and followed the steps at:
              https://gitlab.com/voxl-public/voxl-docker-images/voxl-docker-mavsdk-python
              Screenshot from 2022-06-09 19-12-46.png
              In the step - Pull the image, I received error. The error is shown below:
              Screenshot from 2022-06-09 19-13-09.png
              Please help me solve this error.

              P 1 Reply Last reply Reply Quote 0
              • P
                parbat101 @parbat101
                last edited by

                update:
                Screenshot from 2022-06-09 19-44-18.png

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

                  Double checking, is the VOXL on a network? E.g. can you ping something on the internet?

                  I'm without a VOXL just now but the image is online
                  a323daab-02af-40d6-8edf-7baea4bbbe24-image.png

                  P 1 Reply Last reply Reply Quote 1
                  • tomT
                    tom admin
                    last edited by

                    @parbat101 There is no difference between cloning via ssh and https in regard to the code. SSH just allows you to clone via. a key passes to GitLab and therefore you don't have to manually enter your gitlab user / pass when pulling and pushing to a repo.

                    P 1 Reply Last reply Reply Quote 1
                    • P
                      parbat101 @modaltb
                      last edited by

                      @modaltb Thank you for explaining.
                      I couldnot connect internet on the voxl however I downloaded the files on the computer and used adb push to transfer those to VOXL.
                      Then, I followed the steps to execte the example program given at:
                      https://gitlab.com/voxl-public/voxl-docker-images/voxl-docker-mavsdk-python

                      The motors (without propellers,For Safety) did spin on the drones so I assumed the drone can fly autonomously using sample program provided in MAVSDK Python in Gitlab page mentioned above...
                      However, when I connected the QGroundControl and tried connecting the Transmitter (DX6e, recommended with m500 in the website),it says manual control lost.
                      Until Yesterday, I used to use the manual and position flight mode with the transmitter in the QGroundControl flawlessly but now I cannot connect the controller. "Manual Control Lost" appears on the screen.
                      I am trying to connect the transmitter for Manual Kill Switch Mode.
                      I have attached the picture of the problem below. Please let me know what could be the problem. Thank You.
                      Screenshot from 2022-06-10 17-40-00.jpg

                      1 Reply Last reply Reply Quote 0
                      • P
                        parbat101 @tom
                        last edited by

                        @tom Thank you so much for explaining.

                        1 Reply Last reply Reply Quote 0
                        • tomT
                          tom admin
                          last edited by

                          @parbat101 Someone else may answer with a better idea why you're seeing your issue but checkout this video if you haven't to see this program executed correctly: https://www.youtube.com/watch?v=c5xz5IDccr0

                          P 1 Reply Last reply Reply Quote 1
                          • tomT
                            tom admin
                            last edited by

                            @parbat101 another example: https://www.youtube.com/watch?v=V3vVs8fEOZs

                            P 1 Reply Last reply Reply Quote 1
                            • P
                              parbat101 @tom
                              last edited by

                              @tom Thank you for the video links. I will follow those videos.

                              1 Reply Last reply Reply Quote 0
                              • P
                                parbat101 @tom
                                last edited by

                                @tom The videos were super helpful and the drone worked as shown in the video.
                                To test other flight patterns, I want to edit the test file takeoff_and_land2.py file which I think is inside the docker images.
                                Can you please suggest me the best way to do it?

                                1 Reply Last reply Reply Quote 0
                                • P
                                  parbat101
                                  last edited by

                                  Thank you everyone for helping me. After I was able to solve the internet problem in the VOXL, everything was solved. All the problems I had in the threads above were mostly because of not having internet in the VOXL. It was hard to connect to University's wifi and Mobile hotspot did not work few times in the beginning. Yesterday, I was able to connect VOXL and Laptop to my mobile hotspot and everything was much easier.
                                  I will keep working on the m500 drone and keep asking more questions in the forum as I progress.

                                  1 Reply Last reply Reply Quote 0
                                  • tomT
                                    tom admin
                                    last edited by tom

                                    @parbat101 Since it is included in that image, one (bad) option is to modify the script and then re-build the Docker image and it will pull in the modified script.

                                    The better solution that I would recommend is create a new script i.e my-script.py and then mount it inside the Docker image on run time using something like this:

                                    docker run -it --rm --privileged --net=host  -v $(pwd)/my-script.py:/path/to/my-script.py gcr.io/modalai-public/voxl-mavsdk-python:v1.1 /bin/bash
                                    

                                    where you mount the script from your host os inside of the Docker container. You can read more about docker + mounting here: https://docs.docker.com/storage/bind-mounts/

                                    This would allow you to modify the script on your host os, then run the above command to pull it into the docker container on run-time. Keep in mind if you modify the script inside of the docker container and then exit the container, the edits will be lost. So make sure you edit the script outside of the container and then re-run the above command to pull in the updated script.

                                    Another note, /path/to/my-script.py will denote the path at which you would like to have the script live inside of the docker container, so you will need to modify that to your liking.

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