MIDIInput

The MIDIInput interface of the Web MIDI API receives messages from a MIDI input port. Available only in secure contexts.

MDN Reference

Properties

Link copied to clipboard

The connection read-only property of the MIDIPort interface returns the connection state of the port.

Link copied to clipboard
val id: String

The id read-only property of the MIDIPort interface returns the unique ID of the port.

Link copied to clipboard

The manufacturer read-only property of the MIDIPort interface returns the manufacturer of the port.

Link copied to clipboard
val name: String?

The name read-only property of the MIDIPort interface returns the system name of the port.

Link copied to clipboard

The state read-only property of the MIDIPort interface returns the state of the port.

Link copied to clipboard

The type read-only property of the MIDIPort interface returns the type of the port, indicating whether this is an input or output MIDI port.

Link copied to clipboard

The version read-only property of the MIDIPort interface returns the version of the port.

Functions

Link copied to clipboard
suspend fun close(): MIDIPort

The close() method of the MIDIPort interface makes the access to the MIDI device connected to this MIDIPort unavailable.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
suspend fun open(): MIDIPort

The open() method of the MIDIPort interface makes the MIDI device connected to this MIDIPort explicitly available.

Link copied to clipboard
Link copied to clipboard