Melodi Get the app

USB MIDI on Linux

Plug your Android into a Linux computer. ALSA sees it as a MIDI device, no setup needed.

The Linux kernel has a USB MIDI driver built in. The phone shows up in ALSA, and through it in JACK and PipeWire.

  1. 1

    Open the MIDI connection window

    In Melodi, switch the top bar from Sound to MIDI. In Sound mode Melodi plays the notes itself; in MIDI mode it sends them out.

    Then tap the connection button next to it (it says Not connected for now). The MIDI connection window opens, with a card for USB and one for Wi-Fi.

    The MIDI connection window in Melodi
    MIDI connection: one card for USB, one for Wi-Fi
  2. 2

    Connect the cable and choose MIDI

    Use a cable that carries data. Many cables that came with chargers or power banks only charge, and the computer won't see the phone at all.

    Plug the phone in, then pull down the notification shade and tap the USB notification (it usually says Charging this device via USB). Under Use USB for, choose MIDI.

    Android goes back to Charging only every time you unplug. To keep MIDI as the default, turn on Developer options (tap Build number seven times in Settings›About phone), then set Developer options›Default USB configuration to MIDI.

  3. 3

    Connect in Melodi

    Back in Melodi's MIDI connection window, make sure the USB card is switched on. Once the phone is in MIDI mode, a row called Computer (USB) appears in it. Tap Connect.

    The top bar now shows Connected with a green light. If you were connected over Wi-Fi, Melodi switches over to USB: it only uses one connection at a time.

  4. 4

    Check that Linux sees the phone

    Open a terminal and list the MIDI devices:

    amidi -l          # raw MIDI devices
    aconnect -l       # ALSA sequencer clients

    Your phone appears in both, usually under its model name. To watch the notes arrive, start aseqdump on the phone's port and play a few notes in Melodi:

    aseqdump -p "your phone's name"
  5. 5

    Turn on the input in your music app

    Apps that use ALSA list the phone directly in their MIDI input settings. With JACK or PipeWire, the phone appears as a MIDI source in the patchbay: connect it to your app's MIDI input in a graph tool such as qpwgraph, or in your app's own routing.

    Arm or select an instrument track so it plays what comes in.

  6. 6

    Play test notes

    Tap Play test notes at the bottom of the MIDI connection window. Melodi sends a few notes: if your music app's MIDI meter moves and you hear the instrument, everything works.

    Close the window and play. Every screen sends to the same connection, so you can switch between chord pads, keys and drum pads while you play.

Troubleshooting

The phone doesn't show up on the computer at all

Try another cable first: a charge-only cable is the most common cause. Then try another USB port on the computer, preferably one directly on it rather than on a hub or monitor. Check that the phone is still in MIDI mode: Android switches back to charging whenever the cable is unplugged.

There's no MIDI option in the USB menu

Some phones only show it in Developer options: turn them on by tapping Build number seven times in Settings›About phone, then set Developer options›Default USB configuration to MIDI.

Computer (USB) doesn't appear in Melodi

Switch the USB card off and on again in the MIDI connection window, or unplug the cable, wait a few seconds and plug it back in. The row appears only while the phone is in MIDI mode.

Notes arrive late or stutter

USB timing is normally very tight. If it isn't, turn off battery saver on the phone, close apps that play audio in the background, and make sure Melodi is set to MIDI, not Sound.

Updated October 25, 2026 · Something not working? Write to contact@melodiapp.com