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

    Writing a Custom UART Driver

    VOXL SDK
    3
    7
    620
    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.
    • LucaVertiqL
      LucaVertiq
      last edited by

      @Moderator Hi, our team is going to be writing a driver for UART control of vertiq motors for PX4 soon. Additionally I'm prototyping with a VOXL 2 Mini and have got the tool chain running. I know the voxl 2 works a bit differently than a standard px4 stm32 board. I was looking at the modalIO and I notice it is enabled in both voxl2-slpi and voxl2 default.px4board files. Is the slpi folder for the DSP half of the chip? Is it just a completely different board that I should ignore?

      Thanks,

      Luca

      ModeratorM 1 Reply Last reply Reply Quote 0
      • ModeratorM
        Moderator ModalAI Team @LucaVertiq
        last edited by

        @LucaVertiq you will need your uart driver to run in the slpi portion of the build. you should be able to find everything you need here: https://docs.modalai.com/voxl-px4/

        LucaVertiqL 1 Reply Last reply Reply Quote 0
        • LucaVertiqL
          LucaVertiq @Moderator
          last edited by

          @Moderator Thanks, that's where I've been looking. I'll have to look harder at the slpi portion of the build to understand it better. If I have more questions I'll be back. Thanks!

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

            @LucaVertiq Yes, you have a choice of where to put the driver depending on what UART port you are planning to use. If you use a UART available to the applications processor then you would use the standard voxl2 build. If you use a DSP UART then you would use the voxl2-slpi build.

            LucaVertiqL 1 Reply Last reply Reply Quote 0
            • LucaVertiqL
              LucaVertiq @Eric Katzfey
              last edited by

              @Eric-Katzfey Ahh that makes sense. I see in the voxl 2 mini datasheet that it says apps or slpi proc for each uart. That's great.

              So on the slpi proc how do I know what uart number to use in PX4. It looks like in the spektrum driver is selects uart 7 and the modal_io driver selects uart 2 which seems to match QUP7 and QUP2 in the datasheet:
              01cd2787-0445-4c8e-a7eb-37eafca4cfcc-image.png

              Am I understanding that correctly so far?

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

                @LucaVertiq Yep, that is correct.

                LucaVertiqL 1 Reply Last reply Reply Quote 0
                • LucaVertiqL
                  LucaVertiq @Eric Katzfey
                  last edited by

                  @Eric-Katzfey Thanks to you we now have our motors running right off the SLPI processor with PX4 as a UART 'bus'. Everything seems to work great. The main issue was figuring out what qshell commands to send to start it up properly.

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