How to change mode to video from script ? - Script Writing - CHDK Forum  

How to change mode to video from script ?

  • 7 Replies
  • 3022 Views
How to change mode to video from script ?
« on: 13 / May / 2009, 05:34:24 »
Advertisements
I'm trying to change the mode from "photo" to "video" from a script (on SD870/IXUS860), but it does not work.
The physical mode switch is set to "photo". In the script I'm setting properties 49 and 50 to 2597 (to match what I read when I manually set the mode switch to "Video"), but after executing:
Code: [Select]
press "shoot_full"
sleep 5000
release "shoot_full"
a picture is taken instead of a video.
When displaying the image though, the logo displayed next to it is "video", but it is indeed a .jpg photo, not a video.
When the physical mode switch is set to "video", the above script takes a video.
Any idea ?
Thanks,
Marc

Re: How to change mode to video from script ?
« Reply #1 on: 13 / May / 2009, 06:03:03 »
I'm trying to change the mode from "photo" to "video" from a script (on SD870/IXUS860), but it does not work.

Although you can read property cases, trying to set them does not work for many properties.

Temporarily rename your DISKBOOT.BIN and install this version.

Try this script :-

@title Movie mode
@param a movie duration
@default a 10
shoot_movie_for a
end


Does it work ?

David

Re: How to change mode to video from script ?
« Reply #2 on: 13 / May / 2009, 08:32:40 »
Hi David,
It works ! This version of CHDK is very different from the "regular" one, though...
I have 2 questions:
1) Can this work with the "regular" CHDK builds ?
2) Can the movie length be controlled on the fly, instead of having it fixed beforehand ?
Marc

Re: How to change mode to video from script ?
« Reply #3 on: 13 / May / 2009, 09:54:29 »
1) Can this work with the "regular" CHDK builds ?

That script only works with SDM (StereoData Maker).

That is what the DISKBOOT.BIN that you used is.

It has all the most useful CHDK features, powerful uBasic commands and features for bracketing and time-lapse.
As it says on the webpage, SDM is certainly not just for stereo.
There is an option to turn-off the stereo information at the top of the screen.

Quote
2) Can the movie length be controlled on the fly

Yes, you simply write a script that uses commands 'movie_mode' and 'record_mode' and click the shutter buttons to start and stop the movie.

All commands described here.


David


Re: How to change mode to video from script ?
« Reply #4 on: 13 / May / 2009, 12:05:33 »
It works, I can switch between movie and photo mode :)
The only problem, when trying my existing scripts with SDM, is that the following script fragment doesn't work anymore:
Code: [Select]
press "shoot_half"
rem wait for ready-to-shoot
do
  get_prop 206 p
until p=1
shoot
This waits for the camera to be ready (autofocus, exposure measurement, etc...), then shoots.
With SDM CHDK, this loop takes about 10 seconds to complete, instead of the usual half second.
Any idea ?
Marc

Re: How to change mode to video from script ?
« Reply #5 on: 13 / May / 2009, 12:25:05 »
With SDM CHDK, this loop takes about 10 seconds to complete, instead of the usual half second.
Any idea ?

Yes, you are in the SDM default 'synch' mode where we wait for a USB remote switch to be released.

Ten seconds is the time-out value.

To quickly turn synch mode off, press the shutter button before running your script.

Otherwise, at the start of your script add  'set_sync 0 0 0 0' .

That also turns synch off.


David

Re: How to change mode to video from script ?
« Reply #6 on: 14 / May / 2009, 11:40:15 »
Hello David,
Thank you very much for your help.
I am in a phase of evaluation, before purchasing the CHDK2 device from gentledIR. With your patient explanations, it seems I can program the camera to do what I need remotely.
Thanks again,
Marc

Re: How to change mode to video from script ?
« Reply #7 on: 14 / May / 2009, 11:54:37 »
You are welcome.

I am currently working with James from gentLES to design a new product for stereo and multi-camera synchronised flash and time-lapse.

David


 

Related Topics