• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Blocked in MIDIClientCreate
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Blocked in MIDIClientCreate


  • Subject: Re: Blocked in MIDIClientCreate
  • From: Doug Wyatt <email@hidden>
  • Date: Mon, 12 Dec 2005 14:41:10 -0800

On Dec 12, 2005, at 7:53, philippe wicker wrote:
Hi all,

I'm having a problem with a MIDI app running on Mac OS X (10.4.2) when this app is killed ("terminated" within the debugger). This app communicates with a 2.0 USB Audio/MIDI device (under development as is the MIDI app).

When the application is killed and relaunched, It stays blocked in the call to MIDIClientCreate. The stack displayed in the debugger window shows that it is waiting for a reply in the call to FindOrLaunchServer. I can see using "top" that the MIDIServer is running at that time. The only way I've found to revert to a working situation is to unplug and replug the device.

I suspected first that the problem was a consequence of MIDIClientDispose not being called when the app is killed but I think that CoreMidi does clean up the client "connection" resources when it "unexpectedly" exits. Am I right assuming this?

yes

I did some tests using 2 MIDI devices available in the market. The 1st one uses a vendor driver, the 2nd one relies on the generic USB MIDI driver. I couldn't reproduce the blocking behavior with these devices. So I'd tend to think that there's something wrong with my device but I've no idea where to look at :(

What's happening when a MIDI client is killed with regard to the actual device (e.g. any USB requests sent to it)?
What's happening when MIDIClientCreate is called with regard to the actual device (e.g. any USB requests sent to it)?
What could cause the call to FindOrLaunchServer to be blocking?
Any idea?

Check your console log to see if there's a more specific error, but it looks like MIDIServer is running but it is not responding to the Mach messages from the client. The client-side framework will wait up to 30 seconds before timing out and returning an error.


So the question is, why is the MIDIServer hanging? It would appear that your driver has something to do with that... let me know if you have more questions.

--
Doug Wyatt
Core Audio, Apple

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Blocked in MIDIClientCreate
      • From: philippe wicker <email@hidden>
References: 
 >Blocked in MIDIClientCreate (From: philippe wicker <email@hidden>)

  • Prev by Date: Re: Error in AudioUnitRender()
  • Next by Date: Re: AUSoundFilePlayer: Changing Loop Points on the Fly
  • Previous by thread: Blocked in MIDIClientCreate
  • Next by thread: Re: Blocked in MIDIClientCreate
  • Index(es):
    • Date
    • Thread