What will CHDK LUA get_tick_count() return after 24+ days?My thoughts:Return value should be 32 signed integerMost probably answer is just 2147483647 + 1 -> -2147483648But it could also cap at last integer second and wrap to 0 or some other stuffJust want to confirm this... without running camera for few weeks
If you had asked the question a month ago, then I could give you an answer. I stopped my camera after 23 days. get_tick_count () can be found in the third column (tick) in the logfile.May be next time
time_for_next_shot=get_tick_count() + some_valuewait until get_tick_count() >= time_for_next_shot
Just want to confirm this... without running camera for few weeks
One other thing to watch out for is that calculations can overflow before the actual wraparound time, likeCode: [Select]time_for_next_shot=get_tick_count() + some_valuewait until get_tick_count() >= time_for_next_shottime_for_next_shot becomes negative immediately, less than the still positive get_tick_count.
Quote from: reyalp on 02 / March / 2019, 18:24:05One other thing to watch out for is that calculations can overflow before the actual wraparound time, likeCode: [Select]time_for_next_shot=get_tick_count() + some_valuewait until get_tick_count() >= time_for_next_shottime_for_next_shot becomes negative immediately, less than the still positive get_tick_count.I could do the same think with os.time…Where is the advantage of this method over os.time?https://chdk.setepontos.com/index.php?topic=13675.0
Quote from: vincasr on 02 / March / 2019, 14:32:02Just want to confirm this... without running camera for few weeks Or yo=u could do like this script : Ultimate Intervalometer and automatically reboot the camera every couple of days.
What will CHDK LUA get_tick_count() return after 24+ days?
Yes, if you do another one of these it would definitely be good to know what happens.
I notice one problem. Cancel of retract timer does not work anymore. This can be seen in the focal length in the penultimate column which goes from around 50mm to 24mm.
Started by whim General Discussion and Assistance
Started by Artlav Script Writing
Started by SkyWalker9 « 1 2 ... 8 9 » Completed and Working Scripts
Started by c_joerg Script Writing
Started by Mlapse « 1 2 3 4 » General Help and Assistance on using CHDK stable releases