Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Device addition and removal notification



I am posting this question to both the USB and firewire lists:



How can a Mac OS X application be notified when a new audio / video device
has been added to or removed from the system?  Which API should I be looking
into?


All of these functions are defined in <file:///System/Library/Frameworks/IOKit.framework/Headers/IOKitLib.h>


Adding: Look for IOServiceAddMatchingNotification to get notified when a new device appears.

Removal: Use IOServiceAddInterestNotification to get notified of a device removal.

If you'd like the example, look at:

<file:///Developer/Examples/IOKit/usb/Another%20USB%20Notification%20Example/USBNotificationExample.c>


Yes, it's everything on your disk :-)

Cheers,

  Tomas
--
Ing. Tomas Zahradnicky, Jr.
Production Manager, 24U Software
Associate Member, Filemaker Solutions Alliance
mailto:email@hidden
http://www.24uSoftware.com
_______________________________________________
usb mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/usb
Do not post admin requests to the list. They will be ignored.

References: 
 >Device addition and removal notification (From: "Don Jordan" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.