Magic Lantern Forum

Using Magic Lantern => Hardware and Accessories => Topic started by: Macgyver on September 22, 2019, 02:23:04 AM

Title: Connecting a sensor , add sensor data to picture info
Post by: Macgyver on September 22, 2019, 02:23:04 AM
Here's a challenge -

I am trying to add data from sensors (height,temperature,distance by laser) to pictures i take with a canon DSLR camera.

Would it be possible to connect different sensors through a canon DSLR "hot shoe" or other input? and then add data from the sensor to the picture at the precise moment the picture was taken?

for example - have a temperature sensor connected to the camera, the temperature data is added to the image stored in the camera. same way other data that comes with pictures such as geo location,shutter info, etc..

i need it to be VERY precise timing wise - exactly on the time the picture was taken.

would love to hear your ideas, Also looking for someone who can do this as paid project.

Macgyver
Title: Re: Connecting a sensor , add sensor data to picture info
Post by: a1ex on September 22, 2019, 07:28:00 AM
The hot shoe is handled by the MPU (https://www.magiclantern.fm/forum/index.php?topic=17596.0), to my knowledge, and I did not explore it. I'm pretty sure others did, outside the ML project.

The port with the most consistent timing is probably the UART (https://www.magiclantern.fm/forum/index.php?topic=7531) (available as a debug port, but finding the right connector can be challenging).

The USB port is also available, but your device needs to be a USB host. No idea about timing; probably OK.

Bit-banging over the audio input (microphone) pin might be doable, too. See this remote trigger (https://www.magiclantern.fm/forum/index.php?topic=11930.0).

Timing, i.e. "exactly on the time the picture was taken." -> better sync this one with a microphone :)

Reason: the main CPU controls the exposure, but the mechanical shutter (which gives the actual exposure timings) is handled by the MPU. Communication between them is a little slow. Maybe the timing is actually consistent - who knows - one has to do a bit of low-level experimentation to find out. Start here (https://www.magiclantern.fm/forum/index.php?topic=1915.0).

For adding metadata to pictures, the easiest way is by using a sidecar file. See this thread (https://www.magiclantern.fm/forum/index.php?topic=18083).