Detecting an SD card insertion

There was a thread about detecting USB and SD Cards for Windows and Linux. It talked about essentially looking for new volumes that have mounted via a timer. Is there any other event driven way in OS X?

I have MBS Complete and it can detect USB insertion. I assumed an SD Card might “emulate” a USB device but it does not.

Suggestions??

CarbonApplicationEventsMBS class has an event for volume mounted. Try that. Works in Cocoa, too.

NSWorkspace notification center, listen for the message “NSWorkspaceDidMountNotification”.

As you already have the MBS plugins, check the documentation on how to use it via the plugins.

I played with the methods mentioned above.
The MBS method works the easiest. But how can I see whether a volume is an SD card?

I need to know if a card is a USB thumb drive, CompatcFlash card, SD card or Memorystick(Duo).
And even SxS media, or XQD media, or an XD-CAM disc, if that’s even possible.
I know on the OS-X desktop, the appropriate icon appears for each different type of media. So, somewhere it must be on the volume info.

That is a new question. Please make a new thread and add what OS you need.

Well… it is just very closely related. The title does say “Detecting an SD card insertion”. So, I thought checking the media type falls under the subject. But I will start a new threat :slight_smile:

EDIT : I just did added a new threat: detecting media-type of mounted volume