How can my MIDI driver seize control of my USB device from AppleMIDIUSBDriver.plugin?

I am developing my own MIDI driver for macOS based on SampleUSBMIDIDriver.


When I open the Audio MIDI Setup and then connect my USB MIDI device to my Mac, my MIDI driver loads properly.


However, when I connect my USB MIDI device to my Mac and then open Audio MIDI Setup, my MIDI driver fails at IOUSBDeviceInterface::USBDeviceOpen().


This is because AppleMIDIUSBDriver.plugin has already opened the device.


Can my MIDI driver seize control of my USB device from AppleMIDIUSBDriver.plugin?


Thank you.