Profile

Cover photo
Tony Youngblood
217 followers|250,831 views
AboutPostsPhotosYouTube+1's

Stream

 
Ok, so I've figured out how to cycle a band of lights over this arch ( https://youtu.be/SeIPkWAIdEE ) and get them to change color. But I'm pulling my hair out on how to get them to create a short tail.

Code here: http://pastebin.com/hjtHPvAY

In the pastebin link, the code that's producing the fade in the video is excised, but it was "fadeToBlackBy( leds, NUM_LEDS, 128);" right after FastLED.show(); delay(75);

What I'm trying to get is a fading tail of 2 rows after the main row.

Several things confuse me.

First, I thought fadeToBlackBy( leds, NUM_LEDS, 128) subtracted 128 from 256 (assuming a starting brightness of 256) and then on the next pass, it subtracted 128 from 128. and then at 0 it just stayed black. But now I see that it is actually is a percentage. So in the case of 128, each call of fadeToBlack reduces the brightness by 50 percent. But if that's the case, it is like Zeno's runner paradox. It'll keep getting closer to 0 but never actually getting there:

256 x .5 = 128
128 x .5 = 64
64 x .5 = 32
...
2 x .5 = 1
1 x .5 = .5
5. x .5 = .25
.25 x .5 = .125
.125 x .5 = .0625
...

And so on. Yes, in terms of getting the LED to effectively look black, it will get there, but with many more passes than a simple subtraction.

So that's the first thing I don't completely understand. (And I've read through everything I could find on FadeToBlackBy here and elsewhere.)

Next problem:

Ok, so I know that by calling fadeToBlackBy( leds, NUM_LEDS, 128); within a loop that iterates LED by LED (or in my case by a range of LEDs), I am placing a command that calls ALL the LEDs within a loop that is speaking to a range at a time. And that's not good.

So instead, I might want to use the expression like this: leds[i].fadeToBlackBy(128);

But the problem I now face is how to get it to refer to the previous iteration of "i." I could do, for example, i-1, (or in my case, in a command that somehow merges fill_gradient with fadeToBlackBy, i+31 (because I'm going backwards and each band of lights is 31 long)), but that would mess up when it gets to the end.

Any way I try it, I end up either leaving the trail on at a set level (for example, 50 percent less bright than the lead band), or getting a trail that spans all 7 trailing rows that never totally fades out.

So, to make a long story short, I'm stumped. Any ideas?

Also, thank you for this wonderful community!
1
1
Tony Youngblood's profile photoJustin Eastman's profile photo
13 comments
 
+Tony Youngblood I have some patterns that does that type of motion and never noticed that feeling occuring, but certainly seems feasible.  That Art Pod project is pretty cool.  Wish I lived closer as it would not take much to make something like that with my existing projects. 
Add a comment...

Tony Youngblood

Shared publicly  - 
1
Add a comment...

Tony Youngblood

commented on a video on YouTube.
Shared publicly  - 
 
What studio?

Tony Youngblood

Shared publicly  - 
1
Add a comment...

Tony Youngblood

Shared publicly  - 
1
Add a comment...

Tony Youngblood

Shared publicly  - 
1
Add a comment...
Have him in circles
217 people
Angela Galloway's profile photo
Chris Lee's profile photo
Randy Hunt's profile photo
shea holliman's profile photo
Keith R. Potempa's profile photo
Christopher Watts's profile photo
Sound Mind & Proxy's profile photo
Liz Scofield's profile photo
Becky Fox Matthews's profile photo
 
Hello everyone,

I'm still learning FastLED and C++, and I have a question about some code.

I have a grid that's basically 31 LEDs wide by 8 rows. I want to light the last row, then move to the next row, then move to the next, and so on.
But I also want the hue to change by 16 for every cycle of the 8 rows.

So I figured I could make a nested loop as such:

void loop() {
for(int h = 0; h < 241; h += 16) {
for(int i = NUM_LEDS; i >= 0; i -= 31) {
fill_solid(leds, NUM_LEDS, CHSV(0,0,0));
fill_gradient(leds,i-30,CHSV(h,255,255),i,CHSV(h,255,255),SHORTEST_HUES);
delay(75);
FastLED.show();
}
}
}

The cycling works fine, but the hue keeps a value of 0 (red) throughout. What am I doing wrong?

Thank you!
Tony
1
Zeph Smith's profile photoTechy - Chiptunes & Stuff's profile photoTony Youngblood's profile photo
4 comments
 
Thank you, +Techy 4198. Done.
Add a comment...

Tony Youngblood

Shared publicly  - 
1
Add a comment...

Tony Youngblood

Shared publicly  - 
1
Wayne Youngblood's profile photo
 
The slides look dangerous!!   Wow,almost 200,000 views! 
Add a comment...

Tony Youngblood

Shared publicly  - 
1
Add a comment...

Tony Youngblood

Shared publicly  - 
1
Add a comment...

Tony Youngblood

Shared publicly  - 
1
Add a comment...
People
Have him in circles
217 people
Angela Galloway's profile photo
Chris Lee's profile photo
Randy Hunt's profile photo
shea holliman's profile photo
Keith R. Potempa's profile photo
Christopher Watts's profile photo
Sound Mind & Proxy's profile photo
Liz Scofield's profile photo
Becky Fox Matthews's profile photo
Links
Other profiles
Basic Information
Gender
Male
Apps with Google+ Sign-in
  • BADLAND
  • Crashlands
Tony Youngblood's +1's are the things they like, agree with, or want to recommend.
Sunday at Boheme Collectif: Robbie Hunsinger’s Creative Code 101 for Mak...
www.theatreintangible.com

Robbie Lynn Hunsinger is a Nashville-based musician, multimedia artist, hacker, coder, and all-around amazing person. She collaborated with

Ustream
market.android.com

Broadcast live and watch live video on your phone or tablet - anytime, anywhere!* Watch live and recent videos, discover upcoming events * B

Variety Reviews - Intimacies of Shakespeare and Victor Hugo - Film Revie...
www.variety.com

Dipping a toe into (early) Errol Morris docu waters, Yulene Olaizola sustains a strange, unsettling mood in her tyro feature, &quot;Intimaci

Arduino Group of Nashville - Google Groups
groups.google.com

CoderFaire Nashville Call for Papers, Nathan Hubbard, 6/12/12. Local place to pick up a kit or a arduino board? Steve White, 6/4/12. Arduino

Music: Minimalogic "Irritant" tape (mp3)
mtve-nashville.blogspot.com

Alright I'm breaking my self-imposed exile from reviewing digital albums in order to write up this (impossible to find) gem. Minimalogic was

DANIEL JOHNSTON Friday at Lipscomb University! » Theatre Intangible
www.theatreintangible.com

But color me wrong. If they book the Legendary Stardust Cowboy, The Shaggs, and Jandek, I may even start going to church again. Ok, probably

Sunday at Richland Ballroom (House) – SUGAR SK*-*LLS / COUPLER / STEPHEN...
www.theatreintangible.com

NO KINGS Records is a vital part of the local lo-fi and noise scenes. Sunday night check out an intimate show at No Kings founder Stephen Mo

E078 The Ocean and the Sea 2012-01-17 » Theatre Intangible
www.theatreintangible.com

Here's podcast 78 The Ocean and the Sea starring BREY MCCOY and ANTHONY WILLIAM HERNDON from the Paducah, Kentucky experimental group METRON

E077 Elsewhere 2011-12-20 » Theatre Intangible
www.theatreintangible.com

Here's podcast 77, Elsewhere, recorded July 10th, 2011 and starring LET'S SAY BALTIMORE members ANDY ALEXANDER, AUSTIN ALEXANDER, DAVE DAWSO

The 2011 Rock 'n' Roll Poll
www.nashvillescene.com

For our annual Rock &#39;n&#39; Roll Poll, we once again dialed up a select group of Nashville&#39;s finest rockers, rollers, bloggers, book