EX07: Keyboard Instrument

IMPORTANT:

There is a typo in the code in our projects book. At the start of the code, you will make this change:


 

int buttons[6];
// set up an array with 6 integers

//give the first element of the array the value 2
int notes[] = {262, 294, 330, 349};

void setup() {
Serial.begin(9600);
buttons[0] = 2;
}


NOTICE: the int was removed beforeĀ buttons[0] = 2; AND that line of code moved into the setup function.