   }
 }
 
-void displayBuffer(uint16_t *ledStates) {
+void displayBuffer(uint16_t *ledStates, int colour) {
   for(int y = 0; y < 8; y++) {
     for(int x = 0; x < 16; x++) {
       if(ledStates[y] & (1 << x)) {
-        strip.setPixelColor(127 - (y * 16 + x), strip.Color(200,   200,   200));
+        strip.setPixelColor(127 - (y * 16 + x), Wheel(colour));
       } else {
         strip.setPixelColor(127 - (y * 16 + x), strip.Color(0,   0,   0));
       }

  PRINT_DEBUG("  | ");


 
   
  if (LDRValue < 350) {
    Brightness = 12;
  } else if (LDRValue > 1000) {
      Brightness = 255;
    }  
    else Brightness = map(LDRValue,350,1000,12,255);
  
  strip.setBrightness(Brightness);
  matrix.setBrightness(Brightness);

  }
  else if (KnobValue < 150){
    //rainbow!
//    rainbowCycle(map(KnobValue, 50, 149, 0, 50));
    PRINT_DEBUG("rainbow1 - delay ");
    PRINTLN_DEBUG(map(KnobValue, 50, 149, 0, 50));
    displayBuffer2(ledStates, map(KnobValue, 50, 149, 0, 50));
    
    
  }else if (KnobValue < 300){
    //rainbow!
    displayBuffer3(ledStates, map(KnobValue, 150, 299, 0, 50));
    PRINT_DEBUG("rainbow2 - delay ");
    PRINTLN_DEBUG(map(KnobValue, 150, 299, 0, 50));
    
  }
  else  if (KnobValue <1000){
    //solid colour
    int colour = map(KnobValue, 300, 999, 0, 255);
    PRINT_DEBUG("Show the time, solid colour ");
    PRINTLN_DEBUG(colour);
    displayBuffer(ledStates, colour);
   
  } 
  
  else {
    PRINTLN_DEBUG("Show the time, all white");
      displayBuffer_WHITE(ledStates);
  }
}

