Build a Raspberry Pi-Based Cable Shutter Release for Sony Cameras

Replacing a simple and inexpensive remote cable release for your camera with Raspberry Pi may seem like a classic case of over-engineering, but using the tiny machine to control the camera opens up a whole new world of photographic opportunities. Using a simple Python script, you can turn Raspberry Pi into a powerful and flexible intervalometer or trigger the shutter using sensors connected to the computer. Add to Raspberry Pi a Python-based web app, and you can control your camera from any computer or mobile device.

As with any DIY electronics project, there is always a risk of damaging your camera, so proceed with caution. If you are not sure what you are doing, don’t proceed at all.

This project provides brief instructions on how to build a Raspberry Pi-based cable shutter release and deploy a simple web app that can be used to control it. The setup uses a Sony NEX-3N camera, but any Sony camera compatible with the RM-VPR1 cable release should work fine. And with a few minor tweaks, you can adapt the setup to work with many other camera models.

  • RM-VPR1 remote cable release (you can buy a compatible unit cheaply on eBay)
  • 2x 1K resistors
  • 2x 2N2222 NPN transistors
  • A breadboard and handful of jump wires

First, disassemble the remote cable release. The release has three wires: focusing wire (yellow), trigger wire (red), and ground wire (white). The wire colors may vary depending on the unit you use. The way the cable release works is very simple: when it mechanically shorts (i.e., closes the circuit) the focusing and ground wires, the camera obtains focus. With the focusing and ground wires still shorted, the release then shorts the trigger and ground wires, which triggers the camera’s shutter.

To close the circuits in the required order electronically, you need to create a twin-transistor switch as shown below:


Use the following diagram to wire the circuits on the breadboard:


Next, boot Raspberry Pi and run the nano command to create a file and open it for editing. Paste the following code into the file:

#!/usr/bin/env python
from time import sleep
import RPi.GPIO as GPIO
GPIO.setup(23, GPIO.OUT)
GPIO.setup(25, GPIO.OUT)
GPIO.output(23, True)
GPIO.output(25, True)
GPIO.output(25, False)
GPIO.output(23, False)

Save the script and make it executable using the chmod +x command. Plug the cable release into the camera, turn it on, and run the script using the sudo ./ command. If everything works properly, the camera should fire.

To make it easier to control the cable release, you might want to add a simple Python-based web app. To do this, install the Python Bottle framework:

sudo apt-get update
sudo apt-get install python-pip
sudo pip install bottle

Instead of writing the web app from scratch, you can grab the code for this project from GitHub using the following command:

sudo git clone

Once you’ve done that, use the terminal to switch to the sony-rpi-remote directory, and run the sudo ./ command to launch the app.


Point then the browser to (replace with the actual IP address of Raspberry Pi), and you should see the web app in all its bare-bones beauty.


Tech writer covering Linux and open source software

Tagged with:
Posted in Hardware, Photography
2 comments on “Build a Raspberry Pi-Based Cable Shutter Release for Sony Cameras
  1. David Cox says:

    Wondering why you would need to use the VPR1 remote. Is there are a reason you cannot use a the USB cable you use to connect the camera to a PC. The connector is identical. Is there some functionality built into the cable itself?

    • Dmitri Popov says:

      If I’m not mistaken, Sony NEX and Alpha cameras feature so-called a multi-terminal USB port. I’m not sure how it’s different from a regular USB, though, so I thought I’d use a spare VPR1 cable just to be on the safe side.

Comments are closed.

Recipes for automated and streamlined photographic workflow on Linux

Use digiKam? Get this book!

Practical advice for nighttime photography


%d bloggers like this: