---
title: MIDI Services
framework: coremidi
role: collectionGroup
role_heading: API Collection
path: coremidi/midi-services
---

# MIDI Services

Communicate with hardware using Universal MIDI Packets.

## Overview

Overview MIDI drivers own and control physical MIDI devices, which include hardware such as USB interfaces, MIDI keyboards, and so on. A MIDI device may have multiple logically distinct subcomponents. For example, one device may contain a MIDI synthesizer and a pair of MIDI ports, both addressable over a USB port. Each element of a device is a MIDI entity. A MIDI entity can have any number of MIDI endpoints, each of which is a source or destination of a 16-channel MIDI stream. Grouping a device’s endpoints into entities provides the system enough information for an app to make reasonable default assumptions about how to communicate bidirectionally with each entity, as is necessary in MIDI librarian apps. Core MIDI attaches a collection of properties to each object it manages. Object properties can be: Dynamic characteristics of a device, such as MIDI receive channel and system-exclusive (SysEx) IDs. Determined by user preference; for example, choice of icon, and whether or not the device appears in lists of possible controllers. Static properties that you can’t look up in a database using the device’s manufacturer and model name. The Core MIDI framework uses interprocess communication (IPC) to communicate with a server process, the MIDI server. The server process in turn loads the MIDI driver and manages all communication with it.

## Topics

### MIDI object configuration

- [MIDIObjectFindByUniqueID(_:_:_:)](coremidi/midiobjectfindbyuniqueid(_:_:_:).md)
- [MIDIObjectRef](coremidi/midiobjectref.md)
- [MIDI Object Properties](coremidi/midi-object-properties.md)

### Client management

- [Incorporating MIDI 2 into your apps](coremidi/incorporating-midi-2-into-your-apps.md)
- [MIDIClientCreate(_:_:_:_:)](coremidi/midiclientcreate(_:_:_:_:).md)
- [MIDIClientCreateWithBlock(_:_:_:)](coremidi/midiclientcreatewithblock(_:_:_:).md)
- [MIDIClientDispose(_:)](coremidi/midiclientdispose(_:).md)
- [MIDIClientRef](coremidi/midiclientref.md)

### Device lookup

- [MIDIGetNumberOfDevices()](coremidi/midigetnumberofdevices().md)
- [MIDIGetDevice(_:)](coremidi/midigetdevice(_:).md)
- [MIDIGetNumberOfExternalDevices()](coremidi/midigetnumberofexternaldevices().md)
- [MIDIGetExternalDevice(_:)](coremidi/midigetexternaldevice(_:).md)
- [MIDIDeviceGetNumberOfEntities(_:)](coremidi/mididevicegetnumberofentities(_:).md)
- [MIDIDeviceGetEntity(_:_:)](coremidi/mididevicegetentity(_:_:).md)
- [MIDIDeviceRef](coremidi/midideviceref.md)

### Entity lookup

- [MIDIEntityGetDevice(_:_:)](coremidi/midientitygetdevice(_:_:).md)
- [MIDIEntityGetNumberOfSources(_:)](coremidi/midientitygetnumberofsources(_:).md)
- [MIDIEntityGetSource(_:_:)](coremidi/midientitygetsource(_:_:).md)
- [MIDIEntityGetNumberOfDestinations(_:)](coremidi/midientitygetnumberofdestinations(_:).md)
- [MIDIEntityGetDestination(_:_:)](coremidi/midientitygetdestination(_:_:).md)
- [MIDIEntityRef](coremidi/midientityref.md)

### Port management

- [MIDIInputPortCreateWithProtocol(_:_:_:_:_:)](coremidi/midiinputportcreatewithprotocol(_:_:_:_:_:).md)
- [MIDIOutputPortCreate(_:_:_:)](coremidi/midioutputportcreate(_:_:_:).md)
- [MIDIPortDispose(_:)](coremidi/midiportdispose(_:).md)
- [MIDIPortConnectSource(_:_:_:)](coremidi/midiportconnectsource(_:_:_:).md)
- [MIDIPortDisconnectSource(_:_:)](coremidi/midiportdisconnectsource(_:_:).md)
- [MIDIPortRef](coremidi/midiportref.md)
- [MIDIReceiveBlock](coremidi/midireceiveblock.md)

### Endpoint management

- [MIDIEndpointDispose(_:)](coremidi/midiendpointdispose(_:).md)
- [MIDIEndpointGetEntity(_:_:)](coremidi/midiendpointgetentity(_:_:).md)
- [MIDIEndpointGetRefCons(_:_:_:)](coremidi/midiendpointgetrefcons(_:_:_:).md)
- [MIDIEndpointSetRefCons(_:_:_:)](coremidi/midiendpointsetrefcons(_:_:_:).md)
- [MIDISourceCreateWithProtocol(_:_:_:_:)](coremidi/midisourcecreatewithprotocol(_:_:_:_:).md)
- [MIDIGetSource(_:)](coremidi/midigetsource(_:).md)
- [MIDIGetNumberOfSources()](coremidi/midigetnumberofsources().md)
- [MIDIDestinationCreateWithProtocol(_:_:_:_:_:)](coremidi/mididestinationcreatewithprotocol(_:_:_:_:_:).md)
- [MIDIGetDestination(_:)](coremidi/midigetdestination(_:).md)
- [MIDIGetNumberOfDestinations()](coremidi/midigetnumberofdestinations().md)
- [MIDIEndpointRef](coremidi/midiendpointref.md)

### Event list management

- [MIDIEventListInit(_:_:)](coremidi/midieventlistinit(_:_:).md)
- [MIDIEventListAdd(_:_:_:_:_:_:)](coremidi/midieventlistadd(_:_:_:_:_:_:).md)
- [MIDIEventPacketNext(_:)](coremidi/midieventpacketnext(_:).md)
- [MIDISendEventList(_:_:_:)](coremidi/midisendeventlist(_:_:_:).md)
- [MIDIReceivedEventList(_:_:)](coremidi/midireceivedeventlist(_:_:).md)
- [MIDIEventList](coremidi/midieventlist.md)
- [MIDIEventPacket](coremidi/midieventpacket.md)
- [UnsafeMutableMIDIEventListPointer](coremidi/unsafemutablemidieventlistpointer.md)
- [UnsafeMutableMIDIEventPacketPointer](coremidi/unsafemutablemidieventpacketpointer.md)

### Packet list management

- [MIDIPacketNext(_:)](coremidi/midipacketnext(_:).md)
- [MIDIPacket](coremidi/midipacket.md)
- [MIDIPacketList](coremidi/midipacketlist.md)
- [MIDITimeStamp](coremidi/miditimestamp.md)
- [UnsafeMutableMIDIPacketListPointer](coremidi/unsafemutablemidipacketlistpointer.md)
- [UnsafeMutableMIDIPacketPointer](coremidi/unsafemutablemidipacketpointer.md)

### I/O management

- [MIDISysexSendRequest](coremidi/midisysexsendrequest.md)
- [MIDISysexSendRequestUMP](coremidi/midisysexsendrequestump.md)
- [MIDIFlushOutput(_:)](coremidi/midiflushoutput(_:).md)
- [MIDIRestart()](coremidi/midirestart().md)
- [MIDIIOErrorNotification](coremidi/midiioerrornotification.md)

### Errors

- [MIDI Services Errors](coremidi/midi-services-errors.md)

### Deprecated

- [Deprecated Symbols](coremidi/deprecated-symbols.md)

## See Also

### Services

- [MIDI System Setup](coremidi/midi-system-setup.md)
- [MIDI Bluetooth](coremidi/midi-bluetooth.md)
- [MIDI Messages](coremidi/midi-messages.md)
- [MIDI Thru Connection](coremidi/midi-thru-connection.md)
- [MIDI Networking](coremidi/midi-networking.md)
- [MIDI Drivers](coremidi/midi-drivers.md)
- [MIDI Capability Inquiry](coremidi/midi-capability-inquiry.md)
