Hoping for Help - Arduino UNO (Osepp Uno Really) - 2812B Lightstrip

Hello All,

First time poster, so a little background, I am new to the Arduino world, but have been programming in other languages for some time.

I am making a fun Cornhole set, with Leds around the edges and hole, that will double as a (manual) score tracker, (more fun features to come). The idea is on the board it self have a button for each team, and they hit the button to add a point. From this the code does its magic, and lights up x amount of leds on either side of the board to indicate a teams score. These leds are “bound” between two leds, (lit red for now) with 21 leds in between them.

Now all seems to be working until I get to 18 led’s on either side, (so I could have 17, on both sides lit up to the specific color, the rest of the board is in white). but as soon as I try to add the 18th point, it seems to “reset” my code. I do have a reset game function, but that does not get called until someone hits 21 anyway.

any help here would be appreciated. I will also post this project to the project board when complete.

code attached, using 100 leds with a 5v 40a power supply. so I do not think it is power related.

Cornhole.zip (1.35 MB)

    for(int i; i < 4; i++)

With i starting at whatever was in the memory location before, while i is less than 4, do something is NOT good programming.

The initialization clause should initialize the variables EXPLICITLY.

    for(int i; i < 4; i++)

Same crap code.

        if(digitalRead(Buttons[i]) == false) //Button Pressed

The digitalRead() function does NOT return true or false.


How much memory does myStrip use for 100 LEDs? How much memory do you have on the Arduino you are using?

Thank you for the response, It may be the memory thing. Reading into the FastLED library may have indicated this much to me.

I worked some things around in my code, and it seemed to be related to memory. I have it working now, but if anyone has any other advice I will gladly take it.