Multi-camera setup project. - page 27 - Creative Uses of CHDK - CHDK Forum

Multi-camera setup project.

  • 462 Replies
  • 211702 Views
*

Offline mphx

  • ***
  • 210
Re: Multi-camera setup project.
« Reply #260 on: 13 / November / 2014, 17:30:31 »
Advertisements
@andrew

and... santorini is overrated ...and not for sale last time i've checked :)

the footage for anyone that cares :) https://www.dropbox.com/s/1qk0t09tm8fll43/john_skai_part1-cropped.mp4?dl=0

feel free to yell "it's all greek to me" :)

Re: Multi-camera setup project.
« Reply #261 on: 13 / November / 2014, 17:58:58 »
Whatever you are seeing, it is unrelated to the thread you linked.  The necessary code is in capt_seq.c for the SX150HS.

WW - you may notice the "e.g"  I stated before the link ?

The issue is, I suspect, an example of the same problem on a different camera !


Edit:
Cross reference to here http://chdk.setepontos.com/index.php?topic=8810.msg118513#msg118513
« Last Edit: 21 / November / 2014, 16:05:40 by andrew.stephens.754365 »

Re: Multi-camera setup project.
« Reply #262 on: 13 / November / 2014, 18:06:00 »
@andrew

and... santorini is overrated ...and not for sale last time i've checked :)

the footage for anyone that cares :) https://www.dropbox.com/s/1qk0t09tm8fll43/john_skai_part1-cropped.mp4?dl=0

feel free to yell "it's all greek to me" :)

No translation needed for the interviewers  :)

Edit: this should really go viral... especially since it's all Greek to me !
« Last Edit: 21 / November / 2014, 16:03:42 by andrew.stephens.754365 »

*

Offline rick

  • *
  • 11
Re: Multi-camera setup project.
« Reply #263 on: 23 / November / 2014, 01:45:15 »
I get the concept that "Default Running" means there is no script to run actually. But when this indicator is ON i have noticed that i cant run a script from pc to the camera let's say.
You can only run one script at a time on the camera. When chdkptp wants to run a script there cannot be one already running. I think that when it does run a script, it does not provide a script name to the camera so the "default script" name defaults in the CHDK code and that is what you are seeing.

Quote
At your last phrase "you won't need to worry at all about disconnecting and reconnecting". But with the "usb switch" method a disconnection occurs no matter what. At that point the two script won't lose "connectivity"?
When you used CHDKshell to build your own version using my simple patch, you bypassed that. The patch tricks the Canon PTP code into not seeing the disconnection (i.e. USB power going away) when you press the button. The PC also can't tell that the button was pressed so both the host script and the camera scripts keep running as if nothing has happened. That was the whole point of doing the patch in the first place - you could just use the stock build otherwise.

If I use bcamhost and bcamrem,should I build the special version for my A1200?
(current build info:CHDK 1.3.0 Revision:3726 a1200 100c GCC4.4.3)
If yes,could you tell me how to build the special version?
1.open CHDK GCC Compiler Shell v.3.44 trunk3661
2.choose A1200 100c option
3.click “Source Tool...”,then“Patch...”,select “shared_usb_v13.patch”
how to go on with the popup window (see 2.png)
4.Which options should I set in the “compile options...”

Another question,what is the mask script (novsela called it mask code,see 1.png)?
Thanks!
« Last Edit: 23 / November / 2014, 03:22:31 by rick »

Re: Multi-camera setup project.
« Reply #264 on: 23 / November / 2014, 10:34:24 »
If I use bcamhost and bcamrem,should I build the special version for my A1200?
That should not be necessary (see below).
Quote
Another question,what is the mask script (novsela called it mask code,see 1.png)?
That post refers to a specially modified version of CHDK that allowed the concurrent use of USB "sync" and ptp communications on the same setup.  It was added to the autobuild some time ago and enabled on a few cameras (those that were tested with the patch and confirmed to work).   The A1200 is one of those cameras.
Ported :   A1200    SD940   G10    Powershot N    G16

*

Offline rick

  • *
  • 11
Re: Multi-camera setup project.
« Reply #265 on: 23 / November / 2014, 10:57:57 »
Thank you so much!waterwingz
That's really  a good news to me :)

Then,I  could  go to the next work.
Is it possbile to add some commands ,such as“exec bc=require('bcamHost') bc:connect() bc:cmdwait('shoot')”, to CHDK PTP-- User Tab as a button just like what mphx did.
If it is possbile,could you give me an example?Thus I can learn from it to edit some other commands by myself.
Thanks!

*

Offline mphx

  • ***
  • 210
Re: Multi-camera setup project.
« Reply #266 on: 23 / November / 2014, 11:45:06 »
Thank you so much!waterwingz
That's really  a good news to me :)

Then,I  could  go to the next work.
Is it possbile to add some commands ,such as“exec bc=require('bcamHost') bc:connect() bc:cmdwait('shoot')”, to CHDK PTP-- User Tab as a button just like what mphx did.
If it is possbile,could you give me an example?Thus I can learn from it to edit some other commands by myself.
Thanks!

First of all check your commands in the GUI's console to find the exact expression...
Then you can easily make a button to put your command in it.
You can use "user" tab and check gui_user.lua to see how buttons are made.Create one of your own and experiment.
It's not hard if you get familiar with the syntax.

You can create your own TAB in the GUI and put your commands in it although this requires some additions to  gui.lua file and the creation of a new lua file to hold your buttons.

In any case reyalp can be of more help or i can attach you some example files....although you'd better experiment yourself to learn things.

*

Offline rick

  • *
  • 11
Re: Multi-camera setup project.
« Reply #267 on: 28 / November / 2014, 00:05:08 »
With mphx‘s help,I edited some buttons of both multicam way and bcam way.
Now I can easily shoot and download images.
So I found out a old CRT and downloaded SyncTest011 to make a sync test.(see a.jpg)

I used two canon powershot A1200, set shutter speed to 1/200 sec , ISO 400 (at home night),F2.8.
The CRT is LG 775FT plus( vertical frequency 83Hz, horizontal frequency 66.4KHz, resolution 1024 x 768).
In multicam way, I used “preshoot” command which is better than shot “shoot” command.
In bcam way, I turned on the sync of each camera in the bcamrem script and shot through controlling the switch of central usb hub.
I just took ten shots in each way.

The result of multicam way:
Minimum Mis-Sync (ms):  4.80    Average Mis-Sync (ms): 12.35 (1/81 sec)
Maximum Mis-Sync (ms): 27.86   Average Deviation:       6.51
            
The result of bcam way:
Minimum Mis-Sync (ms):  0.05    Average Mis-Sync (ms):  0.54 (1/1852 sec)
Maximum Mis-Sync (ms):  2.94   Average Deviation:       0.52

The datasets and reports are as below.
https://drive.google.com/folderview?id=0B4hGaTy8v6W1amdxbDNyOHJ4UUE&usp=sharing

multicam way is more convenient.
bcam way is more stable and synchronous.

@mphx:You said the multicam way is enough for building 3D model,do you use faster shutter speed? Thus I think you must use brighter lights.

@ reyalp:Is it possible to improve the Synchronization of the multicam way?

@ waterwingz:Now I use three a1200s,I can shoot just by controlling the switch of the central usb hub to disconnect the USB 5V power without any modification(see b.jpg). Could I still use this method when using 40+ cameras?

*

Offline reyalp

  • ******
  • 14125
Re: Multi-camera setup project.
« Reply #268 on: 28 / November / 2014, 00:56:42 »
Very nice work :)
@ reyalp:Is it possible to improve the Synchronization of the multicam way?
I'm not sure which commands you used. To get the best sync you should
1) Use CHDK 1.3
2) init_sync
3) preshoot and wait for all cameras to be ready
4) ensure sync time is far enough in the future that the shoot command can be sent to all cameras.
5) shoot using the shoot_hook_sync command

If you post the exact code you used to shoot, I can probably tell you if anything is missing. The testshots function might be a useful example.

That said, ~30ms max deviation is about as good as I'd expect with the current code (and if you did enough tests I'd expect the occasional outliers to be even further off). The current system is fundamentally limited by the fact that the tick counter and sleep function only have 10ms precision at best. There is uncertainty in the initial PTP sync, and due to the whole process happening across several tasks.

In theory, using high precision timers (see http://chdk.setepontos.com/index.php?topic=11342.0) and proper task synchronization objects (semaphores or eventflags) it would be possible to get substantially better sync over PTP. This would require non-trivial hacking in the core CHDK code, as well as in multicam. I suspect this could get into the <10ms range, and perhaps better.

Edit:
Some improvement should be possible just by implementing a < 10ms tick counter.

Note that another option on cameras that don't use AA batteries is to use the battery temp as the trigger instead of USB power.
« Last Edit: 28 / November / 2014, 00:59:02 by reyalp »
Don't forget what the H stands for.

*

Offline mphx

  • ***
  • 210
Re: Multi-camera setup project.
« Reply #269 on: 28 / November / 2014, 04:22:41 »

@mphx:You said the multicam way is enough for building 3D model,do you use faster shutter speed? Thus I think you must use brighter lights.

Multicam sync times are enough for building 3d models.We have built enough so its a sure thing what i am saying :).
But we are talking about relatively motionless "objects"...i mean people taking a pose with minimum to none movement...like the poses we take when we get photographs...
If more movement is involved i believe that we will have problems :)

As far as sync times are concerned i haven't measured them.
I use the steps reyalp is mentioning (1,2,3,4,5 --see above post)
We use two buttons .. preshoot and shoot.
We issue the PRESHOOT command ....and we wait for the client to get his/her pose.And then we issue the SHOOT command.
We hear ONLY ONE sound...that in my world means almost perfect syncing :)

BUT we have noticed the following thing.If cameras are turned on for many hours..after a while ..they lose sync (although sync command is issued and in effect).And by "losing" i mean , with the same process i described above , we hear more than one SHOOT clicks when shoot command is issued.Maybe cameras' mechanisms getting warm or something..i don't know...

So we turn them on 1-2 hours before the shooting , so to be sure :)


Finally if you are thinking of making 3d models with the whole setup you are making , lets hope you have good 3d modelling skills , because the produced 3d model needs  A   L O T  O F   W  O R K  to become ready for printing or whatever...low quality of these canon series , don't produce the best images for 3d modelling...


PS: we have bright lights in the shooting area..we don't mess with shutter speed , only iso and zoom.Some photos are taken bright and few (2-3 out of 64) a bit darker...so maybe we should mess with shutter speed at some point..but we can handle the difference in light in those few photos in the 3d modelling procedure for the time being.
« Last Edit: 28 / November / 2014, 04:27:25 by mphx »

 

Related Topics


SimplePortal © 2008-2014, SimplePortal