The component which connects to the keyboard
As a pianist, I've always wanted to play the piano while walking, perhaps in a marching band. However, while there are plenty of ways to carry a piano while walking, they all sacrifice a key functionality of the piano: the sustain pedal. All sustain pedals are designed to stay in place, and wire up to a (supposedly) stationary keyboard. What's more, to make any of these portable, I'd would have to run wires up my legs, which was a huge limitation if I wasn't wearing something which covered them up.
One night, I decided that I've had enough of this limitation, and decided to address this problem once and for all.
What it does
We've designed a sustain pedal which allows for wireless and portable control. The first part consists of two components: a sender and a receiver. The sender is small and lightweight, and can be attached to the bottom of a shoe, while the receiver is attached directly to the piano. The sender is designed to send an IR code whenever I take a step, and the receiver can then wirelessly decode the signal and simulate a MIDI sustain pedal when a signal is received.
While this basic pair works perfectly as a wireless sustain pedal, it doesn't quite match the current trends towards the internet of things. As such, we've decided to integrate a Bluetooth receiver into the system, as well as a corresponding smartphone app to control the sender. Now, it becomes possible to control your sustain pedal from your smartphone!
Unfortunately, while testing this, we found that it was difficult to use one hand for the smartphone app while still using both hands to play the piano. As such, we added one final part to the whole system: by taking a standard MIDI sustain pedal and using it as a switch for a servo, we can now use our other foot to control a robotic stylus that will use our app in our place! Overall a flawless system.
How we built it
The full system uses four microcontrollers: one for the IR sender, one for the IR receiver, one for the Bluetooth receiver, and one for the servo controller. Each of the microcontrollers (an Arduino Nano) is programmed independently, and communicate with each other.
The IR sender is programmed to send a series of pulses at 56 kHz every 30 ms, which we discovered to be the optimal signal length for our IR receiver to decode. The IR receiver then feeds into another Arduino, which controls en electromechanical relay that serves to simulate the sustain pedal. This Arduino also communicates with the Bluetooth receiver, which can also control the relay.
Finally, the last Arduino controls a servo with a stylus attached, and uses a MIDI sustain pedal as a switch to activate the servo. This can be used to control the Android app, which in turn communicates with the Bluetooth receiver, which in turn communicates with the IR receiver, which then controls the relay which controls the pedal.
Challenges we ran into
- Reverse engineering our IR sensor to optimize the frequency response of our sender
- Powering all four circuits with only two power sources
- Streamlining the hardware design to be compact and lightweight
Accomplishments that we're proud of
- Low latency and fast response time (excluding the servo part)
- The streamlined look of all the hardware
- Humor of the full-circle progression of components
What we learned
- How to arrange and solder together components
- How IR sensors filter and interpret IR codes from the ambient environment
- How to use Bluetooth in a low-level application
What's next for Smart Pedal
- Custom PCBs for further compactness
- Integration within the keyboard for minimum form factor
- Battery powering all components to further remove need for wires