View Single Post
Old 10-26-2007, 01:59 AM   #30
mrkai
Bit Wrangler
mrkai has a complete set of Star Wars action figures.mrkai has a complete set of Star Wars action figures.mrkai has a complete set of Star Wars action figures.mrkai has a complete set of Star Wars action figures.mrkai has a complete set of Star Wars action figures.
 
Posts: 181
Karma: 415
Join Date: Oct 2007
Device: Sony PRS-505
I think you are trying to solve the wrong(ish) problem here...

Quote:
Originally Posted by kovidgoyal View Post
...ioreg sounds like it might work, though having to run a commandline program just to find out what devices are attached to the system seems like a lot of unnecessary overhead. Maybe I'll just have to bite the bullet and look at IOKit.
...the polling that you are doing is *horrible* on OS X. looking at drives onlyhen the state changes is a *far* superior solution (on any os, really)..if if you are doing this via iokit or some other means to determine if the PRS 505 is connected.

Since with the 505 there is no need for direct manipulation of the data via a protocol (thank you Sony for Mass Storage support!) it would be a far better *user experience* to not constantly scan for what you are looking for and let the os tell you its a good time to work.

While this might not be the more...geeky"MIT" way of solving the "
mrkai is offline   Reply With Quote