Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Collapse
Brand Logo

ModalAI Forum

  1. ModalAI Support Forum
  2. VOXL Compute & Autopilot
  3. VOXL 2 IO
  4. Neopixel Integration with PX4

Neopixel Integration with PX4

Scheduled Pinned Locked Moved VOXL 2 IO
3 Posts 2 Posters 1.4k Views 1 Watching
  • 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.
  • J Offline
    J Offline
    jakkkkobo
    Contributor
    wrote on last edited by
    #1

    Re: Neopixel GPIO control on VOXL2 SPI port

    Hello all,

    We have been trying to integrate Neopixel on io_0 and io_3 in PX4 to control with "led_control" and, in case not possible, with voxl-send-neopixel-cmd.
    However, with voxl-send-neopixel-cmd, we can't define color, just turn the RGB strip on or change the number of LEDs. When trying to use it on PX4 with "voxl-esc led -l 0x001", it does not run, due to the modal_io_bridge priority.

    system-image 1.7.8-M0054-14.1a-perf
    hx platform: M0054 1.0.0
    voxl-suite:1.3.2

    Thank you in advance for any help!

    Regards,
    Jacob

    Alex KushleyevA 1 Reply Last reply
    1
    • J jakkkkobo

      Re: Neopixel GPIO control on VOXL2 SPI port

      Hello all,

      We have been trying to integrate Neopixel on io_0 and io_3 in PX4 to control with "led_control" and, in case not possible, with voxl-send-neopixel-cmd.
      However, with voxl-send-neopixel-cmd, we can't define color, just turn the RGB strip on or change the number of LEDs. When trying to use it on PX4 with "voxl-esc led -l 0x001", it does not run, due to the modal_io_bridge priority.

      system-image 1.7.8-M0054-14.1a-perf
      hx platform: M0054 1.0.0
      voxl-suite:1.3.2

      Thank you in advance for any help!

      Regards,
      Jacob

      Alex KushleyevA Offline
      Alex KushleyevA Offline
      Alex Kushleyev
      ModalAI Team
      wrote on last edited by
      #2

      @jakkkkobo ,

      The source code of voxl-send-neopixel-cmd test tool is here : https://gitlab.com/voxl-public/voxl-sdk/services/voxl-io-server/-/blob/master/tools/voxl-send-neopixel-cmd.c

      The function that creates a binary packet (which is forwarded to the ESC via PX4) is here : https://gitlab.com/voxl-public/voxl-sdk/services/voxl-io-server/-/blob/master/lib/modal_io.c#L181 . Basically you need to provide the following information to this function:

      • number of LEDs you are controlling
      • LED type (RGB or RGBW)
      • array of LED colors (3 bytes for each LED in case of RGB, or 4 bytes per LED for RGBW).
      • the array should contain all LED values ranging from 0-255, so if you had 3 LEDs and first should be red, second green and third blue (50% power), the LED color array would be : [127, 0, 0, 0, 127, 0, 0,0,127].
      • this function will create a packet with checksum and send it to PX4, and PX4 will forward the packet to the ESC.

      You can modify the voxl-send-neopixel-cmd to do what you need, maybe you can make it accept an array of LED color values via command line.

      I know the tool could have been more helpful. If you describe your use case, maybe I can help improve the voxl-send-neopixel-cmd tool.

      Alex

      J 1 Reply Last reply
      1
      • Alex KushleyevA Alex Kushleyev

        @jakkkkobo ,

        The source code of voxl-send-neopixel-cmd test tool is here : https://gitlab.com/voxl-public/voxl-sdk/services/voxl-io-server/-/blob/master/tools/voxl-send-neopixel-cmd.c

        The function that creates a binary packet (which is forwarded to the ESC via PX4) is here : https://gitlab.com/voxl-public/voxl-sdk/services/voxl-io-server/-/blob/master/lib/modal_io.c#L181 . Basically you need to provide the following information to this function:

        • number of LEDs you are controlling
        • LED type (RGB or RGBW)
        • array of LED colors (3 bytes for each LED in case of RGB, or 4 bytes per LED for RGBW).
        • the array should contain all LED values ranging from 0-255, so if you had 3 LEDs and first should be red, second green and third blue (50% power), the LED color array would be : [127, 0, 0, 0, 127, 0, 0,0,127].
        • this function will create a packet with checksum and send it to PX4, and PX4 will forward the packet to the ESC.

        You can modify the voxl-send-neopixel-cmd to do what you need, maybe you can make it accept an array of LED color values via command line.

        I know the tool could have been more helpful. If you describe your use case, maybe I can help improve the voxl-send-neopixel-cmd tool.

        Alex

        J Offline
        J Offline
        jakkkkobo
        Contributor
        wrote on last edited by
        #3

        @Alex-Kushleyev ,

        Thank you for the clarification!

        We will change the service and see if it meets our needs.

        Regards,
        Jacob

        1 Reply Last reply
        0

        Hello! It looks like you're interested in this conversation, but you don't have an account yet.

        Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

        With your input, this post could be even better 💗

        Register Login
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        ModalAI
        Categories Recent Tags ModalAI.com Docs
        © 2026 ModalAI® · Accelerating autonomy for smaller, smarter, safer drones · Powered by NodeBB
        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups