DIY PIANO FOR ARDUINO UNO

The general idea of my project is to produce a piano keyboard using arduino uno and a drawn keyboard using lead pencil and a paper.

Arduino uno only have 14 io digital ports, plus 6 analog ports, (which can be converted into digital ports).

The problem is that I want to have atleast 61 keys (like a commercial piano) that can be hooked up to the arduino uno. But stated above, the arduino has only a total of 20 inputs.

I tried to research and came up with using a multiplexer to control multiple inputs. So I thought that it might be possible to connect the multiplexers in series to have atleast 61 inputs. From there, the output will be sent to the arduino and a bunch of codes will determine which key was selected/pressed. By determining the key pressed, it will have a corresponding note value that the "pitches.h" library provides therefore recreating the sound of a piano.

This is a very rough sketch of an idea. Trying to reach out to the pros out there. he he.

btw, newbie here. this is for my MPU class project. Thank in advance!

So I thought that it might be possible to connect the multiplexers in series to have atleast 61 inputs.

Yes, or you can chain 8 shift registers or use 4 MCP23016 expander chips.

But first get it working with the input pins you have on the Arduino because I think you will find that pencil graphite is not as nice as you may hope.

You can use conductive paint and a spoon as a playing styles like I did in this book I wrote http://www.apress.com/9781484217207

thank you for your reply sir! :)

well i researched more about my project. and i found out that i need to include in my code a capacitive sensor for the drawn piano keys. since i don't have access to any conductive paint, i guess im going for the capacitive sensor. hehe.

my question now is that can it produce multiple sound/notes at the same time in one output port? e.g. if I press the "G", "A", "B" keys at the same time, will it play like a chord?

i guess im going for the capacitive sensor

For 61 inputs, you will be lucky.

can it produce multiple sound/notes at the same time in one output port

Yes but not easily.

I think you might have just pushed this project out beyond your reach.

Grumpy_Mike:
I think you might have just pushed this project out beyond your reach.

Atleast i know that my project is plausible :slight_smile: thank you sir.

I guess this is the purpose of my post here. To seek help to you kind sirs for guidance and good feedbacks, for help in general haha.

See my project here where I used a '1284P to read 13 inputs and create 13 output that were then mixed as analog signals to make an output to feed to an amplifier. Can use several chips, one per octave, to do the same for more keys to keep the playing good and responsive. http://forum.arduino.cc/index.php?topic=179761.0

CrossRoads: See my project here where I used a '1284P to read 13 inputs and create 13 output that were then mixed as analog signals to make an output to feed to an amplifier. Can use several chips, one per octave, to do the same for more keys to keep the playing good and responsive. http://forum.arduino.cc/index.php?topic=179761.0

Very nice project you have there! :) can i use this as my basis for my project?

Soo, in general, i have to provide several 1284P to recreate the 61 keys. One per octave.

Go for it, you will not have been the first.