Message Boards Message Boards

Arduino Sketch to build an Intervalometer?

Posted 9 years ago
POSTED BY: Douglas Youvan
4 Replies

Ian,

That is very helpful. I'll try.

Doug

POSTED BY: Douglas Youvan

Ian, You are exactly correct. I have the camera side working. It's simply a short (closed) circuit that holds the shutter open. This would be nice to have on the "Connected Devices" page because it is a Nikon. Nikon has a uniform protocol for their cameras.

Thanks, Doug

POSTED BY: Douglas Youvan

So what you can do is you can connect the Arduino to Mathematica using the built-in Arduino device driver.

Depending on which version of Mathematica 10 you are using you will need to have the appropriate version of the Arduino software installed. You can check the in-product documentation page for Mathematica by searching for Arduino and noting the supported Arduino software version listed under the Device Properties section. The web link above is for Mathematica 10.3.

Once you have the appropriate version of the Arduino software installed, you can open a connection to the device with DeviceOpen, and then upload the custom Mathematica sketch with DeviceConfigure[ "Arduino" , "Upload" ]

Then you can turn on/off any pin with DeviceWrite["Arduino", 13 -> 1] (replacing 13 with whatever pin you need and 1 with 0 if you need to turn if off). Note that the max frequency using DeviceWrite is around 140 Hz. If you need faster frequency, than you can use a custom function as documented under the DeviceConfigure section of the Arduino device driver documentation page.

Ian

POSTED BY: Ian Johnson

Hi Douglas,

So the physical circuit you have is a relay switch hooked up to an Arduino, such that when you write the pin high (or low depending on how it was wired) it activates the relay?

Additionally, it sounds like what you need to be able to do is to be able to activate the relay (triggering the remote on the camera), then shortly thereafter deactivate the relay from Mathematica?

Is that correct?

Thanks,

Ian

POSTED BY: Ian Johnson
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract