This plays musical notes using gestures. It uses its on-board accelerometer to play the C Major scale in the seven octaves of a standard piano.
Step 1: Setup
Set up the app by plugging a Loudspeaker into P4 and (optionally) a Touch Sensor into P5. You don’t really need the touch sensor as the notes can be played by pressing Button D . However, the touch sensor provides a more intuitive and tactile interface…..
If you have an Austem 3D printed handle, attach the loudspeaker and touch sensor to each side with little screws through the holes in the modules. Alternatively, the touch sensor can float freely away from the Kookaberry.
Step 2: Starting the app
Press Button B to run the app. Use the touch sensor or Button D to play the note showing on the screen.
What is showing on the screen?
- Top: The name of the app with the loudspeaker shown as shown as being plugged into P4 and the touch sensor into P5
- Middle: The note to be played when either Button D is pressed or the touch sensor is activated. Its Frequency is shown below the note in Hertz (Hz), or cycles per second.
- Bottom: Button A is Exit from application; Button C is a special effect which “wobbles” the note up and down in frequency when Glissando is toggled ON and OFF; Button B plays the note when pressed.
Step 2: Using the app
The note showing when the Kookaberry is perfectly level is middle C (ie, the note C in the fourth octave of a standard piano – written as C4).
Change the note within the same octave (#4 when level) by tilting the Kookaberry forwards (to lower the note) or backwards (to make it higher).
Change the octave by rotating it to the right (for higher octaves) or to the left (for lower octaves).
- In the screen shots shown above, note the frequencies of the two notes which are an octave apart. What would be the frequency of C5?
- Create a sine waveform with two octave overtones
- Create the musical scale from C4 to B4; multipliers for each octave; and note lengths
- Set up the Digital to Analogue Converter (DAC) to produce and analogue output on P4
- Set up button and touch sensor to play note
- Read accelerometer to set up pitch and octave by tilt and rotation
- Display note, octave, and frequency
- Read Button D or input on P5 to play note.