🎁📬❄️📦Adafruit Holiday Shipping Deadlines 2019: Please place all UPS 2 Day orders by 11am Monday, December 16 📦❄️📬🎁
0

Only the first 30 LEDs lighting up on my DotStar Digital LED
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Only the first 30 LEDs lighting up on my DotStar Digital LED

by mgalgs on Mon Nov 25, 2019 2:17 pm

I recently purchased a one meter DotStar Digital LED Strip - Black 144 LED/m. (I actually received a white one, but I'm fine with that assuming it's only a difference in plastic color -- pretty safe assumption I think).

I'm using a Pi 3 Model B to drive the SPI. I'm using this 5v, 10A switching power supply to power the strip. I have tied ground from the power supply to ground from the Pi.

Troubleshooting steps I've tried:

- Power-cycled everything a few times. It consistently only lights up the first 30 LEDs. I can fully control those 30 LEDs individually as expected.
- Threw a 100uF cap on the power.
- Swapped the data and clock lines. The wiring diagram shown in the tutorial seems to have DI and CI swapped (at least from how they look on my strip). In any case, I tried both configurations and in one case I could get the first 30 LEDs going, in the other case nothing lit up.

My main suspicion now is that there's actually a bad connection from LED #30 to LED #31, which I guess would be an RMA.

Any other ideas for troubleshooting this thing?

dotstar1.jpg
dotstar1.jpg (283.48 KiB) Viewed 66 times

dotstar2.jpg
dotstar2.jpg (418.6 KiB) Viewed 66 times

dotstar3.jpg
dotstar3.jpg (445.33 KiB) Viewed 66 times

mgalgs
 
Posts: 5
Joined: Sat Oct 26, 2019 8:00 pm

Re: Only the first 30 LEDs lighting up on my DotStar Digital

by dastels on Mon Nov 25, 2019 2:24 pm

A simple question first: is your code specifying 133 pixels and not 30? That's easy enough to overlook if you're starting with example code.

Dave

dastels
 
Posts: 931
Joined: Tue Oct 20, 2015 3:22 pm

Re: Only the first 30 LEDs lighting up on my DotStar Digital

by mgalgs on Mon Nov 25, 2019 3:55 pm

OOOOH MY.... I was initializing my DotStar class with the wrong number of LEDs (30)...

/MASSIVE-FACEPALM

Changed my code from:

Code: Select all | TOGGLE FULL SIZE
dots = dotstar.DotStar(board.SCK, board.MOSI, 30, brightness=0.2)


to:

Code: Select all | TOGGLE FULL SIZE
dots = dotstar.DotStar(board.SCK, board.MOSI, 144, brightness=0.2)


and the whole strip is now lighting up!

Embarrassingly simple mistake! Thanks for your help!

mgalgs
 
Posts: 5
Joined: Sat Oct 26, 2019 8:00 pm

Re: Only the first 30 LEDs lighting up on my DotStar Digital

by dastels on Mon Nov 25, 2019 4:53 pm

No worries. It's often the obvious things (in hindsight) that trip one up.

Glad you're up & running.

Dave

dastels
 
Posts: 931
Joined: Tue Oct 20, 2015 3:22 pm

Please be positive and constructive with your questions and comments.