 // sequence-bits
 int bs[] = {1, 2, 4, 8, 16, 32, 64, 128, 256};
 
-int instrument_1_seq[8];
-int instrument_2_seq[8];
+int instrument_seq[2][8];
 
 const String sampleFolder = "/mnt/twitterOrchestra/samples/";
 
 void setup() {
-  Bridge.begin();
+//  Bridge.begin();
   Serial.begin(9600);
-  while (!Serial);
+//  while (!Serial);
   String msg = "#BD 10001000";
   parseMessage(msg);
   String msg2 = "#SD 01010101";
   parseMessage(msg2);
-  String msg3 = "#KI 10001010";
+
+  String msg3 = "#I1 51.37.10.40.53.30.16.49";
   parseMessage(msg3);
-  String msg4 = "#CR 01000000";
-  parseMessage(msg4);
-
+  /*  String msg3 = "#KI 10001010";
+    parseMessage(msg3);
+    String msg4 = "#CR 01000000";
+    parseMessage(msg4);
+  */
   nextBInc = MINUTE / bpm;
 }
 

const int EFFECTSTART = 8;
const int EFFECTEND = 10;
//
const int numIns = 6;
byte patterns[numIns - 1];
// length
const int patternL = 8;

    return;
  }
  byte pattern = 0;
  //  Serial.println(patternS);
  for (int i = 0; i < patternL; i++) {
    pattern = pattern << 1;
    byte b = patternS.charAt(i) == '1' ? 1 : 0;
    pattern += b;
  }
  //  Serial.println(pattern);
  patterns[tag] = pattern;
}

void instrument(int tag, String pattern) {
  //  Serial.println(pattern);
  for (int i = 0; i < patternL; i++) {
    Serial.println(pattern.substring(0, 2));
    instrument_seq[tag][i] = pattern.substring(0, 2).toInt();
    pattern = pattern.substring(3);
  }
  for (int i = 0; i < patternL; i++)
    Serial.println(instrument_seq[tag][i]);
}

