Hello Yall,
Question concerning the Neopixel, I bought this item thinging it would be as easy to manage as the Digital RGB LED Weatherproof Strip 32 LED . This strip has only 3 wires . i receieved this product 2 weeks ago , i have never been able to get it going .
Can someone help me in connection this to my ARDUINO UNO R3 ?
BLACK GOES TO GND , DATA GOES TO # 11 , AND RED STAYS LOOSE ON THE ARDUINO SIDE. ON THE FAR END I CONNECT POS TO THE POS SIDE OF THE ADAPTER , AND SAME WITH NEGATIVE . WHAT AM I DOING WRONG OR MISSING ?
ANY ANSWER IS HIGHLY APRECIATED .
Issues getting Neopixel to work
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- adafruit_support_bill
- Posts: 88087
- Joined: Sat Feb 07, 2009 10:11 am
Re: Issues getting Neopixel to work
Are you using the example code from the NeoPixel library? https://github.com/adafruit/Adafruit_NeoPixel
Have you changed to code to use pin 11 instead of pin 6?
Are you connecting the data pin to the Input end of the strip?
Have you changed to code to use pin 11 instead of pin 6?
Are you connecting the data pin to the Input end of the strip?
-
- Posts: 7
- Joined: Thu Jan 03, 2013 1:25 pm
Re: Issues getting Neopixel to work
Are you using the example code from the NeoPixel library? https://github.com/adafruit/Adafruit_NeoPixel
Have you changed to code to use pin 11 instead of pin 6?
Are you connecting the data pin to the Input end of the strip?
Thank you for answering,
I am using that code provided by paintyourdragon, from the NeoPixel Library,
I have changed to code from 6 to 11. i have tried pins3 5 6 9 10
Yes ,on the closer side of the arduino I connected the ground to gnd, and data to pin 11, on the other side going to the power source i connect pos to pos and neg to neg to power source.
I run the code in the arduino softward doing a strandtest try all thost pins all i get is ........ this line turns orange Adafruit_NeoPixel strip = Adafruit_NeoPixel(60, 11, NEO_GRB + NEO_KHZ800);
then at the bottom says
Adafruit_NeoPixel does not name a type .
at that point this is as far as i have gotten
still no luck
Please help,
Your help is very appriciated
Have you changed to code to use pin 11 instead of pin 6?
Are you connecting the data pin to the Input end of the strip?
Thank you for answering,
I am using that code provided by paintyourdragon, from the NeoPixel Library,
I have changed to code from 6 to 11. i have tried pins3 5 6 9 10
Yes ,on the closer side of the arduino I connected the ground to gnd, and data to pin 11, on the other side going to the power source i connect pos to pos and neg to neg to power source.
I run the code in the arduino softward doing a strandtest try all thost pins all i get is ........ this line turns orange Adafruit_NeoPixel strip = Adafruit_NeoPixel(60, 11, NEO_GRB + NEO_KHZ800);
then at the bottom says
Adafruit_NeoPixel does not name a type .
at that point this is as far as i have gotten
still no luck
Please help,
Your help is very appriciated
- pburgess
- Posts: 4161
- Joined: Sun Oct 26, 2008 2:29 am
Re: Issues getting Neopixel to work
Ah! Sounds like the library is not correctly installed.
1. Download the ZIP from Github.
2. Uncompress the ZIP.
3. Rename the resulting folder to 'Adafruit_NeoPixel'. Directly inside this folder should be 'Adafruit_NeoPixel.cpp', 'Adafruit_NeoPixel.h', an 'examples' folder and a couple other files. Depending on your OS, sometimes unzipping creates an extra nested folder...don't want that, move it up out of there.
4. Move the Adafruit_NeoPixel library into the Arduino libraries folder. On Mac this is (home folder)->Documents->Arduino->Libraries. On Windows, I think this is (home folder)->My Documents->Arduino->Libraries, and on Linux it's (home folder)->Sketchbook->libraries
5. Restart the Arduino IDE. You should then be able to access the strandtest sketch by navigating through the menus File->Sketchbook->Libraries->Adafruit_NeoPixel->strandtest. If this is not present, the library still isn't correctly named or located.
1. Download the ZIP from Github.
2. Uncompress the ZIP.
3. Rename the resulting folder to 'Adafruit_NeoPixel'. Directly inside this folder should be 'Adafruit_NeoPixel.cpp', 'Adafruit_NeoPixel.h', an 'examples' folder and a couple other files. Depending on your OS, sometimes unzipping creates an extra nested folder...don't want that, move it up out of there.
4. Move the Adafruit_NeoPixel library into the Arduino libraries folder. On Mac this is (home folder)->Documents->Arduino->Libraries. On Windows, I think this is (home folder)->My Documents->Arduino->Libraries, and on Linux it's (home folder)->Sketchbook->libraries
5. Restart the Arduino IDE. You should then be able to access the strandtest sketch by navigating through the menus File->Sketchbook->Libraries->Adafruit_NeoPixel->strandtest. If this is not present, the library still isn't correctly named or located.
-
- Posts: 7
- Joined: Thu Jan 03, 2013 1:25 pm
Re: Issues getting Neopixel to work
thank you so much i spent hours trying to figure it out .
1 quiestion. this Neopixel can it be used for a ambilighting project ?
or as a steady color ?
1 quiestion. this Neopixel can it be used for a ambilighting project ?
or as a steady color ?
- pburgess
- Posts: 4161
- Joined: Sun Oct 26, 2008 2:29 am
Re: Issues getting Neopixel to work
The WS2811 pixels won't work with Adalight, and a port is unlikely. They require very strict timing that can't be done while simultaneously receiving data over USB. The other pixel types allow some 'wiggle room' in this regard.
-
- Posts: 7
- Joined: Thu Jan 03, 2013 1:25 pm
Re: Issues getting Neopixel to work
Thank you so much for you help. Could not have done it without you. Which led would you recommend for the best ambilighting. I have a 60 inch led tv. And I'm planning on buying the best LEDs for the job. Which would u recommend ?
- pburgess
- Posts: 4161
- Joined: Sun Oct 26, 2008 2:29 am
Re: Issues getting Neopixel to work
The Adalight project was originally designed around our 12mm RGB LED pixels, and I think those are still the most flexible all-around. Some folks have used LPD8806 flex strips in their place...nice and slim, but the LED spacing is fixed in that case and can't be adapted to different situations.
-
- Posts: 7
- Joined: Thu Jan 03, 2013 1:25 pm
Re: Issues getting Neopixel to work
ok final question
1. i would like to set the strip to 1 static color. what part of the codedo i modify ?
im impressed with this strip.
would using this strip with the teensy3.0 speed up the color rotation ?
i ask becuase im going to make a large purchase and i need advice.
1. i would like to set the strip to 1 static color. what part of the codedo i modify ?
im impressed with this strip.
would using this strip with the teensy3.0 speed up the color rotation ?
i ask becuase im going to make a large purchase and i need advice.
- pburgess
- Posts: 4161
- Joined: Sun Oct 26, 2008 2:29 am
Re: Issues getting Neopixel to work
I've not yet had time to test the code on Teensy 3.0. Might work, might not, but the sure bet for now is to use the 2.0 board. You won't notice any difference in speed for this application, since the frame rate is going to be capped on the PC end.
- osbock
- Posts: 151
- Joined: Tue Jan 23, 2007 1:12 pm
Re: Issues getting Neopixel to work
To set one color, you could use the colorWipe function, or write your own:
For speed, if you are talking about the example code, there is a delay parameter on most of the routines, change this to a lower number, and the wipes and rainbows will happen faster.
Code: Select all
for(uint16_t i=0; i<strip.numPixels(); i++) {
strip.setPixelColor(i, c);
}
strip.show();
- paulstoffregen
- Posts: 444
- Joined: Sun Oct 11, 2009 11:23 am
Re: Issues getting Neopixel to work
A high performance WS2811 library is currently in development for Teensy 3.0. It's in beta testing now.... release is expected in about 1 week.
Among the many improvements, it allows driving 8 strips, totalling about 1000 to 2000 LEDs per Teensy 3.0, with minimal impact to CPU time, interrupt latency, and communication on USB, Serial, I2C, etc.
Among the many improvements, it allows driving 8 strips, totalling about 1000 to 2000 LEDs per Teensy 3.0, with minimal impact to CPU time, interrupt latency, and communication on USB, Serial, I2C, etc.
-
- Posts: 7
- Joined: Thu Jan 03, 2013 1:25 pm
Re: Issues getting Neopixel to work
i have purchase 25 meters for the lpd8806 led strip for a large matrix wall i would like to build ,
i am havinf trouble setting the colos to 1 single color .
here is the code i am using .
what part of the code do i adjust to set strip to 1 color ?
any reply is highly appreciated.
i am havinf trouble setting the colos to 1 single color .
here is the code i am using .
Code: Select all
#include "LPD8806.h"
#include "SPI.h"
// Example to control LPD8806-based RGB LED Modules in a strip
/*****************************************************************************/
// Number of RGB LEDs in strand:
int nLEDs = 34;
// Chose 2 pins for output; can be any valid output pins:
int dataPin = 2;
int clockPin = 3;
// First parameter is the number of LEDs in the strand. The LED strips
// are 32 LEDs per meter but you can extend or cut the strip. Next two
// parameters are SPI data and clock pins:
LPD8806 strip = LPD8806(nLEDs, dataPin, clockPin);
// You can optionally use hardware SPI for faster writes, just leave out
// the data and clock pin parameters. But this does limit use to very
// specific pins on the Arduino. For "classic" Arduinos (Uno, Duemilanove,
// etc.), data = pin 11, clock = pin 13. For Arduino Mega, data = pin 51,
// clock = pin 52. For 32u4 Breakout Board+ and Teensy, data = pin B2,
// clock = pin B1. For Leonardo, this can ONLY be done on the ICSP pins.
//LPD8806 strip = LPD8806(nLEDs);
void setup() {
// Start up the LED strip
strip.begin();
// Update the strip, to start they are all 'off'
strip.show();
}
void loop() {
// Fill the entire strip with...
colorWipe(strip.Color(127, 0, 0), 50); // Red
colorWipe(strip.Color( 0, 127, 0), 50); // Green
colorWipe(strip.Color( 0, 0, 127), 50); // Blue
rainbow(10);
rainbowCycle(0); // make it go through the cycle fairly fast
}
void rainbow(uint8_t wait) {
int i, j;
for (j=0; j < 384; j++) { // 3 cycles of all 384 colors in the wheel
for (i=0; i < strip.numPixels(); i++) {
strip.setPixelColor(i, Wheel( (i + j) % 384));
}
strip.show(); // write all the pixels out
delay(wait);
}
}
// Slightly different, this one makes the rainbow wheel equally distributed
// along the chain
void rainbowCycle(uint8_t wait) {
uint16_t i, j;
for (j=0; j < 384 * 5; j++) { // 5 cycles of all 384 colors in the wheel
for (i=0; i < strip.numPixels(); i++) {
// tricky math! we use each pixel as a fraction of the full 384-color wheel
// (thats the i / strip.numPixels() part)
// Then add in j which makes the colors go around per pixel
// the % 384 is to make the wheel cycle around
strip.setPixelColor(i, Wheel( ((i * 384 / strip.numPixels()) + j) % 384) );
}
strip.show(); // write all the pixels out
delay(wait);
}
}
// Fill the dots progressively along the strip.
void colorWipe(uint32_t c, uint8_t wait) {
int i;
for (i=0; i < strip.numPixels(); i++) {
strip.setPixelColor(i, c);
strip.show();
delay(wait);
}
}
// Chase one dot down the full strip.
void colorChase(uint32_t c, uint8_t wait) {
int i;
// Start by turning all pixels off:
for(i=0; i<strip.numPixels(); i++) strip.setPixelColor(i, 0);
// Then display one pixel at a time:
for(i=0; i<strip.numPixels(); i++) {
strip.setPixelColor(i, c); // Set new pixel 'on'
strip.show(); // Refresh LED states
strip.setPixelColor(i, 0); // Erase pixel, but don't refresh!
delay(wait);
}
strip.show(); // Refresh to turn off last pixel
}
/* Helper functions */
//Input a value 0 to 384 to get a color value.
//The colours are a transition r - g -b - back to r
uint32_t Wheel(uint16_t WheelPos)
{
byte r, g, b;
switch(WheelPos / 128)
{
case 0:
r = 127 - WheelPos % 128; //Red down
g = WheelPos % 128; // Green up
b = 0; //blue off
break;
case 1:
g = 127 - WheelPos % 128; //green down
b = WheelPos % 128; //blue up
r = 0; //red off
break;
case 2:
b = 127 - WheelPos % 128; //blue down
r = WheelPos % 128; //red up
g = 0; //green off
break;
}
return(strip.Color(r,g,b));
}
what part of the code do i adjust to set strip to 1 color ?
any reply is highly appreciated.
Last edited by adafruit_support_bill on Wed Feb 06, 2013 7:03 am, edited 1 time in total.
Reason: Please use the 'Code' button for submitting code
Reason: Please use the 'Code' button for submitting code
- adafruit_support_bill
- Posts: 88087
- Joined: Sat Feb 07, 2009 10:11 am
Re: Issues getting Neopixel to work
This is your loop:what part of the code do i adjust to set strip to 1 color ?
Code: Select all
void loop() {
// Fill the entire strip with...
colorWipe(strip.Color(127, 0, 0), 50); // Red
colorWipe(strip.Color( 0, 127, 0), 50); // Green
colorWipe(strip.Color( 0, 0, 127), 50); // Blue
rainbow(10);
rainbowCycle(0); // make it go through the cycle fairly fast
}
Delete or comment out the parts you don't want.
Please be positive and constructive with your questions and comments.