   if (button2.toggled()) {
     if (button2.read() == Button::PRESSED) {
       Serial.println("Button 2 has been pressed");
-      digitalWrite(ledPin, HIGH);
+      showLED(LED_YELLOW);
       if (isConnected) {
         // Send the note to reaper to set the marker
         sendMidiNote(true, 0, 0, 64);
       }
     } else {
       Serial.println("Button 2 has been released");
-      digitalWrite(ledPin, LOW);
+      showLED(LED_OFF);
       if (isConnected) {
         sendMidiNote(false, 0, 0, 64);
       }

  if (button1.toggled()) {
    if (button1.read() == Button::PRESSED) {
      Serial.println("Button 1 has been pressed");
      digitalWrite(ledPin, HIGH);
      if (isConnected) {
        sendMuteCommand(true);
      }
    } else {
      Serial.println("Button 1 has been released");
      digitalWrite(ledPin, LOW);
      if (isConnected) {
        sendMuteCommand(false);
      }

  /* no action, ignoring the incomming data */
}

void showLED(unsigned char state)
{
  switch(state)
  {
    case LED_YELLOW:
      digitalWrite(ledYellow, HIGH);
      digitalWrite(ledRed, LOW);
      break;
    case LED_RED:
      digitalWrite(ledYellow, LOW);
      digitalWrite(ledRed, HIGH);
      break;      
    case LED_OFF:
    default:
      digitalWrite(ledYellow, LOW);
      digitalWrite(ledRed, LOW);
  }
}

void setup()
{
  Serial.begin(115200);
