APM2 / 2.5 LEDs

There's been a few threads on LED strips and lights on the ARDU but most seem outdated now,

What is currently available at V2.8/2.8.1 out of the box (as it were)  are any of the analogue pins already assigned with LED outputs ?

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –


  • Also just found this post by Scot Berfield - very useful

  • Ok, well on the way to making it all work with APM2 so here's where I started, with the driver array.  I have differing types of LEDS on my Octo so to start with I've modified the drawings in the original posts to show the APM2.


  • Thanks for the replies, I'm going to start working my way through it, I'll document it as I go because it all seems a mystery at the moment, there's lots of 'bits' of information in various threads so I'll try and get it all together.

    From my understanding, these are the main items..

    1. Add bridge to enable AN9

    2. Update config in MP setting motorLeds to 107

    3. Buy ULN2003 and wire to drive leds

    It seems there is no coding to be done other than Enable BatteryEvent

    Am I correct ?

  • 100KM

    Yes, copterleds is enabled by default in arducopter 2.8(.1).  

    // Copter LEDS by Robert Lefebvre
    // Based on the work of U4eake, Bill Sanford, Max Levine, and Oliver
    // g.copter_leds_mode controls the copter leds function via bitmath
    // Zeroeth bit turns motor leds on and off: 00000001
    // First bit turns GPS function on and off: 00000010
    // Second bit turns Aux function on and off: 00000100
    // Third bit turns on Beeper (legacy Piezo) function: 00001000
    // Fourth bit toggles between Fast Flash or Oscillate on Low Battery: 00010000 (0) does Fast Flash, (1) does Oscillate
    // Fifth bit causes motor LEDs to Nav Blink: 00100000
    // Sixth bit causes GPS LEDs to Nav Blink: 01000000
    // This code is written in order to be backwards compatible with the old Motor_LEDS code
    // I hope to include at least some of the Show_LEDS code in the future
    // copter_leds_GPS_blink controls the blinking of the GPS LEDS
    // copter_leds_motor_blink controls the blinking of the motor LEDS
    // Piezo Code and beeps once on Startup to verify operation
    // Piezo Enables Tone on reaching low battery or current alert

  • 3D Robotics

    Please see the user-submitted LED tutorials here. Version 2.9 of the ArduCopter code (coming in a week or two) makes the software support easier, too. 

This reply was deleted.


Neville Rodrigues liked Neville Rodrigues's profile
Jun 30
Santiago Perez liked Santiago Perez's profile
Jun 21