DIY Mult-channel external LEDs for arducopter

hi all,
This project is for External LEDs and easy DIY, This WS2812 LED controller communitcate with ardupilot with I2C, support Ardupilot firmware ver 3.6 and higher, only test with multicopters, others like Rover, Plane not have test. LEDs only for the popular WS2812, aka Neopixel,only support 3 LEDs every channel.
I test with AC3.6 and the latest AC4.0.3, they all work will, I have not youtube account, so I can’t show the video, maybe some guys made this project can show a video, have fun.

  • LED controller: STM32F103 bluepill or Arduino pro mini
  • LED type: WS2812
  • Muti-channel: 4~8 or more
  • Features: 2 channels for navigation, blinking with red color, others sync with pixhawk main LED status. ref ardupilot wiki page LED Meaning
  • Ardupilot firmware version: 3.6 and higher

Hardware

  • STM32 Bluepill or STM32 Blackpill
  • Arduino Pro mini 3.3V 8MHz or 5V 16MHz

Wrie

Board Pin comments
STM32 bluepill or blackpill PA0 for drone heading, always blinking RED color
PA1 for sync status with ardupilot main LED status
Arduino Pro mini D8 for drone heading, always blinking RED color
D9 sync ardupilot main LED status

my project is here: https://github.com/ejngnng/Ardupilot_External_LEDs

B/R ninja

We can control WS2812 directly from the flight controller on 4.0.

1 Like

yes, AC4.0 can, but fmuv3, and lower AC4.0 fc can’t support

can you send physical connection, and source code if possible.

Hi,

There are 2 parts of source code, Arudpilot firmware (I2C master ) and MCU firmware(I2C slaver).

Ardupilot source code : AP_Notify: add AnyLED I2C for external LED by ningjianggeek · Pull Request #11511 · ArduPilot/ardupilot · GitHub

Sorry, It’s be a long time ago, I can’t find the source code of the i2c slaver.

Thankyou for the response

Dear Ejngnng**,**

I hope you are doing well. I am Shreya.S and currently working on an ArduPilot-based project using a Cube Orange+ flight controller with a Here3+ GPS module (connected via CAN). I am facing an issue where the GPS status LED on the Here3+ is displaying the correct GPS fix state (e.g., yellow for no fix, blue for 3D fix), but when I parse the GPS_RAW_INT MAVLink message on an Arduino Mega (connected via TELEM2), the fix_type value does not seem to match the LED behavior on the Here3+.

Setup Details:

  • Flight Controller: Cube Orange+
  • Firmware: ArduCopter (latest stable release)
  • GPS Module: Here3+ (connected via CAN)
  • External LED: WS2812B LED (connected to Arduino Mega)
  • Communication: MAVLink messages received via TELEM2 (57600 baud)

Issue:

  1. When the Here3+ GPS LED is yellow (indicating no fix), the GPS_RAW_INT message sometimes reports fix_type = 3 instead of 1.
  2. The Arduino Mega parses this data and updates the WS2812B LED, which then displays an incorrect color (e.g., blue instead of yellow).
  3. When I calibrate the motors, the Here3+ LED blinks red and blue, but the external WS2812B LED does not change accordingly.

Debugging Done:

  • Confirmed that fix_type values received by Arduino are incorrect in certain cases.
  • Verified baud rates and hardware connections (TELEM2 TX/RX to Arduino Mega).
  • Used Mission Planner to check GPS status, which appears to be correct.
  • Printed raw MAVLink data from Cube Orange+, which shows unexpected values at times.

Request for Assistance:

Could you please provide guidance on:

  1. Possible reasons why fix_type might be reported incorrectly in MAVLink?
  2. Whether this issue is related to CAN GPS status reporting or a MAVLink message delay?
  3. If there is a more reliable way to read real-time GPS status directly from the Cube Orange+ for external LED indication?

Any insights or recommendations would be greatly appreciated. Thank you for your time and contributions to the ArduPilot community!

Best regards,
[Shreya.S]
gmail:shreyashankar1405@gmail.com
[Mimicking the external Led based on both mavlink messages and gps status]

Hi Shreya,

I have send the project video to your gmail.

I recommend using I2C or CAN bus to sync up the status of Ardupilot, this will have a good performance.

I don’t have Cube Orange+ flight controller, but from the doc of ardupilot, there may have a simple way like this:

https://ardupilot.org/copter/docs/parameters.html#ntf-led-override

Dear Ejngnng ,

I appreciate your prompt response and the video demonstration. The LED synchronization with the Pixhawk appears to be working perfectly.

We are currently using a Cube Orange+ with version 4.5.7 and a WS2812B 4x4 LED module. We have followed the ArduCopter documentation, but unfortunately, we haven’t been able to achieve the desired output. Despite our efforts, the LEDs are not functioning as expected.

Could you kindly provide the circuit diagram or the source code that would help us understand the setup better? We also have a few additional doubts and would appreciate your guidance.

Please share your email and phone number so we can reach out for further clarification.

Looking forward to your response.

Best regards,
[Shreya.S]
[shreyashankar.mbl.com@gmail.com]
[8951214058]

Hi Shreya:

What’s your project about ?

It may take some time to find out the circuit diagram and source code.

I’m living in China, my phone might not be able to make calls.

My email is: ztnjhappy@163.com

Don’t hesitate to contact me.

//BR