Hello,
ixus160-elph160, CHDK build 1.4.0 rev 4286, chdkptp rev 676. Basic rig is a tiny PC, plus an Aruino driving various cameras. Doing intervalometry and weather data acquisition/processing.
Ixus160 is modified: power on-off switch shorted together, external power by way of 12v 55AH AGM battery (from a wheelchair/electric scooter) - all hardware mods Working fine. Thanks to this post
Here's post in another thread that might be of interest : Auto on-off management
Note the little gold pin sockets - shorting those fires the shutter.
and the referred post re: Auto on-off management
were quite helpful to me, thanks waterwingz.
I was looking now to gracefully retract the lens before cutting power to camera when chdkptp tasks are complete. Started here;
http://chdk.setepontos.com/index.php?topic=2751.msg25770#msg25770Discovered function named "shut_down" - but it's an old post.. Casual grep thru scripts provided with 1.4.0 rev 4286 did not reveal a function named shut_down,
But in looking at source code from Ultimate,
http://chdk.wikia.com/wiki/Ultimate_Intervalometer , I found reference where we reboot() and post_levent_to_ui('PressPowerButton')
I run un-ashamedly stolen* lua snips from within a chdkptp session to the cam. This code works perfectly.
con> =status,msg=post_levent_to_ui('PressPowerButton') sleep(10000) if msg then print(msg) end
Lens retracts. Cam power remains on, LCD remains on (because I have not yet cut power.) I cut power. It goes off. All fine. My chdkptp session dutifully reports ERROR: I/O error
My lua understanding improves. I/O Error is due to cam "turning off" (thinking it is turning off) before the lua I started in chdkptp can gracefully complete..
The '=' means run at cam, the '.' means despool lua action to cam and return immediately, I think.
con3> .status,msg=post_levent_to_ui('PressPowerButton') sleep(10000) if msg then print(msg) end
con4>
No error! :-D
Will report on power consumption if interesting to anyone. Thanks to reyalp, waterwingz, and all who develop CHDK and related tools.
*<ahem - "
borrowed & adapted" - from stuff reyalp and waterwingz wrote>