POOM MIDI Lab: Motion Becomes Music
Connect POOM as a Bluetooth MIDI instrument, select C major, and turn accelerometer motion into piano notes in Chromium browsers.
I do not consider myself a musician, but there is something wonderful about MIDI: it can turn almost anything into an instrument.
For this lab, we will not use POOM like a tiny keyboard. We will use something already inside it: the accelerometer.
Move your hand, make a hit in the air, rotate POOM, or move with it while listening. You may end up dancing and turning your movements into music. It all depends on your aura.
POOM processes accelerometer motion and converts it into MIDI events sent over Bluetooth. Motion stops being only X, Y, and Z and starts becoming notes, hits, and sound.
We will use GarageBand for the example because it provides a quick way to try several instruments on an iPhone or iPad. Other BLE MIDI-compatible music apps can work too.
First, what is MIDI?
MIDI means:
Musical Instrument Digital Interface
The most important idea is:
MIDI is not audio.
POOM does not send the sound of a drum, piano, or synthesizer over Bluetooth. It sends musical instructions such as:
- play this note;
- stop playing this note;
- play it with this intensity;
- change a control or instrument parameter.
Note ON
C4
Velocity 90
This message does not contain a piano recording. It means something like: "Play this note with this intensity."
GarageBand decides how the event sounds. Select a piano and you hear a piano. Select drums and you hear percussion. Choose a synthesizer and the same event creates a different sound.
The controller and the instrument do not need to be the same thing. Our controller is especially unusual: it has no keys. It has motion.
The accelerometer is our instrument
POOM observes acceleration on the X, Y, and Z axes. Those measurements are not music by themselves; the firmware must interpret them.
For example, the firmware can detect that a movement is strong enough to count as a hit, then generate a MIDI note.
- POOM detects movement.
- The accelerometer provides data.
- The firmware analyzes its intensity.
- POOM decides whether the motion represents an event.
- POOM generates a MIDI note.
- The event travels over BLE.
- GarageBand receives the event.
- The selected instrument generates sound.
The experiment is about turning physical motion into a musical action.
MIDI over Bluetooth
POOM does not need a USB connection to the iPhone, iPad, or computer while you play. It detects motion and sends BLE MIDI events; the music app generates the audio.
| POOM | GarageBand or another music app |
|---|---|
| Detects motion. | Receives the MIDI event. |
| Processes accelerometer data. | Uses the selected instrument. |
| Decides when an event happened. | Generates the sound. |
| Creates and sends the MIDI message over BLE. | Lets you change the sound without changing POOM's firmware. |
Enter the MIDI Lab
- On POOM, open THE ZEN from the main menu.
- Select MIDI and press A.
Opening the app starts:
poom_air_drums
POOM begins reading the accelerometer and starts its BLE MIDI service. The screen displays the Bluetooth state:
BLE: PAIRING
This means POOM is waiting for another device. After a phone, tablet, or computer connects, it changes to:
BLE: CONNECTED
The screen also shows MIDI parameters such as:
Note: C4=60
Thr
DRUM
MELODY MAJOR
MELODY MINOR
Play POOM through the browser piano
You can hear POOM without installing a DAW. The mini player below connects directly over BLE MIDI and turns every incoming note into a piano sound.
First, configure POOM for C major:
- On POOM, open THE ZEN, select MIDI, and press A.
- Use UP / DOWN to select
Note, then set it toC4=60. - Select
Mode / Melody, then set it toMelody:MAJOR. - Confirm that POOM displays
BLE: PAIRING. - Press Connect POOM in the piano and choose
poom-midi.
C4=60 + Melody:MAJOR uses the C-major pentatonic notes C, D, E, G, and A.Air Drums
DRUM is the easiest mode for your first experiment. Imagine POOM as an invisible drumstick.
Move POOM. The accelerometer measures the motion. If its intensity crosses the configured threshold, the firmware generates a MIDI note.
Hit in the air
Accelerometer
Detection
MIDI event
GarageBand
Sound
You do not need a physical drum or even a surface to hit. Try short movements, wider swings, following a song's rhythm, or moving your whole body.
Is it the world's most serious musical instrument? Probably not. Is it fun? Definitely.
The motion threshold
Thr is the detection threshold. It matters because the accelerometer measures continuously, and even a stationary POOM produces tiny variations.
| Threshold | Result |
|---|---|
| Too low | Tiny movements and sensor noise may generate notes constantly. |
| Too high | You must move POOM very strongly before it generates an event. |
| Comfortable | Intentional gestures trigger notes without constant false hits. |
The sensor only reports numbers:
Ax = ...
Ay = ...
Az = ...
The firmware decides when those numbers mean "this was an important movement" and then "this movement should become a MIDI note."
That small decision is what transforms a sensor into an application.
Melody modes
MELODY MAJOR and MELODY MINOR move beyond drum hits. Your gestures generate notes from different scales.
You do not need music theory to begin. Move POOM, listen, change the note or mode, and move it again. You may find a combination that sounds good almost by accident.
Play with notes until you discover something interesting.
Controls
| Control | Action |
|---|---|
UP / DOWN | Select the parameter to modify. |
LEFT / RIGHT | Change the selected value. |
Note | Change the MIDI note. |
Thr | Change the motion-detection threshold. |
Mode / Melody | Switch between DRUM, MELODY MAJOR, and MELODY MINOR. |
A | Send Panic / All Notes Off. |
B | Exit the application. |
You can change parameters while playing. The current menu is designed for live experimentation; these values are not persistent presets saved to the microSD card or device memory.
What does Panic mean?
A MIDI note normally uses a pair of events:
NOTE ON
NOTE OFF
During testing, a note may remain active if its corresponding Note Off event does not arrive. The result is a sound that continues indefinitely.
Press A to send:
ALL NOTES OFF
It is a quick way to say: "Stop everything that is playing."
Try it with GarageBand
- On POOM, open THE ZEN, select MIDI, and press A.
- Wait for POOM to display
BLE: PAIRING. - Open GarageBand on your iPhone or iPad.
- Choose an instrument such as drums, piano, percussion, or a synthesizer.
- Open GarageBand's Bluetooth MIDI device browser and connect to POOM.
- Confirm that POOM displays
BLE: CONNECTED. - Move POOM and listen.
Try short and strong movements. Adjust Thr, change the note, switch to a melody mode, and choose another GarageBand instrument.
There is no single correct way to play it. This is an experiment.
The same motion can sound completely different
Make exactly the same gesture with POOM while GarageBand uses drums. You hear percussion. Change to a piano, and the same motion produces a piano note. Change again, and it becomes a synthesizer.
POOM did the same thing each time: it detected motion and sent a MIDI event. The receiving instrument changed how that event sounded.
You also do not need to keep touching or watching the phone. GarageBand can remain open while POOM becomes the controller:
Motion
POOM
MIDI
Sound
From motion data to music
In the Maker PLOT lab, we observe accelerometer signals and watch the values change when POOM moves. Here, we take the next step. We do not only want to see the signal; we want to do something with it.
- Measure motion.
- Interpret the data.
- Detect an event.
- Generate MIDI.
- Let the instrument generate sound.
This is how many embedded applications begin: collect sensor data, give it meaning, and use that meaning to control something.
Where could this go next?
The current firmware is a foundation for experimentation. Future versions could map:
- upward and downward gestures to different notes;
- rotation to instrument or effect changes;
- motion intensity to MIDI velocity;
- orientation to different sounds;
- gestures to chords;
- continuous movement to effect controls;
- two POOM devices to two drumsticks;
- accelerometer and gyroscope data to a complete motion instrument.
Motion
Orientation
Rotation
All of that information can become MIDI control.
Build your own instrument
This experiment shows how an electronic drum kit or a completely new instrument could begin:
Sensor
MIDI event
From there, add:
Pads
Sensors
Hits
Velocity
Gestures
Buttons
Effects
It does not need to become a drum kit. It can become any instrument you can imagine.