With everything going on this week, I'm thinking this may have been overlooked :
I've always thought that it would be nice if CHDK actually used the values in each camera's shooting.c file for aperature_size_table[ ] , shutter_speeds_table[ ], and iso_table[ ] for something more useful.
One obvious thought would be to use the data there as the values available for custom Tv, Sv, and Av input fields in script parameters.
In theory, these tables are tuned to the actual values each camera can use so that's even more powerful. (Ignoring the possibility that many of them might have been C&P'd from other cameras).
While updating one of my scripts today, I once again realized that user specified @param values (for Av in particular) allowed choices that the camera does not actually support. And we have all the necessary information in each camera's shooting.c file to fix that.
There is probably a limit on how many specialized @param / #name things you might want to add but exposure values for a camera scripting system seem like they might be inside of that limit.
I guess I'll prototype something myself and see how it goes.
I initially thought using 'aperture_sizes_table', and 'shutter_speeds_table' from shooting.c to generate the '@values' list for a parameter would be pretty easy.
I started to do this then realised it gets complicated by the 'extended' ranges allowed in the menu overrides.
Aperture is extended by 2 stops beyond the smallest value (except for G1X where it is turned off).
Shutter speed is extended from very long to very short values.
So the question is should an Av or Tv parameter type be limited to the Canon values from shooting.c or the extended values from the override menu?
There is also at least one camera where the aperture table in shooting.c includes ND filter simulated values.
The next area that makes it more complicated is what values do you provide to the script via the parameter.
To be useful the script would probably need both the av96/tv96 value plus the string label for each entry - this is a bit more complicated than what I did for the 'table' options, haven't quite worked out the details yet.
Lastly - how do you specify the default value for the parameter in the script header (especially for Av)? The list of options available will be set at runtime on each camera, for example aperture[0] on the G12 is 2.8; but on the S100 it is 2.0.
So the default parameter value could select a different Tv or Av value. Unless we make it even more complex and set the default value in av96/tv96 units, then map it to the closest available entry when the script header is parsed.
Phil.