@hokiespurs : I have your script setup so it works now with a sync'd shot rate of 1.75 seconds per shot (on my A1200 - an elcheapo Powershot) ! And no special builds or changes to CHDK were needed.
Awesome!! Thanks for the script. I should have some free time tomorrow to give it a go, and will let you know how it does.
Only a one line change to the script required once the patch goes through so if it works for you now, it should work for you (with that change) in the future.
I just began an edit of "usb_sync.lua" (attached) in order to investigate the quickest method of 2 frame capture - with the possibility of varying the exposure of the first frame using "CloseMechaShutter".
Anyway, I was attempting to replace the script key presses with levents. These levents work fine in the normal chdkptp gui but not when used in the script.
I've locally edited the kbd.c file to enable usbremote/ptp, is there a particular reason why you mention "usb_force_active" in my circumstances?
I'm not clear why you are trying to do it this way, but it's almost certainly not a good idea. The mechanical shutter on these cameras is just used to block light while the sensor is being read out, and the timing you will get controlling it through script is going to be very uncertain. You can use the normal set_tv96_direct function to set the actual shutter time.
The general idea is, with controllable lighting (but different between the first capture and second) - how to minimize the capture time of 2 consecutive frames
"You can use the normal set_tv96_direct function to set the actual shutter time." - on 2 consecutive frames on the same cam?
(i'm actually trying to get away without overrides )
All of this seems very far from hokiespurs original question.
I'd split it into a new thread but I don't even know what the subject is.
Messing with the mecha shutter won't do this for you. The electronic exposure length (from the sensor being cleared to readout) is set in advance. If you manage to close the mecha shutter during the exposure, the camera will still do the same exposure, some fraction of it will just be blocked by the shutter.
Even if you could control the actual exposure, script timing is limited to ~10ms at best, which would be totally unsuitable for controlling exposure in normal lighting.
Yes, just set the shutter speed before each shot. You can use the raw shooting hook or the exposure counter to know when the first shot is finished.
Again, I don't understand. Even if it could work, what do you gain by using CloseMechaShutter rather than normal overrides?
--[[@title levent Sync--]] post_levent_to_ui('PressSwOne') repeat sleep(50) until get_shooting() == true
> luar post_levent_to_ui('PressSwOne')
lua f=1;loadfile(''A/CHDK/SCRIPTS/HDR.LUA")()
A wheel back on my wagon - thanks. I had this idea that when the shutter was half-pressed that av/tv/iso could not be adjusted - hence mecha shutter idea.
perhaps EXIF data says what it means.
results in "attempt to call a nil value"
f,err=loadfile('A/CHDK/SCRIPTS/usb_sync_levent.lua')if not f then error(err)endf()
--[[@title levent main]] f=loadfile('A/CHDK/SCRIPTS/LEV.LUA') if not f then print("loadfile failed.") else f() end
--[[@title levent halfpress--]] post_levent_to_ui('PressSwOne') repeat sleep(50) until get_shooting() == true
> .loadfile('A/CHDK/SCRIPTS/LEV.LUA')()
Started by Anaglyphic Hotwire! Hardware Mods, Accessories and Insights
Started by Blooper « 1 2 » Creative Uses of CHDK
Started by Alarik « 1 2 ... 12 13 » General Discussion and Assistance
Started by David Ripple « 1 2 ... 6 7 » General Discussion and Assistance
Started by colombo11 « 1 2 3 4 » General Discussion and Assistance