Question

I need to find photos on external devices like cameras and mobiles connected as USB pendrive. As I don't want to traverse all disks, I thought of looking for specific folders under root or deeper, e.g. DCIM for cameras and start traverse from there.

For cameras the directory structure is specified in the Design rule for Camera File system (DCF) as always using a DCIM directory at root.

But for different mobile brands I did not find any rules. So can you please help me out and post the directory where your photos are stored in when you're mobile is connected as USB pendrive along with yout mobiles brand?

I'm looking for all major brands, like Nokia, LG, Samsung, Sony Erricson, etc. (IPhone connects as camera under 'camera and scanners', so I need to TWAIN it, but that works...)

Thanks a lot!

Was it helpful?

Solution

Lots of ways to get to the images.

Device specific - Needs lots of hardware to test with. An easily unpalatable app could handle getting new devices supported.

  1. Check for known vendor/device id's on USB bus with related info on how to get to data. Some may have proprietary methods for extracting images.

Drive based photos - traverse entire drive makes it future proof, however speed is bad.

  1. For each removable drive in system.
  2. Check for existence of "known" base folders
    • If found, traverse from base folder
    • Else, traverse entire drive

TWAIN based photos - not a clue with these

  1. Lookup iphone, would this be for capturing new photos, or actually viewing previously captured photos

OTHER TIPS

My Blackberry Curve stores images on the SD card in X:\BlackBerry\pictures by default.

My Samsung Omnia gives me the default

DCIM

directory on the root of the assigned drive.

Note that I have to specifically enable USB file transfer on the phone, otherwise all files need to come through the Windows Mobile Device folder.

I know this is a hack but you could try something like this and then record (in a DB) the make/model/handset stats in for future.

in Linux (on the command line) (This is an example)

ls /*/*.jpg

This would look under the first level of directories for any file with a .jpg extension.

ls /*/*/*.jpg

For the second directory

Again this is just a hack and really not advised for production, but for testing to get a working path for a device this might come in handy.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top