Ultimate Intervalometer - a script for shooting over a long duration - v4.9 - page 57 - Completed and Working Scripts - CHDK Forum

Ultimate Intervalometer - a script for shooting over a long duration - v4.9

  • 651 Replies
  • 218256 Views
Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #560 on: 14 / February / 2019, 09:06:14 »
Advertisements
however when i let UI restart the camera it seems to go just a little bit too quickly and thus the zoom is not set before the script starts.
Most of my scripts allow a user defined "start delay" but apparently not this one.  And what you really want is a "restart delay".

So here's an experiment to see if it works.  I'll update the script in a more general way if it does.  Assuming you are using release 4.8 of ultimate.lua, edit line 747 from
Code: [Select]
        printf("Autostarted.  Next reboot:%d days", reboot_counter )
        sleep(1000)
        start_delay = 0                             -- disable start delay if autostarted
to
Code: [Select]
        printf("Autostarted.  Next reboot:%d days", reboot_counter )
        sleep(5000)
        start_delay = 0                             -- disable start delay if autostarted

That will cause the script to pause 5 seconds when it restarts.  Does that fix the refocus problem?

Quote
would it be possible (and work) if the UI script was delayed in startup after a reboot?  and naturally, if it is, how would i create that delayed startup for UI (so probably in CHDK: for any script loaded)

It would be easy to add "Script Startup Delay"  and "Script Restart Delay" options to the CHDK Menu and CHDK script engine.  But that's a code and documentation change that would have to propagate through the revision process and would probably only be justified if the patch I gave you above does not achieve the same effect.

It's interesting that the CHDK Script menu has a menu choice called : Script Shoot Delay.  I can only assume that was added early in CHDK so that a script running on different cameras could be manually tuned for the delay needed after each shot to allow the image to be processed and stored to the SD card. I'm willing to bet nobody uses this menu choice and there are much better ways to achieve the same function within the script code.  However, there is a reluctance to remove anything historical from CHDK as it might break something someone is doing.
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline Mlapse

  • *****
  • 583
  • S95 S110
Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #561 on: 14 / February / 2019, 10:19:05 »
I tested it and this does not solve it.
but due to the longer delay i noticed that this is because when it restarts, it restarts in 'play' mode and for that reason the zoom won't come back on. That is normal behaviour if you don't go from shooting mode to shooting mode...it might already be in play mode when it is going for that 5sec reboot.

when i do not start with a long press on the on/off button it ends up in play mode as well (only with card locked method), cancelling the zoom setting. So it might be not a timing issue, but related to the fact that the camera starts up in play mode?
is that a must being in play mode around the reboot?

Quote
I'm willing to bet nobody uses this menu choice and there are much better ways to achieve the same function within the script code.  However, there is a reluctance to remove anything historical from CHDK as it might break something someone is doing.

i was one of those users, but after 1.3 some advanced settings of CHDK were broken, so i had to stop using them.
« Last Edit: 14 / February / 2019, 10:40:12 by Mlapse »
frustration is a key ingredient in progress

Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #562 on: 14 / February / 2019, 10:40:22 »
but due to the longer delay i noticed that this is because when it restarts, it restarts in 'play' mode and for that reason the zoom won't come back on.
That is normal behaviour if you first start up in play mode
when i do not start with a long press on the on/off button it ends up in play mode as well, cancelling the zoom setting. So it might be not a timing issue, but related to the fact that the camera has firmware update only available in play mode?
IIRC, the choice of starting the camera in Play mode on an autoboot was made a long time ago on the assumption that it was "safer" to do it that way. The issue is that the CHDK boot process can't tell which button started the boot (On/Off or Play) unless the On/Off button is held down during the boot.  So the decision was to always start in Play mode and not extend the lens in case the user was not expecting it.

I've never really understood that reasoning as without CHDK you can start your camera in shooting mode all day long with no concern about damage.  And 99% of people start the camera with the On/Off button in shooting mode every time.  Granted, CHDK always starting in shooting mode would mean you can no longer start the camera in playback mode (unless CHDK requires you to hold down the playback button during the boot  :haha )  Is that really a problem?

The code could be changed to allow starting in shooting mode, unless the Play button is held down, now that there is a use case for why it's needed.  The difficulty is that it would require editing the boot.c file for every camera firmware version - a big job that would be almost impossible to get fully tested in these days of declining interest in CHDK. And it would either be on or not, there is really no easy way to make it a user option.   I suppose we could provide two DISKBOOT.BIN files - one normal and one that boots into shooting mode but that's messy.

Having said that - you could do a personal custom build just for your application if it's that important to you.  The required code change is trivial.

Quote
i was one of those users, but after 1.3 some advanced settings of CHDK were broken, so i had to stop using them.
That's interesting - do you have a list of what stopped working?  I don't recall hearing about that but it has been quite a while since that update.
« Last Edit: 14 / February / 2019, 10:45:17 by waterwingz »
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline Mlapse

  • *****
  • 583
  • S95 S110
Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #563 on: 14 / February / 2019, 10:57:54 »
Important, i would rather solve the zoom setting in UI copy my camera's fixed settings, but yes......
I would like to make that code change with the risk that my camera desintegrates ;)
If you could provide that trivial change i'll give you the results.

and i'm sorry don't have lists of that sort of thing.
but from the top of my head the fixed iso parameter is the most annoying, it might have to do with the floating of exposure in rawopint i experienced, but haven't tested it properly.
it at least makes all pictures overexposed when in canon shooting mode and iso is set in CHDK at lower than iso400. (even when iso is synced with canon's setting)
-be aware, you might suffer from other unexpected sideeffects even after disabeling setting, set iso back to 0, check if it sticks after a reboot or erase and extract your build again to the sd card-

if you look at the display you'll see f.i. iso201 or iso101 instead of the set iso100 & iso200, it will also state those values in UI log.
« Last Edit: 14 / February / 2019, 11:43:30 by Mlapse »
frustration is a key ingredient in progress


Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #564 on: 14 / February / 2019, 13:50:42 »
Important, i would rather solve the zoom setting in UI copy my camera's fixed settings, but yes......
So if I understand the problem, calling the CHDK set_zoom( ) function in a script does not give exactly the same zoom position each time?  At least, not between restarts of the camera?   Line 297 in the script only allows 2 seconds after issuing that command before it does a half_press to force a refocus. I wonder it it needs to be a bit longer on some cameras?  Change it to sleep(5000)?

Quote
I would like to make that code change with the risk that my camera desintegrates ;)
If you could provide that trivial change i'll give you the results.
Let me know your camera model and firmware version and I'll post something.  Not much risk of disintegration.

Quote
and i'm sorry don't have lists of that sort of thing.
but from the top of my head the fixed iso parameter is the most annoying, it might have to do with the floating of exposure in rawopint i experienced, but haven't tested it properly.
it at least makes all pictures overexposed when in canon shooting mode and iso is set in CHDK at lower than iso400. (even when iso is synced with canon's setting)

-be aware, you might suffer from other unexpected sideeffects even after disabeling setting, set iso back to 0, check if it sticks after a reboot or erase and extract your build again to the sd card-

if you look at the display you'll see f.i. iso201 or iso101 instead of the set iso100 & iso200, it will also state those values in UI log.
Hmmm .. maybe @reyalp can comment.  However, I will point out that if you set any of the overrides in the CHDK menu, then you really need to set all of them!  The Canon firmware does not know that you are going to override one of the settings and so sets the other settings as if it still had full control.   If it wants to use tv=1/60 sec,  av=f2.8,  sv= ISO200 and you set just the CHDK override to ISO400 then the resulting picture will be taken with tv=1/60 sec, av=f2.8, sv=ISO400 and will be overexposed.  This has always been the case and did not change with release 1.3

As far as ISO100 vs ISO101 that sounds like Canon rounding to a set of discrete values and CHDK reporting the actual numeric value.
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline Mlapse

  • *****
  • 583
  • S95 S110
Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #565 on: 14 / February / 2019, 14:29:42 »
Quote
So if I understand the problem, calling the CHDK set_zoom( ) function in a script does not give exactly the same zoom position each time?  At least, not between restarts of the camera?   Line 297 in the script only allows 2 seconds after issuing that command before it does a half_press to force a refocus. I wonder it it needs to be a bit longer on some cameras?  Change it to sleep(5000)?

that is correct restart or newly started gives the same result, that is, slightly different than last try. on my s95-100k it is most obvious because i already was using the standard zoom settings.

It is a while back that i tested the zoom per percent. and it started for me because those 10% steps to set zoom sometimes showed serious barrel distortion compaired to the factory zoom values. and that's when i first spotted the small differences in zoom.
I thought something like 56%-64% is 11mm for the s95. the only difference in data of the picture is that 56%@11mm has f 3 or 3.2 while 64% has f 3.5.
the picture is at 64% just slightly more zoomed than at 56%
Sounds all logical to me, but why 60% isn't 60% the next time you start up is less logical.
I will try the sleep command tomorrow.

Quote
Hmmm .. maybe @reyalp can comment.  However, I will point out that if you set any of the overrides in the CHDK menu, then you really need to set all of them!  The Canon firmware does not know that you are going to override one of the settings and so sets the other settings as if it still had full control.   If it wants to use tv=1/60 sec,  av=f2.8,  sv= ISO200 and you set just the CHDK override to ISO400 then the resulting picture will be taken with tv=1/60 sec, av=f2.8, sv=ISO400 and will be overexposed.  This has always been the case and did not change with release 1.3
i always used the same iso settings. so sv=iso200 and chdk=iso200, still overexposed.
if sv=iso400 and chdk=iso400 you have no overexposure, only below iso400, then the screen also shows iso400
« Last Edit: 14 / February / 2019, 14:54:27 by Mlapse »
frustration is a key ingredient in progress

Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #566 on: 14 / February / 2019, 14:52:40 »
It is a while back that i tested the zoom per percent. and it started for me because those 10% steps to set zoom sometimes showed serious barrel distortion compaired to the factory zoom values. and that's how i first spotted the small differences in zoom.  I thought something like 56%-64% is 11mm for the s95. the only difference in data of the picture is that 56%@11mm has f 3 or 3.2 while 64% has f 3.5.
the picture is at 64% just slightly more zoomed than at 56%
I will try the sleep command tomorrow.
CHDK does not really set continuous zoom positions. Each Powershot has a set of discrete steps - from a little as 7 on cheaper cameras to over 200 on the super zooms.  So the script takes the % setting you specify and converts that to the closest zoom step #.   It should request the same step # (zoom position) every time once you specify the zoom % in the script.  And they should be the same discrete zoom positions the Canon firmware uses.   So this is a mystery.

Quote
i use the same iso settings. so sv=iso200 and chdk=iso200, still overexposed.
if sv=iso400 and chdk=iso400 you have no overexposure, only below iso400
Interesting.  I wonder if this a ISO "market value" vs "real" issue?  Seems to me the lower iso settings had the biggest diffference?
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline Mlapse

  • *****
  • 583
  • S95 S110
Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #567 on: 14 / February / 2019, 14:57:45 »
I really have no idea if lower values are more overexposed, nowadays I just set CHDK to NO OVERRIDES

canon only has 4 different fixed zoom settings in the s95, the percentages work from 20% onwards..if i use 1% steps i might have more than 60 different steps.
« Last Edit: 14 / February / 2019, 15:03:47 by Mlapse »
frustration is a key ingredient in progress


Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #568 on: 14 / February / 2019, 16:17:52 »
canon only has 4 different fixed zoom settings in the s95, the percentages work from 20% onwards..if i use 1% steps i might have more than 60 different steps.
I don't think it works that way.  The script looks up how many steps are available in the Canon firmware and converts the % value you request to the nearest step.

According to the S95 porting information,  CHDK for your camera has 10 different discrete zoom steps.
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline Mlapse

  • *****
  • 583
  • S95 S110
Re: Ultimate Intervalometer - a script for shooting over a long duration - v4.8
« Reply #569 on: 14 / February / 2019, 16:37:43 »
well in that case only the last 8 work and what i'm seeing is the result of calculations on tipping points?
frustration is a key ingredient in progress

 

Related Topics