FWIW, you could do the second one with the shutter script hook and polling USB from script, but it would introduce several tens of ms variability.
I'm not completely sure of the best way to do this with the standard "pushbutton" USB remote circuit we use. Here are some options :
Thanks, can you explain why this would introduce what the 10s of ms of variability would be from? Would that be variability in the dt between frames or in the sync between cameras?
From a user standpoint it seems like any of those options would work, but I dont know enough about the development to help suggest which would be easiest to implement.
Polling the same signal from a script can result in a longer delay before that transition is recognized due mostly to the script "yielding" periodically between instruction executions.
Sorry - just rechecked the USB remote source as something was bothering me. Sure enough, this is not going to work the way I had hoped as the sync function is not enabled when shots are taken via a script (or the shutter button).
// Process a button press action from the stackstatic int action_stack_AS_PRESS(){ extern int usb_sync_wait; long skey = action_pop_func(1); // Key parameter returned if ((skey == KEY_SHOOT_FULL) && conf.remote_enable && conf.synch_enable) usb_sync_wait = 1; kbd_key_press(skey); return 1;}
In non-sync situations, "one press" does a shutter half-press on 0->5 and shutter full-press on 5-0. Thus, in sync mode, there is nowhere to put the half-press and it is sacrificed to allow the two necessary action for sync.
I was under the impression that no focus/exposure ops would be attempted with this setup . Does the outcome meake sense or is it likely a bug?
--[[@title USB Sync @chdk_version 1.3 @param l LED? @default l 1 @range l 0 7--]]function restore() set_config_value(cnf.remote_enable,0) -- disable USB remote set_config_value(cnf.synch_enable, 0) -- disable syncend-- setup AF_led = l cnf=require("gen/cnf_core") set_console_layout(10, 0, 40, 14) print("USB Sync test started...") set_config_value(cnf.remote_enable,1) -- enable USB remote set_config_value(cnf.synch_enable, 1) -- enable sync-- switch to shooting mode if ( get_mode() == false ) then set_record(1) while ( get_mode() == false ) do sleep(100) end end-- set focus & exposure and lock them in press("shoot_half") repeat sleep(50) until get_shooting() == true-- fire away as fast as possible repeat ecnt=get_exp_count() set_led(AF_led,1) repeat sleep(20) until get_usb_power(1) == 1 press("shoot_full") set_led(AF_led,0) tic = get_tick_count() repeat sleep(20) until get_usb_power(1) == 0 pwidth = get_tick_count() - tic i=0 repeat sleep(20) i=i+1 until( get_exp_count()~=ecnt ) or ( i>100 ) release("shoot_full_only") until ( pwidth > 2000) -- done release("shoot_half") restore() print("done")
Quote from: andrew.stephens.754365 on 06 / February / 2015, 18:21:49I was under the impression that no focus/exposure ops would be attempted with this setup . Does the outcome meake sense or is it likely a bug?When using one press & sync, the code does the focus & exposure adjustment and then a "full press" to shoot on the rising edge of the USB pulse ( 0V to 5V). So yes, there is focus & exposure setting done - it's just that the shot immediately starts after that rather than waiting for the USB 5V to be released. The big difference here is that the display will go dark in this mode when 5V is applied. When sync is not enabled the display stays active until the 5V is released.
So, if the half-press is sacrificied that infers the autofocus/exposure operations related to that process no longer occur - correct?
is there a particular reason why you didn't want to initiate the shooting process from the rising edge of a onepush?
As the risk of repeating myself again
The reason I even mention all of this is that you, as the photographer, will see something very different as a result. In the one push/normal/sync case, the display will go blank when you set the USB pin to 5v. In the one push/normal/no sync case it does not. So there is no chance to reframe your shot or waiting for the "perfect moment" by watching the LCD if you are using sync.
However, remember that the USB remote and PTP communications are sharing the USB port. So at some point before you remove 5V from the USB power pin for the first time, you need to call the usb_force_active() function. Prior to that, you need 5V connected to the USB power pin at all times to maintain communications. As you need to design your work flow sequence to accommodate this, one method might work better than the other for you.
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