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

    flight core v2 compilation

    Ask your questions right here!
    2
    14
    243
    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.
    • H
      hockey_fan
      last edited by 12 Nov 2024, 20:23

      To build flight core v2 I'm following the basic instructions:

      git clone -b modalai-1.13.3 https://github.com/modalai/px4-firmware.git --recursive
      cd px4-firmware
      make modalai_fc-v2

      But when using make, I have a very large number of compile errors. Most I've gotten through by adding missing python libraries, stm32 cross compiler, etc. However there are still more related to missing header files. Are there recommended version(s) for the developer toolchain that go together with this branch? Or is there something else I'm still missing? Thanks.

      T 1 Reply Last reply 12 Nov 2024, 21:23 Reply Quote 0
      • T
        tom admin @hockey_fan
        last edited by 12 Nov 2024, 21:23

        @hockey_fan In order to build PX4 for FCv2 we build inside a nuttx docker container (px4io/px4-dev-nuttx-focal:2022-08-12), this is how we do it in CI: https://gitlab.com/voxl-public/voxl-sdk/ci-tools/-/blob/master/pipeline-configs/fc-px4.yml?ref_type=heads#L31

        H 1 Reply Last reply 13 Nov 2024, 00:35 Reply Quote 0
        • H
          hockey_fan @tom
          last edited by 13 Nov 2024, 00:35

          @tom Thanks, I have not used docker before so I'll dive in. At the same time the instructions above are antiquated and also are pulling from a different repository than the subsequent one mentioned. Could the instructions on building flight core v2 be updated in the future to reflect using docker and the alternate repository, thanks.

          T 1 Reply Last reply 13 Nov 2024, 00:36 Reply Quote 0
          • T
            tom admin @hockey_fan
            last edited by 13 Nov 2024, 00:36

            @hockey_fan Can you send a link to the directions you're following?

            H 1 Reply Last reply 13 Nov 2024, 00:40 Reply Quote 0
            • H
              hockey_fan @tom
              last edited by 13 Nov 2024, 00:40

              @tom https://docs.modalai.com/flight-core-v2-firmware/

              T 1 Reply Last reply 13 Nov 2024, 00:52 Reply Quote 0
              • T
                tom admin @hockey_fan
                last edited by tom 13 Nov 2024, 00:54 13 Nov 2024, 00:52

                @hockey_fan Is there a specific reason you're building the flight core firmware yourself and not loading one of our prebuilt binaries?

                Since those instructions are out of date, following them will produce an out of date binary.

                The newest pre-built binary is: http://voxl-packages.modalai.com/dists/fc-v2/staging/modalai_fc-v2_1.14.0-2.0.85.px4

                H 1 Reply Last reply 13 Nov 2024, 00:54 Reply Quote 0
                • H
                  hockey_fan @tom
                  last edited by 13 Nov 2024, 00:54

                  @tom I need to make modifications to the code, that's why I want to build it.

                  T 1 Reply Last reply 13 Nov 2024, 01:06 Reply Quote 0
                  • H
                    hockey_fan
                    last edited by 13 Nov 2024, 01:06

                    I'm using the flight core v2 standalone board as a development platform with PX4 before moving on to the voxl2 board environment.

                    1 Reply Last reply Reply Quote 0
                    • T
                      tom admin @hockey_fan
                      last edited by 13 Nov 2024, 01:06

                      @hockey_fan Understood, I recommend doing your development off the tip of our branch instead of modalai-1.13.3:

                      https://github.com/modalai/px4-firmware/tree/voxl-dev

                      H 1 Reply Last reply 13 Nov 2024, 01:38 Reply Quote 0
                      • H
                        hockey_fan @tom
                        last edited by 13 Nov 2024, 01:38

                        @tom Shall I use the .yml file mentioned at the first comment to build flight core v2, or is there a dockerfile in the repository that will work?

                        1 Reply Last reply Reply Quote 0
                        • H
                          hockey_fan
                          last edited by 13 Nov 2024, 01:56

                          I am still very confused on how I should build for flight core v2, and which docker file to use. Which is the git repository needed to get to the ci tools? It is not included in the regular voxl-dev repository.

                          T 1 Reply Last reply 13 Nov 2024, 19:47 Reply Quote 0
                          • T
                            tom admin @hockey_fan
                            last edited by tom 13 Nov 2024, 22:42 13 Nov 2024, 19:47

                            @hockey_fan I recommend installing voxl-docker on your host machine, this will guide you through installing docker and the voxl-docker repo which makes building voxl packages easier.: https://docs.modalai.com/voxl-docker-and-cross-installation/#how-to-setup-voxl-docker-and-voxl-cross

                            Once done, you'll be able to do the following:

                            move into the px4-firmware directory

                            cd px4-firmware
                            

                            Mount the directory into the docker container (the first time you run this it will download the px4-dev-nuttx-focal docker image to your host machine

                            voxl-docker -i px4io/px4-dev-nuttx-focal:2022-08-12
                            

                            Once in the container:

                            make modalai_fc-v2
                            

                            This will generate the px4 build at px4-firmware/build/modalai_fc-v2_default/modalai_fc-v2_*.px4 which can be accessed inside or outside of the container

                            H 1 Reply Last reply 14 Nov 2024, 01:40 Reply Quote 1
                            • H
                              hockey_fan @tom
                              last edited by 14 Nov 2024, 01:40

                              @tom Thanks very much, I got it working, appreciate it.

                              T 1 Reply Last reply 14 Nov 2024, 17:32 Reply Quote 0
                              • T
                                tom admin @hockey_fan
                                last edited by 14 Nov 2024, 17:32

                                @hockey_fan No problem, I'll update the docs page with this info, thank you for pointing this out

                                1 Reply Last reply Reply Quote 0
                                1 out of 14
                                • First post
                                  1/14
                                  Last post
                                Powered by NodeBB | Contributors