photopc



       photopc  -  utility  to  control  digital cameras based on
       Sierra Imaging firmware


SYNOPSIS

       photopc [-h] [-V] [-v[v]] [-q] [-z] [-t]  [-f  timeformat]
       [-s <speed>] [-l <device>] [command [params] ] ...


DESCRIPTION

       This  is  a  command line tool to manipulate digital still
       cameras that use certain  control  protocol,  namely  Agfa
       ePhoto  line,  Epson  PhotoPC  line,  Olympus D-xxxL line,
       Sanyo and Nikon (at least CoolPix 900)  cameras.   It  can
       set camera parameters, download and erase pictures, e.t.c.
       It was originally developed for Epson PhotoPC 500, now the
       author  uses  it  with  Olympus D-600L, results with other
       models may vary.


OPTIONS

       -h   This option produces a help screen of all options and
            commands.

       -V   This option prints software revision information.

       -v   This  option  enables  verbose  output.  Using two -v
            options increases the level  of  verbosity.  This  is
            primarily meant for debugging.

       -q   This option sets quite mode.  If it is not specified,
            the program will show running download progress indi-
            cator.

       -z   This  option  sets no time-zone processing mode.  Use
            this option if the camera's clock is (should be)  set
            up shifted by the local timezone offset.

       -s speed
            This  option allows setting the data rate to use when
            communicating with the camera.  Valid rates are 9600,
            19200, 38400, 57600 and 115200 (the default).

       -t   Set timestamp of generated files to the time of snap-
            shot.

       -f timeformat
            This option allows to specify the format for automat-
            ically  generated image file names; the value is used
            as the format string for  strftime(3)  function.   By
            default,  names of the format "MMDD_NNN.jpg" are gen-
            erated, where MM is a month, DD is a day, and NNN  is
            a count starting from 001.  A good starting point for
            the       timeformat       value       could       be
            "%Y_%m_%d-%H_%M_%S.jpg".   If  the format string con-
            tains context "%%XXXd" where XXX are  digits,  it  is
            taken  for the count, i.e. if the file with such name
            is present, next  count  is  tried.   If  the  format
            string  does  not  contain  "%%XXXd"  part, the count
            field, if necessary, is appended at the  end  of  the
            name.

            A few single-character formats are used as shortcuts.
            "x" makes the name of seconds since the epoch in hex-
            adecimal  format  (8  characters + ".jpg"), "d" - the
            same in decimal format (10  characters),  "1"  stands
            for  default  format "%m%d_%%03d.jpg", "2" stands for
            "%y%m%d%%02d.jpg",       "3"        stands        for
            "%Y_%m_%d-%H_%M_%S.jpg"     and    4    stands    for
            "%Y/%m/%d/%H_%M_%S.jpg".   The  program  attempts  to
            create  intermediate  directories  is  necessary (and
            possible).

       -l device
            This allows specifying the serial device to  use  for
            communicating   with   the  camera.  The  default  is
            /dev/photopc (which is typically created as  a  (sym-
            bolic)  link  to the real device, e.g. /dev/ttyS0) in
            UNIX, and COM1: in DOS and Windows.


COMMANDS

       After the options, one or more commands can  be  given  on
       the command line.

       Some  commands  accept  frame-list  as a parameter.  Frame
       list is a comma-separated list of  tokens  (no  whitespace
       allowed),  each of the tokens being a word all , or a sin-
       gle number, or two numbers separated by a dash (-),  or  a
       number followed by a dash and a word last (without whites-
       pace).

       query
            Display all current camera settings.

       count

       list List  information  about frames stored in the camera.
            Fields displayed are: frame  number,  size  of  image
            file,  protection  state,  resolution mode and times-
            tamp.  Faster than llist but may not work  with  some
            (older) models.

       llist
            List more information about frames stored in the cam-
            era.  Fields displayed are: frame number,  protection
            state,  size  of  image file, resolution mode, flash,
            shutter and timestamp.  Slower than list and does not
            work with models that use Exif file format.

       protect <frame-list> On | Off
            Change  "protected" status of frames. Frame numbering
            starts at 1. The command will fail if the frame  num-
            ber  is  omitted, not numeric, or does not correspond
            to a stored  frame.   "Protected"  frames  cannot  be
            erased  with  "erase" and "eraseall" commands or with
            the "erase" button on the camera.

       erase <frame-list>
            Erase frames. Frame numbering starts at 1.  The  com-
            mand  will  fail  if the frame number is omitted, not
            numeric, or does not correspond to a stored frame.

            WARNING!   note  that  erasing  list  may  not   give
            expected  result.   As  frames are erased, subsequent
            frames change their numbers.  For example, if you had
            three  frames, and run "erase 1-2", you will have one
            frame left that was originally frame  no.  2,  frames
            no.  1  and  3  will  be deleted.  To be sure, always
            specify  frames  in  descending  order,  e.g   "erase
            5,2-1".

       eraseall
            Erase all stored frames.

       snapshot
            Take a picture.

       off  Switch  off  the  camera.  This command only has this
            effect on some models (notably Olympus  D-600L).   On
            other  models,  it just terminate the session immedi-
            timeout, such as Photopc  600,  it  may  be  wise  to
            always  issue  "off"  at  the  end of command row, to
            decrease power consumption.

            All commands going after "off" are ignored.

       image <frame-list> <file-or-dir-name>
            Download an image or series of images from the camera
            to  disk file(s) on the host computer.  Frame number-
            ing starts at 1. The command will fail if  the  frame
            number  is  omitted,  not numeric, or does not corre-
            spond to a stored frame.  Files are  stored  in  JPEG
            (JFIF  or  Exif)  format.  Image file also contains a
            thumbnail portion, and set  of  parameters  like  the
            shutter  speed,  date and time, I.D. string and more.
            Directory  must  be  specified  if  frame   list   is
            requested.   If  directory  name  is specified, down-
            loaded file(s) will get unique  names  starting  with
            month and date of snapshot, unless -f option is used,
            in which case unique names are created  according  to
            the format specified.

       thumbnail <frame-list> <file-or-dir-name>
            Download  a  thumbnail  image or series of thumbnails
            from the camera to disk file(s) on the host computer.
            Frame numbering starts at 1. The command will fail if
            the frame number is omitted, not numeric, or does not
            correspond  to  a  stored  frame. Files are stored in
            JPEG (JFIF or Exif) format.  If the camera  does  not
            keep  files  in  EXIF format, then the thumbnail file
            also contains a set of parameters  like  the  shutter
            speed,  date and time, I.D.  string and more.  Direc-
            tory must be specified if frame  list  is  requested.
            If  directory  name  is specified, downloaded file(s)
            will get unique names starting with month and date of
            snapshot, unless -f option is used.

       audio <frame-list> <file-or-dir-name>
            Download an audio notice file or series of files from
            the camera to disk  file(s)  on  the  host  computer.
            Frame numbering starts at 1. The command will fail if
            the frame number is omitted, not numeric, or does not
            correspond  to  a stored frame. Files are stored with
            ".wav" extention but the format is not RIFF WAV  for-
            mat.   It  is  compressed  in some way, probably some
            variation of ADPCM.  The program stores the raw  data
            as  provided  by  the camera, it is not playable as a
            normal .wav file.  Directory  must  be  specified  if
            frame list is requested.  If directory name is speci-
            option is used.

       preview <file-name>
            take a `preview' snapshot and save image as a  <file-
            name>.   File  is  in JPEG (JFIF or Exif) format, and
            does not contain  any  additional  data,  just  plain
            (very low resolution) image.

       upload <file-name>
            Upload  image  file into the camera.  This command is
            not enabled in LOWMEMORY version (i.e. under MS/DOS).

            WARNING!   You  cannot  upload  arbitrary  JPEG file.
            Depending on  the  camera  model,  such  attempt  may
            result  in  the  image not uploaded, not viewable, or
            even the camera "hung" needing to remove the  batter-
            ies  to  make  it  work again.  File previously down-
            loaded from the same camera model is  always  upload-
            able.  Otherwise, your milage may vary.  photopc pro-
            gram does not perform any checks, so it's up  to  the
            user to provide the file in proper format.

       resolution Hi | Lo | Ext | <number>
            Set  the  camera  to high, low or extended resolution
            mode.  Exact meaning of the modes is  model-dependant
            and  may  specify  different  image dimensions and/or
            JPEG compression rate.

       clock
            Set the camera's internal real-time clock  using  the
            current  date  and time from the host computer.  Time
            of taking a snapshot  is  included  inside  the  JPEG
            files  produced.   Note that the models which display
            the time on the LCD will then display GMT rather than
            local  time.   With  -z  option,  time shifted by the
            timezone offset is set,  and  the  LCD  will  display
            local time.  Using unshifted (GMT) time in the camera
            seems a proper way to go.

       shutter <speed>
            Set the camera shutter speed.  Units can be specified
            in  microseconds or in traditional form like "1/250".
            Valid interval depends on the model.  If a value out-
            side  the  interval is specified, the camera will set
            the speed to the nearest margin of the  valid  inter-
            val.   Special  speed  value  auto will set automatic
            shutter.  Note that this only works while the  camera
            always set automatically.  Also note that there is no
            known way to control  the  aperture  value  from  the
            host.

       flash Auto | Force | Off | AntiRedeye | SlowSync
            Set the camera flash mode.

       id <string>
            Set  the  camera  identifier  string that is included
            inside the JPEG files produced.  Only few models sup-
            port this.

       autoshut-host <seconds>
            Automatically  shut  off  the  camera after that many
            seconds of inactivity while connected to the computer
            (on the host).

       autoshut-field <seconds>
            Automatically  shut  off  the  camera after that many
            seconds of inactivity  while  disconnected  from  the
            computer (in the field).

       lcd-autoshut <seconds>
            Automatically  shut  off  the  LCD monitor after that
            many seconds of inactivity.

       lcd-brightness <value>
            Set LCD brightness to the value (valid values  are  1
            to 7).

       macro On | Off
            Set  the  lens  macro mode.  As far as I can tell, on
            fixed focus models macro  only  means  force  minimum
            aperture,  not  change  the  focal  length.  Only has
            effect in the same invocation  with  "snapshot"  com-
            mand.

       color On | Off
            Set color or B/W mode.

       dzoom On | Off
            Set digital zoom on or off.  Note that low resolution
            must be set prior to turning on digital  zoom.   Only


EXAMPLES

       % photopc query

       % photopc -f "image%H:%M:%S" eraseall snapshot image 1 .


OTHER NOTES

       The  latest  version  of  this  tool  can  be   found   at
       ftp://ftp.average.org/pub/photopc/;  see  also WWW page at
       http://www.average.org/digicam/.

       Trademarks are properties of their respective owners.


KNOWN BUGS

       On some models, powersaving timeouts are measured  not  in
       seconds  but  in 1/10 sec units.  The program reports them
       as in seconds.

       Llist command relies on the format of thumbnail image that
       does  not  contain  necessary  information  on some models
       (e.g. Nikon CP 900), this command does not work for  these
       models.   List  command,  on  the contrary, do not display
       useful data on models that do not return it in the  regis-
       ter 47 (e.g. Agfa 780).

       The  program is known to have some timing problems talking
       to Nikon CP900 when the camera is "napping" in powersaving
       mode.  Until the problem is solved, a workaround is to run
       the program this way:

       $ photopc && photopc <command list>


COPYRIGHT

       The  program  is  copyrighted   by   Eugene   G.   Crosser
       <crosser@average.org>   and   freely  distributable.   See
       README file for detailes.  DOS and Windows  support  copy-
       right Bruce D. Lightner <lightner@lightner.net>


CREDITS

       The  man  page  was  originally  written  by  Jeff Tranter
       <jeff_tranter@pobox.com>, who also contributed a few  bug-
       fixes.    Some   information  about  the  serial  protocol
       obtained  from  Jun-ichiro  "itojun"   Itoh   <itojun@ito-
       jun.org>, Thierry Bousch <bousch%linotte.uucp@topo.math.u-
       psud.fr> and other contributors.

       epinfo(1), strftime(3), protocol description (protocol.htm
       in the source distribution).


Man(1) output converted with man2html