   }
 }
 
+// Send the colours out to the LEDs---right now also includes the low-pass filtering
 void sendColors(){
-  for(uint8_t y=0; y<ROWS; ++y)
-    for(uint8_t x=0; x<COLS; ++x){
-      for(uint8_t i=0; i<3; ++i)
-        leds[xy2i(x,y)][i] = (uint8_t) (((uint16_t) leds[xy2i(x,y)][i]*19 + new_colors[xy2i(x,y)][i])/20);
-    }
+  // We do not need to use the array structure here---just copy some values
+  for(uint8_t i_led=0; i_led<NUM_LEDS; ++i_led)
+    for(uint8_t i=0; i<3; ++i)
+      leds[i_led][i] = (uint8_t) (((uint16_t) leds[i_led][i]*19 + new_colors[i_led][i])/20);
+  
   LEDS.show();
 }
 
+// Update the colours: in this case, propagate the "on" pixels downwards and seed
+// new pixels on the first row, to obtain a "Matrix effect"
 boolean onPixels[ROWS][COLS];
 void updateColors(){
   
+  // Loop through the rows, starting from the bottom, copying the "on" state from the
+  // row above and then clearing that pixel, to have the "on" state "walk down" the cols
   for(uint8_t y=ROWS-1; y>0; --y)
     for(uint8_t x=0; x<COLS; ++x){
       if(onPixels[y-1][x]){

        onPixels[y][x] = true;
        // and turn off that preceding one
        onPixels[y-1][x] = false;
      } else {
        onPixels[y][x] = false;
      }
    }

  // Seed a new pixel
  if(random(0,10)>7){
    uint8_t randx = random(0,COLS);
    onPixels[0][randx] = true;
    new_colors[xy2i(randx,0)].setHSV(random(0,256), 255, 255);
  }
  
  for(uint8_t y=ROWS-1; y>0; --y)
    for(uint8_t x=0; x<COLS; ++x){
      if(onPixels[y][x]){
        for(uint8_t i=0; i<3; ++i)
          new_colors[xy2i(x,y)][i] = new_colors[xy2i(x,y-1)][i];
      } else {
        for(uint8_t i=0; i<3; ++i)
          new_colors[xy2i(x,y)][i] = 0;
      }
    }
  for(uint8_t x=0; x<COLS; ++x){
    //first row -> turn off the off pixels after propagation of colour
    if(!onPixels[0][x]){

#define NUM_LEDS (ROWS*COLS)

CRGB leds[NUM_LEDS];
CRGB new_colors[NUM_LEDS];


#define LOOP_TIME 20
#define UPDATE_TIME 150


// Return 0-based led index for 0-based x and y grid co-ordinate values
