midi
type: Ontology
documentation: This specification defines a data type for a MIDI message, midi:MidiEvent, which is normalised for fast and convenient real-time processing. MIDI is the Musical Instrument Digital Interface, a ubiquitous binary standard for controlling digital music devices. For plugins that process MIDI (or other situations where MIDI is sent via a generic transport) the main type defined here, midi:MidiEvent, can be mapped to an integer and used as the type of an LV2 Atom or Event. This specification also defines a complete human and machine readable description of the MIDI standard (except for standard controller numbers). These descriptions are detailed enough to express any MIDI message as properties.

Active Sense Message
type: Class
subclass of: System Realtime Message

Aftertouch Message
type: Class
subclass of: Voice Message;
chunk:
  byte number: 0
  property: noteNumber
chunk:
  byte number: 1
  property: pressure

Bender Message
type: Class
subclass of: Voice Message;
chunk:
  byte number: 0
  byte number: 1
  property: benderValue

Channel Pressure Message
type: Class
subclass of: Voice Message;
chunk:
  byte number: 0
  property: pressure

Chunk
type: Class
comment: A series of contiguous bytes (usually one) in a message.

Clock Message
type: Class
subclass of: System Realtime Message

Continue Message
type: Class
subclass of: System Realtime Message

Controller Change Message
type: Class
subclass of: Voice Message;
chunk:
  byte number: 0
  property: controllerNumber
chunk:
  byte number: 1
  property: controllerValue

MIDI Message
type: Class
subclass of: Event
subclass of: Atom
string type: hexBinary
documentation: A single raw MIDI message (i.e. a sequence of bytes). This is equivalent to a standard MIDI messages, except with the following restrictions to simplify handling: Running status is not allowed, every message must have its own status byte. Note On messages with velocity 0 are not allowed. These messages are equivalent to Note Off in standard MIDI streams, but here only proper Note Off messages are allowed. "Realtime messages" (status bytes 0xF8 to 0xFF) are allowed, but may not occur inside other messages like they can in standard MIDI streams. All messages are complete valid MIDI messages. This means, for example, that only the first byte in each event (the status byte) may have the eighth bit set, that Note On and Note Off events are always 3 bytes long, etc. Where messages are communicated, the writer is responsible for writing valid messages, and the reader may assume that all events are valid. If a midi:MidiEvent is serialised to a string, the format should be xsd:hexBinary, e.g. (in Turtle notation): [] eg:someEvent "901A01"^^midi:MidiEvent .

Note Off Message
type: Class
subclass of: Voice Message;
chunk:
  byte number: 0
  property: noteNumber
chunk:
  byte number: 1
  property: velocity

Note On Message
type: Class
subclass of: Voice Message;
chunk:
  byte number: 0
  property: noteNumber
chunk:
  byte number: 1
  property: velocity

Program Change Message
type: Class
subclass of: Voice Message;
chunk:
  byte number: 0
  property: programNumber

Quarter Frame Message
type: Class
subclass of: System Common Message

Reset Message
type: Class
subclass of: System Realtime Message

Song Position Pointer Message
type: Class
subclass of: System Common Message
chunk:
  byte number: 0
  byte number: 1
  property: songPosition

Song Select Message
type: Class
subclass of: System Common Message

Start Message
type: Class
subclass of: System Realtime Message

Stop Message
type: Class
subclass of: System Realtime Message

System Common Message
type: Class
subclass of: System Message

System Exclusive Message
type: Class
subclass of: System Message

System Message
type: Class
subclass of: MIDI Message

System Realtime Message
type: Class
subclass of: System Message

Tune Request Message
type: Class
subclass of: System Common Message

Voice Message;
type: Class
subclass of: MIDI Message

benderValue
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: short
comment: The value of a pitch bender (-8192 to 8192).

binding
type: Property
type: ObjectProperty
range: MIDI Message
documentation: The MIDI event to bind a parameter to. This describes which MIDI events should be used to control a port, parameter, or other object. The binding should be a midi:MidiEvent but the property that represents the control value may be ommitted. For example, to bind to the value of controller 17: port midi:binding [ a midi:Controller ; midi:controllerNumber 17 ] .

byteNumber
type: Property
type: DatatypeProperty
domain: Chunk
range: unsignedByte
comment: The 0-based index of a byte which is part of this chunk.

channel
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: unsignedByte
comment: The channel number of a MIDI message.

chunk
type: Property
range: byte
range: hexBinary
comment: A chunk of a MIDI message.

controllerNumber
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: byte
comment: The numeric ID of a controller (0 to 127).

controllerValue
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: byte
comment: The value of a controller (0 to 127).

noteNumber
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: byte
comment: The numeric ID of a note (0 to 127).

pressure
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: byte
comment: Key pressure (0 to 127).

programNumber
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: byte
comment: The numeric ID of a program (0 to 127).

property
type: Property
type: ObjectProperty
type: FunctionalProperty
domain: Chunk
range: Property
comment: The property this chunk represents.

songNumber
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: byte
comment: The numeric ID of a song (0 to 127).

songPosition
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: short
comment: Song position in MIDI beats (16th notes) (-8192 to 8192).

status
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: byte
range: hexBinary
comment: The exact status byte for a message of this type.

statusMask
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: byte
range: hexBinary
comment: The status byte for a message of this type on channel 1, i.e. a status byte with the lower nibble set to zero.

velocity
type: Property
type: DatatypeProperty
type: FunctionalProperty
range: byte
comment: The velocity of a note message (0 to 127).