Main Content

mididevinfo

MIDI device information

Description

mididevinfo displays a table containing information about the MIDI devices attached to the system.

example

deviceInformation = mididevinfo returns a structure, deviceInformation, containing information about the MIDI devices attached to the system.

Note

Before starting MATLAB®, connect your MIDI device to your computer and turn on the device. For connection instructions, see the instructions for your MIDI device. If you start MATLAB before connecting your device, MATLAB might not recognize your device when you connect it. To correct the problem, restart MATLAB with the device already connected.

example

Examples

collapse all

Call mididevinfo to display a table containing information about the MIDI devices attached to your system.

mididevinfo
  MIDI devices available:
  ID  Direction  Interface   Name
   0   output    MMSystem   'Microsoft MIDI Mapper'
   1    input    MMSystem   'BCF2000'
   2    input    MMSystem   'MIDIIN2 (BCF2000)'
   3   output    MMSystem   'Microsoft GS Wavetable Synth'
   4   output    MMSystem   'BCF2000'
   5   output    MMSystem   'MIDIOUT2 (BCF2000)'
   6   output    MMSystem   'MIDIOUT3 (BCF2000)'

Call mididevinfo with an output argument to return a structure containing MIDI device information.

deviceInformation = mididevinfo
deviceInformation = struct with fields:
     input: [0×0 struct]
    output: [1×2 struct]

The deviceInformation structure has two fields: input and output. Both input and output contain arrays of structures. Each member has three fields: Name, Interface, and ID. Get the device information for the output Microsoft GS Wavetable Synth device.

deviceInformation.output(2)
ans = struct with fields:
         Name: 'Microsoft GS Wavetable Synth'
    Interface: 'MMSystem'
           ID: 1

Output Arguments

collapse all

Description of available devices, returned as nested structures. The outer structure has two fields: input and output. The input and output values are arrays of structures, and each member has three fields: Name, Interface, and ID.

Data Types: struct

Version History

Introduced in R2018a