WiFiCameraControl - Wireless Remote Control for taking photos

  • 6 Replies
  • 2570 Views
WiFiCameraControl - Wireless Remote Control for taking photos
« on: 03 / September / 2016, 06:38:20 »
Advertisements
This is a script for wireless remote shooting using CHDK and a Toshiba FlashAir WiFi SD-card.

Use any smartphone, iPad, computer, ... to control a CHDK script on the camera which takes a photo.

Using this script you can connect to the FlashAir card via Wifi and a Web browser to get a web page which allows interaction with the camera:
* Zoom in / zoom out
* Take a picture
* Take a number of pictures with a settable interval (a very simple intervalometer)
* Adjust delay until the first picture is taken
* See information about camera status (free space on SD, battery voltage, ...)

The project is hosted on  Github.
The script is also attached to this post.

Installation is a bit more complicated than other CHDK scripts, since this project contains several files (the CHDK script, another lua script which does not run on the camera but on the FlashAir card plus the web page files), but it should not be too difficult. See webpage on Github for instructions.

This is my first CHDK script, so there may be some rough edges. You have been warned    :)

The script has been tested on a Canon SX260 HS.
From what I read about CHDK's zoom functions this may not work perfectly on all cameras. The script does not use setZoom(), which is (has been?) known to cause problems, so it should work on all cameras, but the display on the web page may be wrong. Feedback will be welcome.

This project is based on ideas and work from   this thread.

Enjoy.
Jens

Re: WiFiCameraControl - Wireless Remote Control for taking photos
« Reply #1 on: 03 / September / 2016, 08:42:46 »
Nice! 

And I just happen to have a 8G Toshiba FlashAir card sitting in a box that I have never gotten around to trying out.   There goes another day of my weekend.


Edit :   just looked at the README.md file.  My card is a couple of years old - doesn't actually say if it's a W-03 or W-02 or W-01.

Which makes me suspect it's going to be too old?  I notice the card in the original thread you  mentioned is my model though.  What's different between W-03 and W-01 that matters here?
« Last Edit: 03 / September / 2016, 09:11:33 by waterwingz »
Ported :   A1200    SD940   G10    Powershot N    G16

Re: WiFiCameraControl - Wireless Remote Control for taking photos
« Reply #2 on: 03 / September / 2016, 13:52:12 »
You definitely need a W-03 version card. It should say "W-03" somewhere on the sticker.

My "script" is actually two lua scripts: One CHDK script and another script which runs on the Flashair web server which also happens to run lua scripts.

According to this website, only the W-03 cards support lua scripts.

I decided to use a lua script on the web server to allow XmlHttpRequests between the web page and the camera in the hope that this would allow for quicker response times compared to exchanging command files and reloading web pages as discussed in the older Flashair thread.

Jens

*

Offline msl

  • *****
  • 1239
  • A720 IS, SX220 HS 1.01a
    • CHDK inside
Re: WiFiCameraControl - Wireless Remote Control for taking photos
« Reply #3 on: 04 / September / 2016, 04:09:52 »
Nice work!

I'm still looking for a solution without Lua on the sd card (Transcend Wifi sd card has Lua not included.), maybe with a cgi script.

msl
German CHDK pages:  CHDK forum | CHDK inside | CHDK Twitter News by msl | Download CHDK-DE (Autobuild)
Note: SDM violates the GPL rules!


Re: WiFiCameraControl - Wireless Remote Control for taking photos
« Reply #4 on: 04 / September / 2016, 05:04:41 »
The discussion in the older thread used a solution without running lua on the SD-card.

But if the Transcend card can run cgi-scripts, then my solution could be made to work there, too.
According to this gist the card runs linux and perl as a cgi-script interpreter. It should be fairly simple to convert "status.lua" to perl (although I can't really judge since I never used perl)
I can help by providing my thoughts behind the design of status.lua, if you want.

Jens

Re: WiFiCameraControl - Wireless Remote Control for taking photos
« Reply #5 on: 22 / September / 2017, 13:53:25 »
is it possible to access with your script a few cameras at once?

So I want to shoot 10 images per second 3, 5 or even 7 cameras in the same time.
Do I need to open 3, 5 or 7 differnt browser tabs and in that a unique connection to each camera?
Or does that not work at all currently?

If it is currently working only with one camera, how much work is it, to adopt it to my needs?

Re: WiFiCameraControl - Wireless Remote Control for taking photos
« Reply #6 on: 14 / October / 2017, 12:40:23 »
shooting that fast would require major work on the script, sorry.
Controlling several cameras at once is possible but requires additional work to actually use it.

The CHDK part of the scripts works by polling a file on the SD-card a *lot* less often than 10 times a second, which determines the minimum shot-to-shot time.
My camera (SX260HS) takes a few seconds from shot to shot anyway, so I did not have a need for implementing a "fast shoot" mechanism.

Controlling several cameras at once is possible, but requires setting up a Wifi network (e.g. your Wifi at home), having the cameras (resp. the SD-cards) all join this network and then opening one browser tab for each camera like you already guessed.
You  could also use curl and write a small batch-file to trigger all cameras with a double-click. It would work for any number of cameras but the cameras would not shoot at exactly the same time. I guess the accuracy would be between 0.5 and 1 second for any number of cameras (even only two).

Sorry, no out-of-the-box solution for your needs, at least not with the required shooting speed.

Jens

 

Related Topics