digital camera

karlp at ourldsfamily.com karlp at ourldsfamily.com
Mon Jul 24 04:14:15 UTC 2006


On Thu, 20 Jul 2006, Rick Stevens wrote:

>On Thu, 2006-07-20 at 08:37 -0500, Fred Grant wrote:
>> On Wed, 2006-07-19 at 19:27, Rick Stevens wrote:
>> > On Wed, 2006-07-19 at 18:05 -0500, Fred Grant wrote:
>> > > Recently acquired an el cheapo digital camera made by dgx.  When I go to
>> > > mass storage mode via usb the hardware browser indicates the presence of
>> > > /dev/sda1.
>> > > 
>> > > Do any of you have any pointers for viewing images?  I assume I'll have
>> > > to mount /dev/sda1 but I don't know what type of file system it is or
>> > > how or where to mount it.  Otherwise this should be a piece of cake!
>> > 
>> > 99% of all cameras use FAT-32 or VFAT filesystems.  Have you tried
>> > gphoto (Gnome) or kamera (KDE) to see if they "grok" your camera?
>> > 
>> > If not, you probably want to create a mountpoint for your camera's
>> > storage (e.g. "/media/camera") once.  Then, an appropriate mount command
>> > would be
>> > 	
>> > 	mount -t vfat /dev/sda1 /media/camera
>> > 
>> > Then you'll see the directory structure under /media/camera.  One of
>> > the more common would be:
>> > 
>> > 	/media/camera/dcim/olympus/file.jpg
>> > 
>> > That's from an old Olympus 3050Z camera I have.  Usually, there will
>> > be a "dcim" directory, and under that some permutation of your camera's
>> > maker.  The "*.jpg" files are the actual images.
>> > 
>> Thanks Rick.  I got it to work with /mnt/pics.  How about a script to
>> automate the mount command?  I've never written a script before so I
>> don't know how or where to save it so I can find it again and use it as
>> needed.
>
>Uh, hmmm.  Well, as root, create the file "/usr/bin/mntcam".  In it, put
>these lines:
>
>    #!/bin/bash
>    if [ $0 = "mntcam" ]; then
>	mount -t vfat /dev/sda1 /mnt/pics
>	echo "Camera mounted at /mnt/pics"
>    else
>	umount /mnt/pics
>	echo "It is now safe to unplug the camera"
>    fi
>
>Save it.  Then (still as root), enter these two commands:
>
>    # chmod 755 /usr/bin/mntcam
>    # ln -s /usr/bin/mntcam /usr/bin/umntcam
>
>You now have two commands "mntcam" to mount it, and "umntcam" to unmount
>it.


Nice script Rick. One other suggestion I would make is create a bin 
directory in your home directory, then put scripts you write there. Then 
the link command would be:

ln -s /home/yourname/bin/mntcam /usr/bin
&
ln -s /home/yourname/bin/mntcam /usr/bin/umntcam

This gives you the option of just backing up your home bin dir for moving 
and modifying your scripts.

One nice tool for writing scripts is vim, or you can venture into 
KDevelop, which also does syntax hilighting.

My 2 bits.

Karl (from a hotel room in Idaho the night before a funeral on my wife's 
side of the family).

>
>----------------------------------------------------------------------
>- Rick Stevens, Senior Systems Engineer     rstevens at vitalstream.com -
>- VitalStream, Inc.                       http://www.vitalstream.com -
>-                                                                    -
>-                He who laughs last thinks slowest.                  -
>----------------------------------------------------------------------
>
>_______________________________________________
>Redhat-install-list mailing list
>Redhat-install-list at redhat.com
>https://www.redhat.com/mailman/listinfo/redhat-install-list
>To Unsubscribe Go To ABOVE URL or send a message to:
>redhat-install-list-request at redhat.com
>Subject: unsubscribe
>

-- 
klp

     _/  _/      _/      _/_/_/       ____________   __o
    _/ _/       _/      _/    _/     ____________  _-\<._
   _/_/        _/      _/_/_/                     (_)/ (_)
  _/ _/       _/      _/           ......................
 _/   _/ arl _/_/_/  _/ earson    KarlP at ourldsfamily.com
--
Senior Consulting Sys/DB Analyst
http://consulting.ourldsfamily.com
--
 My Thoughts on Terrorism In America:
 http://www.ourldsfamily.com/wtc.shtml
--
 A right is not what someone gives you; it's what no one can take from you.
 -Ramsey Clark
--





More information about the Redhat-install-list mailing list