set_zoom question - Script Writing - CHDK Forum supplierdeeply

set_zoom question

  • 1 Replies
  • 3206 Views
set_zoom question
« on: 15 / December / 2009, 22:21:43 »
Advertisements
what would the set_zoom be for a Canon SX100 IS be to set the zoom to 10x or 60mm?

TIA,
Rick

*

Offline reyalp

  • ******
  • 14121
Re: set_zoom question
« Reply #1 on: 16 / December / 2009, 00:07:00 »
set_zoom takes a number in "zoom steps", which varies depending on the camera. Each camera can zoom in a discrete number of steps. This 5-10 most cameras, but up to 128 or so on some.

The number of steps available is obtained in script with
get_zoom_steps

The current position, in steps, is obtained with
get_zoom

In the CHDK menu, you can use OSD->Miscellaneious Values->Show zoom to display the current focal length, 35mm equivalent, or X. You can also get this information from exif of a picture taken at a given zoom. Note, this information may be wrong on some ports, because people like to copy/paste code without checking. If in doubt, verify that the limits match the canon specs.

Using this, you can either just count the number of times you have to click the zoom lever to reach the desired zoom, or (if your camera has a lot of steps) make a script that displays the value of get_zoom.

You can also get a list (in funny units) from the CHDK source code, in platform/<camera>/main.c fl_tbl
Don't forget what the H stands for.

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal