NOTE: This code and circuit diagram works for my specific keyboard. Your keyboard will likely have a different keyboard matrix (e.g. different numbers of wires coming from the ribbons). You will have to figure out how to change things around for your keyboard. That said, for the piezos, joystick and midi port this will all be fine for you and this will give you the general idea of how to set things up for your keyboard. Also, there is of course no obligation to use the Arduino Nano like I am, you can use whichever type you have.
Software requirements (if using USB to plug into computer):
- hairless midi to serial bridge. See Step 5 from this instructable for more explanation of this.
- If you're using Windows, also loopMIDI. You'll need to run both this and hairless to send MIDI data from the arduino to whichever software you want.
- Any software that can take midi input such as a DAW (Reaper, Ableton, etc).
Circuit diagram