I just got some ws2812. I have one wired up according to the spec sheet I found that was published by world semico. I have just one hooked up to a Mega 2560 and am using the following code:
#include "FastLED.h"
#define NUM_LEDS 1
#define DATA_PIN 6
// Define the array of leds
CRGB leds[NUM_LEDS];
void setup() {
FastLED.addLeds<NEOPIXEL, DATA_PIN>(leds, NUM_LEDS);
}
void loop() {
// Turn the first led red for 1 second
leds[0] = CRGB::Red;
FastLED.show();
delay(1000);
// Set the first led back to black for 1 second
leds[0] = CRGB::Black;
FastLED.show();
delay(1000);
}
I've been mostly just following a few blogs and youtube videos. I have spent a few hours looking up information and cannot seem to get even one LED to light. Any glaring issues or suggestions?">
What I am trying to see is if the LED is wired correctly. In order to do this I need to see the orientating mark on your LED. This is not viable in the added photograph.
Also I can't see any 0.1uF ceramic capacitor across the power lines of the LED.
You changed your first post making my comment look silly. We don't like that round here. Please read this:- How to use this forum it will tell you how we like to play things here.
Grumpy_Mike:
What I am trying to see is if the LED is wired correctly. In order to do this I need to see the orientating mark on your LED. This is not viable in the added photograph.
Also I can't see any 0.1uF ceramic capacitor across the power lines of the LED.
You changed your first post making my comment look silly. We don't like that round here. Please read this:- How to use this forum it will tell you how we like to play things here.
My bad about editing the post.
The orientation mark is on the corner with the black wire going to ground. Red is 5v. Yellow is Data on Pin 6.
Is the capacitor necessary to drive a single LED? I was reading that this was to prevent flickering when using several of these in a chain.
Code looks ok, wiring looks correct, if the soldering is proper then I'd start seeing if the sketch is actually uploading. Are you clicking Upload and not just clicking Verify?
Sounds stupid but it has taken pages to reach that conclusion before.
Grumpy_Mike:
It is in the data sheet that each LED requires a decoupling capacitor, I have never used one without.
That sounds right.
The first photograph looks like the data is connected to pin 7 not 6 like the software says.
OK, I'm not sure. I don't have any capacitors so I can't test that. If I can't get anything else to work I'll look into getting some. The picture may look off, but I have double checked the wiring and used a multimeter to check the voltages.
Grumpy_Mike:
Where did you probe?
You need to probe on the metal of the LED connector not on the soldered joint to make sure the joint is correctly made.
I tried as well as I could to contact only the pads, but there isn't much room to work with, even with fine pointed probes.
Edit: Wired another up just the same in-case of a bad chip. Still nothing. I'm going to assume its a capacitor issue then.
So have you tried the other 5v pin or should I just let you go off worrying about capacitors?
Your clone board could simply be mislabeled as the pin could be aref with high resistance.
So the least you could do is try what I said.
INTP:
So have you tried the other 5v pin or should I just let you go off worrying about capacitors?
Your clone board could simply be mislabeled as the pin could be aref with high resistance.
So the least you could do is try what I said.
I did. I didn't respond because I am rate limited on this new account, and figured that was a pretty obvious thing.
Alright. I tried a third LED and this one is working.... I might have a bad batch, or maybe some were damaged in shpping. I got them in a pretty wrinkly looking shipping envelope. Either way:
Thank you all for your help! I appreciate it very much.
Your soldering is indicative of an 'iron not hot enough and left on too long' so I would not be so quick to blame a bad batch of LEDs that were damaged by you.
INTP:
Your soldering is indicative of an 'iron not hot enough and left on too long' so I would not be so quick to blame a bad batch of LEDs that were damaged by you.
I did damage one earlier, didn't attempt to connect it. i had the iron on for plenty of time though. it may have been poor soldering, but I tugged lightly on each one to make sure it was secure. I'll work more with the ones I may have hastily labeled bad.
jgetrost:
i had the iron on for plenty of time though. it may have been poor soldering, but I tugged lightly on each one to make sure it was secure.
By on-too-long I meant you left it touching the wire and component for too long because you were waiting for solder to flow because iron was not hot enough.
Hot iron, 1-2 seconds contact, bring in solder, remove solder, remove iron.
I'm not saying the connection isn't physically attached, I'm saying the duration that you kept heating up the component damaged it internally.