Library to control NeoPixel strings of RGB leds

Dependencies:   PixelArray

Dependents:   NeoPixelI2cSlave NeoPixelI2cSlave

Revision:
0:66a5d46a740f
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/neopixel_string_factory.cpp	Sun Oct 25 11:24:54 2015 +0000
@@ -0,0 +1,10 @@
+#include "neopixel_string_factory.h"
+
+NeoPixelString * NeoPixelStringFactory::createNeoPixelString(PinName spi_pin, unsigned int length) {
+    // Create a temporary DigitalIn so we can configure the pull-down resistor.
+    // (The mbed API doesn't provide any other way to do this.)
+    // An alternative is to connect an external pull-down resistor.
+    DigitalIn(spi_pin, PullDown);
+    
+    return new NeoPixelString(spi_pin, length);
+}
\ No newline at end of file