What You Are Building and Who It Is For
A portable music studio built from M5Stack music devices is a compact live performance rig that combines DIY looper hardware, an open source synthesizer, and touch or MIDI control into a small, desk‑sized system that you can customize in software and extend with open hardware modules for looping, sound design, and real-time play.
You are going to build and use two open‑source instruments side by side: M5KaossLooper, a 4‑track looper with 60 DSP effects on an M5Stack Core2 touchscreen, and M5Stack AMY Synth, a 26‑key CoreS3 instrument with illuminated keys and MIDI input. Together they give bedroom producers and live performers a flexible portable music studio that still fits in a backpack. The real prerequisite is that you are comfortable flashing firmware and following wiring diagrams; you do not need deep DSP theory, because both projects ship with ready‑to‑play code and documentation. The main caveat: you are building performance gear on microcontrollers, so stability depends on following the build steps carefully.

Gather the M5Stack Hardware and Open-Source Code
Before you touch any firmware, lock down your hardware choices. For M5KaossLooper, you need an M5Stack Core2 for AWS, which brings a 320×240 touchscreen, dual‑core ESP32, 8 MB PSRAM, SD slot, power management, and a haptic motor, plus an M5Stack Module Audio with an ES8388 stereo codec providing mic/line TRS input and TRRS headphone output. You also need a micro‑SD card formatted as FAT32 for loop storage and the configuration file, and an instrument or microphone with a TRS cable to feed the looper.
For M5Stack AMY Synth, you need an M5Stack CoreS3 controller, a PCM5102 I2S DAC for stereo line‑level output, a 26‑key diode‑matrix keyboard with one NeoPixel LED per key, an MCP23S17 GPIO expander, a 74HC138 for column selection, an HT16K33 control panel with a three‑digit display, a joystick, potentiometers, and UART wiring for MIDI in. Both devices run Arduino‑compatible firmware and rely on open source repositories, including the KaossLooper code with full hardware references and per‑effect DSP documents and the AMY synthesis engine code used with ESP32 Arduino Core firmware. This open codebase is what lets you tweak the instruments for your own workflow.
Step-by-Step: Assemble, Flash, and Play Both Instruments
Build in stages so you can find problems early. Both projects were developed incrementally for reliability, and copying that process will save you debugging time later. The biggest gotchas are subtle: codec bypass settings that leak dry signal and overloaded cores causing watchdog resets on the looper, and audio interruptions when the synth is juggling display, keys, and controls at once. If you respect the order below, you are far less likely to hit those issues in the middle of a live set.
- Snap the M5Stack Module Audio onto the Core2’s M5‑Bus, insert a FAT32 micro‑SD card, and plug in a TRS cable from an instrument or microphone to the audio input so the KaossLooper has a clean audio path with no extra wiring for the codec or storage.
- Flash the open‑source M5KaossLooper firmware from its repository to the Core2, mount the SD so it can store raw 22050 Hz stereo loops, and confirm the 4‑track looper can record, play, overdub, undo, and quantize recordings to BPM without glitches.
- On the KaossLooper, touch the Core2 touchscreen pad to play the active effect, then use the controls to freeze individual slots at specific XY positions, stack up to eight effect slots, and layer recorded loops while the BPM detector keeps tempo‑based effects and the arpeggiator in sync with your playing.
- Assemble the CoreS3 power and PCM5102 I2S connection for AMY Synth, verify the 5 V and 3.3 V rails, configure AMY for external I2S output, and test a basic sound, taking care that the CoreS3’s internal audio functions do not conflict with the external DAC pin setup.
- Add the 26‑key diode‑matrix keyboard with MCP23S17 and 74HC138, test each row and column individually, then connect and check every NeoPixel LED so that each pressed key lights and releases cleanly without ghost notes.
- Attach the HT16K33‑based control panel, joystick, rotary encoder, potentiometers, and UART MIDI IN to GPIO 44, then flash the AMY Synth firmware built with the ESP32 Arduino Core and AMY engine, confirming that patch selection, LED indicators, analog controls, and MIDI input all respond while audio continues to run without interruption.
- Connect the PCM5102 stereo outputs to an amplifier, mixer, or powered speakers, power on the CoreS3, watch the LED and display self‑test, pick a bank and patch from JUNO‑style, DX7‑style, or piano presets on the touch screen or panel, and play using the 26‑key keyboard or an external MIDI controller with pitch bend and modulation from the joystick.
- Place both completed devices side by side, route the looper output and synth output into your mixer, and start using the KaossLooper for live 4‑track loops with 60 effects while AMY Synth supplies virtual‑analog, FM, or PCM sounds, giving you a portable music studio made of two M5Stack music devices instead of a laptop rig.
Watch for the two main mistakes that trip builders up. On M5KaossLooper, the ES8388 codec’s analog bypass can stay enabled and bleed dry signal until you disable it with a specific two‑register write. On AMY Synth, early firmware revisions saw audio dropouts when LCD, logging, keyboard scanning, and analog reads all hit at once; the fix is to adopt the project’s non‑blocking architecture and avoid heavy debug output during performance.
Why This Setup Feels Like a Real Instrument
Both devices are designed to feel like instruments, not tech demos. The KaossLooper streams loops from micro‑SD in raw 22050 Hz stereo with double buffering, keeping the audio core away from SD access so playback never glitches while you record, overdub, or undo on four tracks. Its DSP engine covers 60 effects, including filters, modulations, delays, reverbs, granular, distortion, and combos, laid out as eight serial slots with individual programs, bypass, and per‑slot hold. Because each slot can freeze at an XY position and be repositioned live, your finger movements on the touchscreen translate directly into sound shaping.
AMY Synth was built to show that a small ESP32‑S3 controller can behave like a dependable open source synthesizer rather than a toy. Its firmware keeps audio running while the CoreS3 simultaneously drives the display, scans the 26‑key matrix, handles NeoPixels, reads MIDI, and manages patches. According to the project’s author, the aim was to make sure that every pressed key sounds reliably, every released key stops correctly, and patch changes stay intuitive even while multiple subsystems are active. Combining touch control on Core2 with MIDI and physical keys on CoreS3 gives you expressive, real‑time performance control instead of menu diving.
Extend, Customize, and Decide If It Is Worth It
Once the basic rig is working, the open‑source nature of both projects is where they start to feel like a true DIY portable music studio. The M5KaossLooper repository includes Arduino‑compatible code, a hardware reference, a full user manual, system architecture notes, and 30 effect design documents, plus a log of bugs such as watchdog reboot loops due to a starved core and I2S FIFO stalls and how they were fixed. That level of documentation makes it much easier to add new effects, change the looper workflow, or integrate the box into your existing pedalboard. The AMY Synth firmware uses the AMY engine with ESP32 Arduino Core, so you can add new virtual‑analog, FM, additive, or PCM patches or adjust how patches and banks are organized.
Is it worth the effort? If you want a plug‑and‑play commercial unit, probably not. But if you like the idea of owning an adaptable M5Stack music device you can recompile overnight, this setup pays off. The main things to watch for are firmware changes that affect timing, heavy UI or logging that could disturb real‑time audio, and low‑level codec settings that can reintroduce dry‑signal bleed or watchdog resets if you rewrite large sections of code. Treat the published GitHub designs as a reference build, keep a stable branch for live use, and you will have a customizable DIY looper hardware and open source synthesizer rig that grows with your skills.






