Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void mardisGrasAnimation() {
- int j;
- static uint16_t count = 0;
- for(j=0; j < LIGHTS; j++) {
- if(j%count == 0) {
- led_strip[j].green =255;
- led_strip[j].red = 0;
- led_strip[j].blue = 0;
- }
- if(j%count == 1) {
- led_strip[j].green =69;
- led_strip[j].red = 139;
- led_strip[j].blue = 19;
- }
- if(j%count == 2) {
- led_strip[j].green =0;
- led_strip[j].red = 255;
- led_strip[j].blue = 255;
- }
- if(j%count == 3) {
- led_strip[j].green =100;
- led_strip[j].red = 100;
- led_strip[j].blue = 0;
- }
- if(j%count == 4) {
- led_strip[j].green =215;
- led_strip[j].red = 255;
- led_strip[j].blue = 0;
- }
- }
- /* Call to set the colors */
- int i;
- for(i = 0; i < LIGHTS; i++) {
- //icicleAnimation();
- setColor(led_strip[i].green, led_strip[i].red, led_strip[i].blue);
- //move to next light in strip
- }
- count++;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement