Mailing Lists: Apple Mailing Lists

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

Looking for an example program / objective-C foundation tool which maintains a run loop & monitors USB.



This is a cross post from the Cocoa list, hoping someone here has done something like this in the past.

-----

I need to write an objective-C foundation tool which does not terminated except when instructed to. Additionally it needs to continue to respond to additional input as it is called from another application and monitor for changes on the USB bus.

What I want it to do is:

When First launched:
-> create a list of objective-C objects based on attached custom USB hardware
-> perform a function based on the command line argument
-> return result
-> wait for next call & idle

When idling:
-> monitor the USB bus in order to add / delete objects from our list based on insertion / deletion of our custom USB hardware
-> terminate if none of our custom USB hardware exists
-> otherwise wait for next call & idle

On Subsequent call
-> perform a function based on the command line argument
-> return result
-> wait for next call & idle

Currently I have all this running in a Cocoa app, however they now want to be able to call it from the UNIX command line.

Can anyone direct me to an example program which maintains a run loop (extra points if it monitors for USB insertions / deletions)?

-----

George Lawrence Storm
Macintosh Applications Development
Edmonds (Seattle), Washington
E-mail: <email@hidden>


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Usb mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/usb/email@hidden

This email sent to 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.