USB MIDI Support Part 1: The Basics

USB MIDI Support Part 1: The Basics

In preparation for the b2 prototyping (which will feature two front-facing USB OTG connectors), I’m furiously adding support for a few new USB devices. In this case, we’ll specifically talk about USB MIDI controllers. While the USB MIDI standard is fairly cut and dry and there are a few USB MIDI hosts out there for eurorack already, the ‘b and it’s successors have quite a few outputs to play with, so we can be a bit more liberal with the outputs… which should result in a more expressive experience.

Monophonic Controllers

To start with, we’ve got the basics… Each voice on the ‘b has the possibility of 6 different note-specific signals plus any number of channel signals.

As such, the monophonic voice has separate outputs for each of the following:

  • Pitch CV (note + pitchbend)
  • Velocity CV
  • Gate
  • Pressure CV (note pressure)
  • Note ON trigger
  • Note OFF trigger

And of course, there is a common channel aftertouch CV.

Here’s what it looks like in JSON:

That’s fine and dandy, but what about splits? Yeah, that works too. Two separate monophonic voices split across the keyboard:

The Note Stack

A key feature of a monophonic voice is how the key presses stack up and release. The monophonic voice follows a standard pattern of most-recent-key wins. An example of how this works on a few key presses is as follows:

  1. The user presses C2.
  2. The pitch, velocity, and pressure for the C2 note is routed to the respective analog outputs.
  3. The gate output is opened, and the note-on trigger is fired.
  4. The user then presses G2.
  5. The pitch, velocity, and pressure for the G2 note is routed to the respective analog outputs.
  6. The gate remains open (unchanged), and the note-on trigger is fired again.
  7. The user presses C3.
  8. The pitch, velocity, and pressure for the C3 note is routed to the respective analog outputs.
  9. The gate remains open (unchanged), and the note-on trigger is fired again.
  10. The user releases G2.
  11. No changes are made to any of the outputs since G2 is not currently the active note.
  12. The user releases C3.
  13. The pitch, velocity, and pressure for the C2 note is routed to the respective analog outputs.
  14. The gate remains open (unchanged), and the note-off trigger is fired.
  15. The user release C2.
  16. The pitch output remains at C2. The velocity and pressure outputs are changed to 0.
  17. The gate is closed. The note-off trigger is fired.

Up to 16 key presses are stored per monophonic voice. When the split controller is used, each voice gets its own complete voice stack.

That’s a brief overview of the first two MIDI-based devices. Next time we’ll look at continuous controllers and the arpeggiator.

Submit a Comment

Your email address will not be published. Required fields are marked *