EngDrvRead is available on all cameras, and is found by the sigfinder (only for DryOS ATM). It will need a wrapper though.
The EngDrv functions are available as eventprocs, so finding it on vxworks cameras should not difficult.
This topic has continued to be interesting to the people with multi-camera bullet time rigs (and those who wish to do stereo photography with CHDK).In order to get this into the 1.3.0 trunk, the patch needs to be generalized so that it can be activated on cameras that have been tested, and so that it can be easily enabled for testing on cameras where the feature is requested.To that end, I've attached a patch file that shows how this might be done. It assumes thatCode: [Select]#define USB_PRECISION_SYNC 1is added to the platform_camera.h of any cameras where the feature is tested (or is to be tested).There are four "register" values that need to be defined. I stuck them in the usb_remote.c code for this example but they belong in either platform_camera.h or perhaps stubs_min.S or stubs_entry_2.S. Obvious if they get added to the sigfinder they go in stubs_entry.SCode: [Select]// s90 values#define USB_SYNC_REGISTER_1 0xC0F06000#define USB_SYNC_REGISTER_2 0xC0F06014#define USB_SYNC_REGISTER_3 0xC0F07008#define USB_SYNC_PERIOD 0x00386014Finding the first three of these seems to depend only on having a digicIV or digicV camera but its not clear that is always true. The last one is apparently found by looking inside the EngDrvOut function.I suppose I could have posted this in the 1.3.0 planning thread, but it seem to make more sense to put it here.
#define USB_PRECISION_SYNC 1
// s90 values#define USB_SYNC_REGISTER_1 0xC0F06000#define USB_SYNC_REGISTER_2 0xC0F06014#define USB_SYNC_REGISTER_3 0xC0F07008#define USB_SYNC_PERIOD 0x00386014
#define GPIO_VSYNC_UPDATE 0xC0F06000#define GPIO_VSYNC_MAX 0xC0F06014#define GPIO_VSYNC_CURRENT 0xC0F07008
As far as I can tell the IO addresses are the same on all Digic cameras (from S5IS to SX50HS). The shadow RAM address changes from camera to camera, so using EngDrvRead would be preferable for USB_SYNC_PERIOD.
int std_period = _EngDrvRead(USB_SYNC_REGISTER_2);
I'm not sure about the names though - these IO addresses don't really have anything to do with USB and synching is just a side effect. Funnel used regB (0xC0F06014) and reg_update (0xC0F06000) in his script; but these aren't really very accurate either.Perhaps:Code: [Select]#define GPIO_VSYNC_UPDATE 0xC0F06000#define GPIO_VSYNC_MAX 0xC0F06014#define GPIO_VSYNC_CURRENT 0xC0F07008
This topic has continued to be interesting to the people with multi-camera bullet time rigs (and those who wish to do stereo photography with CHDK).
waterwingz, please could you explain to me how i would implement your precision_sync.patch? Since I don't have real experiences I am hesitating a little to put this piece of software into my camera without knowing what I do.Shall I simply copy the _wait_until_remote_button_is_released function into my usb_remote.c, together with the defines? What about the USB_SYNC_PERIOD that should be found in "EngDrvOut"? Can this be omitted, as stated in a later Mail? And if so, how?Thanks a lot!
Started by Microfunguy CHDK Releases
Started by Blooper « 1 2 » Creative Uses of CHDK
Started by David Ripple « 1 2 ... 6 7 » General Discussion and Assistance
Started by koshy « 1 2 ... 8 9 » General Discussion and Assistance
Started by cameraman Creative Uses of CHDK