On 12 Jun 2008, at 23:01, David Duncan wrote:

On Jun 12, 2008, at 10:38 PM, Omar Qazi wrote:

I have a Cocoa application that controls an external USB device. I want to be able to turn the device off when the user performs some action, like click a button. Is there a way in Cocoa or IOKit to disable power to a USB Socket? The application runs on Leopard.


Are you really sure you want to turn off the USB socket itself? It would seem to me that you really want to use a device that has software control over its power state instead and that you would just send the proper message to turn it on or off rather than turning off the USB socket. That said, I have no idea if what you are asking is possible...

In particular, consider the scenario of the device plugged into a USB hub. If you turn off the computer's USB port, any other devices on the hub are screwed. Furthermore, the hub may well provide its own power connection, regardless of the computer, and almost certainly has no electronics to disable power that you can communicate with anyway.

Mike.

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to