uBASIC docs editing - Script Writing - CHDK Forum supplierdeeply

uBASIC docs editing

  • 1 Replies
  • 2235 Views
uBASIC docs editing
« on: 05 / June / 2012, 02:30:22 »
Advertisements
I'm tempted to make some changes to the uBASIC documentation, but I have experience with only one camera and am a raw newbie at CHDK.  I'd hate to correct something, only to be yelled at for messing up docs that work for everyone else.

Here's my biggest beef:
set_tv96         vs.          get_tv96
and all the other, similar commands.
All the docs I've found say that to set the shutter speed to a value of n Tv96 units, write:
set_tv96 n
That works.  The docs also say that to fetch the camera's current shutter speed value, you use the same syntax:
get_tv96 n
will put the Tv96 shutter speed value in variable n.  It never worked that way in the script I was writing when I stumbled over this.  I had to change it to:
n = get_tv96
That did exactly what the docs said the other syntax would do.  As far as the documentation I could find is concerned, get_tv96 n is the standard method, and n = get_tv96 is just a renegade way of bypassing the standard method.

Am I the only one who has has this problem?  Do get_tv96 n and get_focus n and get_dof n work for everybody else?  If everybody else has the same problem, I'm more-or-less ready to edit some docs.  I'm just wary of "correcting" something that worked fine for everybody but me.

Eric

S3 IS with LensMate filter/hood adapter

Re: uBASIC docs editing
« Reply #1 on: 05 / June / 2012, 08:34:35 »
I'm tempted to make some changes to the uBASIC documentation, but I have experience with only one camera and am a raw newbie at CHDK.  I'd hate to correct something, only to be yelled at for messing up docs that work for everyone else.
Always a risk that someone will say something that appears to be harsh.  But its really easy to roll-back wiki  changes if someone makes a mistake.  A few of us keep an eye on them daily so I'd say that if you have the time, interest and care enough to fix things you are sure are broken - go ahead please !

Quote
Here's my biggest beef:
set_tv96         vs.          get_tv96
and all the other, similar commands.
All the docs I've found say that to set the shutter speed to a value of n Tv96 units, write:
set_tv96 n
That works.  The docs also say that to fetch the camera's current shutter speed value, you use the same syntax:
get_tv96 n
will put the Tv96 shutter speed value in variable n.  It never worked that way in the script I was writing when I stumbled over this.  I had to change it to:
n = get_tv96
That did exactly what the docs said the other syntax would do.  As far as the documentation I could find is concerned, get_tv96 n is the standard method, and n = get_tv96 is just a renegade way of bypassing the standard method.

Am I the only one who has has this problem?  Do get_tv96 n and get_focus n and get_dof n work for everybody else?  If everybody else has the same problem, I'm more-or-less ready to edit some docs.  I'm just wary of "correcting" something that worked fine for everybody but me.
The old original implementation of uBASIC was "get_tv96 n" but that was changed to add "n=get_tv96" years ago.  I would never use the former format so I can't say if it still works or not.  Changing it to "n=get_tv96" where-ever you find it will do no harm and cleans things up. Go ahead ?

Reyalp  can probably weigh in on whether the old way should still work.
Ported :   A1200    SD940   G10    Powershot N    G16

 

Related Topics