Problem with RGB LED Pixels and Adalight project (Solved)

EL Wire/Tape/Panels, LEDs, pixels and strips, LCDs and TFTs, etc products from Adafruit

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
luisf
 
Posts: 46
Joined: Sat Jan 04, 2014 8:40 am

Problem with RGB LED Pixels and Adalight project (Solved)

Post by luisf »

Hello all!

I'm in serious need of help to get my my Adalight working :shock: I recently received the Adalight pack with the Flat Digital RGB LED Pixels (WS2801) instead of the Thin ones, but i can't get any decent response from them :? I'll try to explain with detail the problem and the steps i took..

So of course i strictly followed the tutorial (http://learn.adafruit.com/adalight-diy- ... g/wiring-1) for wiring and software installation. These are some shots of my wiring (http://imageshack.com/a/img827/9109/uuoi.jpg , http://imageshack.com/a/img163/172/23hu.jpg). As you can see in the first i only get some kind of response from the first led and sometimes not even that, and i've tried pressing the cables in the first and second leds to make shure they are connected.

Altough the color order in my led strip is different from the tutorial i still connect GREEN to 13, YELLOW to 11, and BLUE to GND in the Arduino. In the power side RED is + and BLUE is - I'm i supposed to connect anything else? Because the color order in the tutorial is different i also tried switching the green and yellow cables, but still nothing.

I've double checked the wiring instructions and my wiring and i can't understand what's missing but i can never get a decent response from the LEDs, they're never all on at the same time, don't do the startup diagnostic when i upload the code to the Arduino, or respond to Colorswirl or Adalight.

I doubt the problem is coming from the Arduino since the TX light keeps flashing when i upload the LEDstream code, and i get "Ada" in the Serial Monitor. Once i turn on Colorswirl the RX goes steady on and i get good text output "Average frames/sec: 130, bytes/sec: 10561". Since i get a response from the Arduino once i turn on the Processing code i assume everything is working on that part and the COMs are all properly set.

So this just leaves the LED or wiring as the problem, please help me, i REALLY want to get this thing working and enjoy some movies and games!
Last edited by luisf on Wed Feb 26, 2014 4:34 am, edited 1 time in total.

User avatar
adafruit_support_mike
 
Posts: 67454
Joined: Thu Feb 11, 2010 2:51 pm

Re: Problem with RGB LED Pixels and Adalight project

Post by adafruit_support_mike »

I can't tell from the photos: are you sure you're connecting the signals to the input side of the first pixel?

There's an arrow printed on the PCB.. you want the data to flow in the direction of the arrow.

User avatar
luisf
 
Posts: 46
Joined: Sat Jan 04, 2014 8:40 am

Re: Problem with RGB LED Pixels and Adalight project

Post by luisf »

The Arduino must connect to the “input” end! This is the smaller of the two plastic end connectors, the one with the triangular “arms”:
The Arduino is connected to the port with the "arms", right? Or am i misinterpreting something? Also on the other end the plug is male, there is no place to connect the wires.

User avatar
luisf
 
Posts: 46
Joined: Sat Jan 04, 2014 8:40 am

Re: Problem with RGB LED Pixels and Adalight project

Post by luisf »

adafruit_support_mike wrote:I can't tell from the photos: are you sure you're connecting the signals to the input side of the first pixel?

There's an arrow printed on the PCB.. you want the data to flow in the direction of the arrow.
I checked and yes, it's going on the direction of the arrow.
I had the power connected to the other end so i also connected to the same end as the data, but not on the plug of course.

I was able to get some reaction from the leds. When i run color swirl i can get some color changing in the first LED if i unplug the GND wire from the arduino, but when its connected nothing changes in the strip. Is this normal? Am i supposed to connect the GND in the Arduino to something other than the strip?

I've read this thread also, http://forums.adafruit.com/viewtopic.php?f=47&t=50100, but still can't get this to work.

User avatar
adafruit_support_mike
 
Posts: 67454
Joined: Thu Feb 11, 2010 2:51 pm

Re: Problem with RGB LED Pixels and Adalight project

Post by adafruit_support_mike »

You do need a connection between the Arduino's GND and the LED strip's GND. Without it, the strip has no way of knowing whether the data signal is HIGH or LOW.

Just to be sure, are you using the WS2801 library code? Those strips don't work like NeoPixels. This tutorial has a description of how to work with the strip, plus links to the appropriate code: http://learn.adafruit.com/12mm-led-pixels/overview

User avatar
luisf
 
Posts: 46
Joined: Sat Jan 04, 2014 8:40 am

Re: Problem with RGB LED Pixels and Adalight project

Post by luisf »

adafruit_support_mike wrote:You do need a connection between the Arduino's GND and the LED strip's GND. Without it, the strip has no way of knowing whether the data signal is HIGH or LOW.
That's what i thought, just checking.
adafruit_support_mike wrote:You do need a connection between the Arduino's GND and the LED strip's GND. Without it, the strip has no way of knowing whether the data signal is HIGH or LOW.

Just to be sure, are you using the WS2801 library code? Those strips don't work like NeoPixels. This tutorial has a description of how to work with the strip, plus links to the appropriate code: http://learn.adafruit.com/12mm-led-pixels/overview
I tested the Strand Test and it works, while connected to ports 2 (yellow) and 3 (green) ! However when i upload LEDStream, and connect port 11 to yellow, and 13 to green, i don't get the initial color test, nor does the rest of the software work.

The strandtest.pde includes the library Adafruit_WS2801.h, however the LEDStream doesn't, or does it somewhere else? If the LEDStream compiles and uploads properly then there should be no problem with libraries or other right?

User avatar
adafruit_support_mike
 
Posts: 67454
Joined: Thu Feb 11, 2010 2:51 pm

Re: Problem with RGB LED Pixels and Adalight project

Post by adafruit_support_mike »

'ledstream' uses its own magic to run the LEDs at a rate fast enough to stay in sync with the video.

If 'strandtest' works, it means the basic LED strip is okay. Moving the wires to pins 11 and 13 shouldn't cause any problems.

I need to bring our blinky-stuff guru in on this one..

User avatar
pburgess
 
Posts: 4161
Joined: Sun Oct 26, 2008 2:29 am

Re: Problem with RGB LED Pixels and Adalight project

Post by pburgess »

Okay, so you've confirmed strandtest works with this default configuration:

Code: Select all

uint8_t dataPin  = 2;    // Yellow wire on Adafruit Pixels
uint8_t clockPin = 3;    // Green wire on Adafruit Pixels
Let's change these lines to:

Code: Select all

uint8_t dataPin  = 11;
uint8_t clockPin = 13;
and move the wires from pins 2 & 3 to 11 and 13. NOT RUNNING LEDSTREAM YET. Upload the modified strandtest to the board. Do things work?

If no: the Arduino is potentially defective, and we'll work on troubleshooting that or replacing it if it came from Adafruit.

If yes: change this line:

Code: Select all

Adafruit_WS2801 strip = Adafruit_WS2801(25, dataPin, clockPin);
to:

Code: Select all

Adafruit_WS2801 strip = Adafruit_WS2801(25);
Upload to the board again. Does it still work? Report back your results and we'll plan the next steps.

User avatar
luisf
 
Posts: 46
Joined: Sat Jan 04, 2014 8:40 am

Re: Problem with RGB LED Pixels and Adalight project

Post by luisf »

pburgess wrote:Okay, so you've confirmed strandtest works with this default configuration:

Code: Select all

uint8_t dataPin  = 2;    // Yellow wire on Adafruit Pixels
uint8_t clockPin = 3;    // Green wire on Adafruit Pixels
Let's change these lines to:

Code: Select all

uint8_t dataPin  = 11;
uint8_t clockPin = 13;
and move the wires from pins 2 & 3 to 11 and 13. NOT RUNNING LEDSTREAM YET. Upload the modified strandtest to the board. Do things work?

If no: the Arduino is potentially defective, and we'll work on troubleshooting that or replacing it if it came from Adafruit.
Guess we found the problem then. When i change the code to pins 11 and 13 nothing happens. I also tried pins 10 and 12 and it works.
pburgess wrote:If yes: change this line:

Code: Select all

Adafruit_WS2801 strip = Adafruit_WS2801(25, dataPin, clockPin);
to:

Code: Select all

Adafruit_WS2801 strip = Adafruit_WS2801(25);
Upload to the board again. Does it still work? Report back your results and we'll plan the next steps.
I assume omitting the two last parameters makes it use the default 11 and 13 right? Anyway there was no response from the strand in either cases.

Is there any way to change the pins the Arduino uses for Serial communication in the LEDStream code? So i could get this working until i get a new Arduino. (and yes, the Arduino also came from Adafruit)

I think there's a colleague who owns an Arduino at my workplace, tomorrow i'll try to test this setup with a different Arduino.

User avatar
pburgess
 
Posts: 4161
Joined: Sun Oct 26, 2008 2:29 am

Re: Problem with RGB LED Pixels and Adalight project

Post by pburgess »

The difference between these two lines:

Code: Select all

Adafruit_WS2801 strip = Adafruit_WS2801(25, 11, 13);
Adafruit_WS2801 strip = Adafruit_WS2801(25);
Is that the first uses software "bitbang" SPI on pins 11/13, while the latter uses the chip's hardware-native SPI on the same pins.

The fact that neither case is working suggests either:
  • The wires are swapped; try switching, see if any change, or
  • A problem with the board or the microcontroller
If you have access to a second Arduino Uno to test with, that's ideal. If you get the same symptoms, I'd suspect the swapped wires case.

Anyway, in the "defective board" case, it may be as simple as the metal spring contact in the header being wonky. We can test for that. Refer to this image:
http://www.pighixxx.com/pgdev/Temp/ARDUINO_V2.png
Notice on pins 11 and 13, the last of the special functions for these pins (at the far right, in blue) is MOSI and SCK. There are two other places where you have access to these same signals: the 6-pin ICSP header at the bottom end of the board (middle two pins, upper one is SCK, lower is MOSI); and then on the ATmega chip itself, pins 17 and 19. Neither of these have the female header connectors, but you can just hold the wires against those pins for a quick test. If the LEDs respond, the chip is fine and something's not connected right on the board; could wire up a workaround if you're eager to move forward, but if you'd prefer a replacement board we can do that too. If they don't light up, something's weird with the ATmega chip, in which case we'd also provide a replacement. Let me know what you find.

User avatar
luisf
 
Posts: 46
Joined: Sat Jan 04, 2014 8:40 am

Re: Problem with RGB LED Pixels and Adalight project

Post by luisf »

I tried all the combinations for "bitbang" SPI / hardware-native SPI, with green to SCK / yellow to MOSI and the other way around, for all possible locations where i could get acess to the signals, and none of them worked. This leads me to conclude that there is indeed some problem with some chip in the Arduino

When i get the chance to try the strand with another Arduino i'll report back. Thank you for your patience and great support so far :)

User avatar
luisf
 
Posts: 46
Joined: Sat Jan 04, 2014 8:40 am

Re: Problem with RGB LED Pixels and Adalight project

Post by luisf »

After testing the setup i have with a different Arduino, provided by user Rubentju, everything worked at first try. So i think this clarifies the source of all these problems, some broken chip on the Arduino that is used in serial communication right?

I have some commercial questions in order to change this piece so i'll email them instead of discussing them here.

Thank you for all your help, this thread should be good for debugging future problems, at least i didn't find many in this forum that were useful for this problem.

Locked
Please be positive and constructive with your questions and comments.

Return to “Glowy things (LCD, LED, TFT, EL) purchased at Adafruit”