Introduction: MuseScore+Arduino+LEDs+MIDI = Piano Tutor
This article explains how to turn your MIDI-capable keyboard or digital piano into a full piano learning & tutoring system, i.e., an interactive lighted keyboard/piano, based on the open-source MuseScore sheet music editor & player, a common Arduino board and a LED stripe. The system will let you practice a piano piece on the keyboard without any need for reading sheet music: just load any MIDI file on MuseScore, play it activating the Piano Tutor function, and then follow the LEDs lighting up on the stripe deployed along your keyboard, repeating as many times as needed.
Step 1: Hardware Set-up
First, connect the NeoPixel LED stripe to your Arduino, plugging the black and red wires of the stripe to the GND and +5V pins on your Arduino. Also, connect the input data wire to the pin n.7 on your Arduino. The image shows how I did it in detail, however you can find more details on the Adafruit website.
Step 2: Software - Arduino
Download the software:
git clone https://github.com/tomcucinotta/MuseScore.git cd MuseScore git checkout piano-tutor
Install the Arduino IDE on your PC/laptop, then open within the above checked out git repository the miditools/PianoTutor/PianoTutor.ino file, and upload the program onto Arduino.
Step 3: Software - MuseScore on Linux
Ensure you have all the build dependencies on your Linux PC:
sudo apt-get build-dep musescore sudo apt-get install cmake-qt-gui
then, compile and install the modified MuseScore:
make PREFIX=/usr/local/mscore-git SUFFIX=-git release sudo make install
now you're ready to launch it, opening a MIDI file of your choice:
and opening the Piano Tutor pane, pressing 't' (visible in the picture).
Step 4: MIDI Connections
Ensure your USB MIDI keyboard, or MIDI-to-USB adapter, is plugged into your Linux PC/laptop, and use qjackctl to ensure its MIDI port is connected to the MuseScore MIDI input port (see picture).
Step 5: Have Fun!
Have fun practicing with the millions MIDI files available on the Internet, without the burden of reading sheet music ;-)! You can see a video of the system in action on YouTube.
Should you have any trouble in any of the steps in these instructions, then please check out the additional details available here.
DavidR882 made it!