WAVR PLUGIN · WEB MIDI API · v1.0.0

MIDI CTRL PLUGIN

Connect any hardware MIDI device to your browser. Route notes, CC, and transport commands to WAVR PRO or any Web Audio application. Live piano display, CC bar graph, configurable mappings, MIDI log.

0
DEPENDENCIES
3
DEFAULT CC MAPS
CUSTOM MAPPINGS
16
MIDI CHANNELS
— no device —
waiting...
KEYS — C3–B4
CC ACTIVITY
CC1
CC7
CC10
CC11
CC64
MIDI LOG
WEB MIDI API AUTO-CONNECT HOT-PLUG SUPPORT CC MAPPINGS TRANSPORT COMMANDS LIVE PIANO DISPLAY MIDI LOG CHANNEL FILTER SESSION PERSISTENT ZERO DEPENDENCIES WEB MIDI API AUTO-CONNECT HOT-PLUG SUPPORT CC MAPPINGS TRANSPORT COMMANDS LIVE PIANO DISPLAY MIDI LOG CHANNEL FILTER SESSION PERSISTENT ZERO DEPENDENCIES
CAPABILITIES

Everything MIDI.
Nothing extra.

Wraps the Web MIDI API as a self-contained plugin. Works standalone or registered inside WAVR PRO — same class, same API either way.

Auto-connect
First detected device connects automatically. Hot-plug: plug in a device mid-session and it appears in the dropdown instantly via onstatechange.HOT-PLUG
Note display
A two-octave piano keyboard (C3–B4) lights up on every incoming Note On. White keys go purple, black keys go lavender. Note Off clears them immediately.VISUAL
CC bar graph
Six common CC numbers (1, 7, 10, 11, 64, 74) show live bar graphs. Bars animate on every message. Cached bars turn green after first touch.MONITORING
CC routing
Map any CC number to BPM, master volume, or transport toggle. Three built-in maps, unlimited custom targets. Add or remove from the UI or via setState().ROUTING
Transport
MIDI Clock Start/Stop/Continue messages fire the onTransport callback and, when in WAVR PRO, toggle the host transport.TRANSPORT
Channel filter
Select a specific MIDI channel (1–16) or listen to all channels. Filter applies immediately — no restart needed. Saved in session state.FILTER
SIGNAL PATH

From hardware
to browser.

Every MIDI message travels through a single well-defined path. No polling, no timers — events are delivered by the browser's MIDI runtime.

🎹
MIDI Device
Keyboard, pad controller, or any class-compliant USB/BLE MIDI device
🌐
Web MIDI API
navigator.requestMIDIAccess()
Browser runtime delivers events
MidiController
Parses status bytes, routes to callbacks, updates UI
onNote / onCC
Your callbacks, or WAVR PRO host if registered as a plugin
WAVR PRO
BPM, volume, transport — controlled by CC in real time
CC MAPPINGS

Map any knob
to anything.

Three built-in mappings cover the most common use cases. Add custom targets in the UI, or pass a ccMap object into setState().

CC 1
BPM control
Maps CC 0–127 to BPM 60–180. Move the mod wheel to tempo-scrub.
Default · mod wheel on most keyboards
CC 7
Master volume
Maps CC 0–127 to 0–100%. Immediate — no latency, directly sets the master gain node.
Default · channel volume (MIDI spec)
CC 64
Transport toggle
Value 127 (pressed) fires play/pause on the WAVR PRO host transport.
Default · sustain pedal on most keyboards
CC N
Custom target
Add any CC → target string pair. Handle it in your onCC callback.
User-defined · unlimited
Session persistence AUTOMATIC
All CC mappings, the selected device ID, and the channel filter are saved via getState() / setState(). WAVR PRO restores them when the plugin is reopened.
Add via setState()
mc.setState({
  ccMap: {
    1:  "bpm",
    7:  "master_volume",
    64: "transport_toggle",
    74: "my_custom_target",
  }
});
Handle in onCC
mc.onCC = ({ cc, value }) => {
  if (cc === 74) {
    myFilter.frequency.value =
      200 + value * 120;
  }
};
GET STARTED

Three lines to
connect hardware.

Standalone in any framework, or registered in WAVR PRO. The API is identical either way.

// npm
npm install wavr-midi-controller

// standalone
import MidiController from 'wavr-midi-controller';

const mc = new MidiController({
  onNote: ({ note, velocity, type }) => {
    console.log(type, note, velocity);
  },
  onCC: ({ cc, value }) => {
    // react to any CC
  },
  onTransport: ({ command }) => {
    // "start" | "stop" | "continue"
  },
  onConnect:    (port) => {},
  onDisconnect: (port) => {},
});

mc.mount(document.getElementById('container'));

// WAVR PRO plugin
pluginManager.register(MidiController);
// Opens as a drawer from the topbar.
Browser Web MIDI Notes
Chrome 43+ ✓ Native Full support
Edge 79+ ✓ Native Full support
Firefox No native support
Safari No native support
iOS Safari No native support
⚠ HTTPS REQUIRED
navigator.requestMIDIAccess() is blocked on http://. The plugin works on https:// and localhost. GitHub Pages is HTTPS by default.
GRACEFUL FALLBACK
On unsupported browsers the plugin mounts normally and renders a warning message. All callbacks simply receive no events — no errors thrown.
CONNECT

Plug in
and play.

Download, register, and your hardware MIDI device is talking to WAVR PRO.