5x8 keyboard matrix to MIDI

So I picked up a 37 key (3 octave +1) toy keyboard from a local thrift store, and I want to add MIDI functionality to it. the matrix works out to be 5 grounds (labeled AB0-4) and 8 keys (labeled EF0-7). so for example the first note would be AB0 and EF0, making C2, and say AB4 and EF4 (C4) would be the last note on the actual keyboard (since there are only 37 keys and 40 notes)

What I need to know is how to loop through all of the inputs, and see which ones are connected, then send out the corresponding MIDI note.

I have female midi jacks that I can use and also some CD4051 multiplexers and a bunch of 595 shift registers available for use. I have used the shift registers before to control some LEDS, but as far as multiplexing inputs, i'm totally lost.

All my Arduino sketches are rudimentary., but I am using an Arduino Uno R3.

Keyboard_Matrix.png

Keyboard_Matrix.png

How about using the Keypad.h library to recognize which buttons are pressed?

ok, how would I do that?

You would down load the keypad library and look at the examples that come with it.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.