Arduino code to control NeoPixel strips using a set color gradient and a PWM input representing robot speed
You can download the AdaFruit NeoPixel dependency library using the Arduino IDE:
- Does Sketch → Import Library → Library Manager exist?  If so:
- Open that dialog.
 - Type "neopixel" into the search box and select the AdaFruit NeoPixel library.
 
 - If not, you need to (install the library)[http://arduino.cc/en/Guide/Libraries
] by hand:
- git clone -v https://github.com/adafruit/Adafruit_NeoPixel.git
 - Move the 
Adafruit_NeoPixelfolder into ~/sketchbook/libraries (on Linux.)- Note that using Sketch → Import Library → Add Library and browsing to the  
Adafruit_NeoPixelfolder accomplishes the same thing. 
 - Note that using Sketch → Import Library → Add Library and browsing to the  
 
 
The code can compile and run just fine on its own using the standard
g++ compiler.  Just define the PC_TESTING macro to stub out the
Arduino functions and classes:
g++ -DPC_TESTING -x c++ ./sketch_nov09a.ino -o sketch
You should still be able to use Serial.println() to debug color values.