I am trying to integrate the WS2812B leds onto my Copter. According to the Copter wiki page . I was supposed to select NeoPixelx servo function for one of my auxiliary outputs.
Unfortunately I couldn’t find such an option in the GCS. (QGC).
I have tested this and, for me, neopixels still don’t work. Looking at the code I think I should get one led flashing the ‘standard’ RGB patterns. I have them set on output 120 and turned on in the bitmask. In this case there on a 1M board so I cant try scripting control.
I have just got round to having another look at this. I hooked up the trusty Saleae. They have just added a WS2812B decoder in the logic beta. I’m getting some repeated data on the output but logic (and the led) don’t think its valid. This is the capture:
I will see if some printf’s give any more insight.
This looks like a mistake in the SERVOx_FUNCTION parameter descriptions. I’ll fix this up but until then you should be able to manually set the parameter to 120 (for NeoPixel1) to get it working.
I have a Pixhawk 2.4.8 FC which has 8 MAIN outputs and 6 AUX outputs.
I am using AUX5 (which I believe is SERVO13?) to provide the digital data to the WS2812B LED.
I have set SERVO13_FUNCTION to 120 and NTF_LED_TYPES to 455 which includes NeoPixel in the bit-mask of types.
The WS2812B LED (a linear string of 8 LEDs) is powered by a separate +5v source.
I assume that the colour of the WS2812Bs should mimic the main LED on the Pixhawk. But all I get are all 8 LEDs as white, which means that they are not getting any valid data. I am obviously doing something wrong - but what?
I hope that is not the case as I have no knowledge of Lua …
All that I am trying to achieve is to get the various patterns of the internal LED displayed on a WS2821B LED that I will fit to a part of the drone where it is visible to me while flying.
According to @tridge, the LEDs should show the default pattern. Looks like we have a few people who can’t get it working so I’ve added this to our Copter-4.0 issues list so we don’t forget about it.