   0.0,
   0.0,  // a few extra make it feel more natural
   0.0,
-  0.0,
-  0.0,
+//  0.0,
+//  0.0,
   0,0
 };
 
 void start_breathing(){
   states[0] = BREATHE_ON;
+}
+
+rgb_color blend_colors(rgb_color color1, rgb_color color2){
+  rgb_color result;
+  result.red = (color1.red + color2.red) / 2;
+  result.green = (color1.green + color2.green) / 2;
+  result.blue = (color1.blue + color2.blue) / 2;
+  return result;
+}
+
+void do_blend(){
+  colors[0] = blend_colors(colors[0], colors[1]);
+  colors[1] = colors[0];
+}
+
+void do_max(){
+  colors[0] = scale_color(colors[0], MAX_BRIGHTNESS_PERCENT / 100.0);
+}
+
+void do_dim(){
+  colors[0] = scale_color(colors[0], DIM_BRIGHTNESS_PERCENT / 100.0);
+}
+
+void do_bright(){
+  colors[0] = scale_color(colors[0], BRIGHT_BRIGHTNESS_PERCENT / 100.0);
+}
+
+void fade(float rate = FADE_RATE){
+  unsigned char *p;
+  p = (unsigned char *)colors; 
+  for(int i = 0; i < LED_COUNT * 3; i++){
+    *(p + i) *= rate;
+  }
+}
+
+void do_fade(float rate = FADE_RATE){
+  for(int i = 0; i < FADE_TIMES; i++){
+    fade(rate);
+    ledStrip.write(colors, LED_COUNT);
+    delay(FADE_DELAY);
+  }
+}
+
+void do_flood(){
+  for(int i = 1; i < LED_COUNT; i++){
+    colors[i] = colors[0];
+    states[i] = states[0];    
+  }
+}
+
+rgb_color random_color(){
+  return palette[random(NPRETTY_COLORS)];
+}
+
+int do_random(){
+  push_color(random_color());
 }
 
 void setup_buffer(){


#define BRIGHTNESS_DIVISOR 20.0
#define DEFAULT_BRIGHTNESS_PERCENT 20

// Standard colors
rgb_color black = {0, 0, 0};

    setup_buffer();
    display_buffer();
  }
}

// Compute a random seed by sampling an unconnected analog input pin 
int random_seed(){
  int seed = analogRead(RANDOM_SEED_PIN);
  for(int i = 0; i < 16; i++){
    seed = (seed << 1) ^ analogRead(0);  
  }
  randomSeed(seed);
}

void setup() { 
