Gphoto2 Tether
Context: $ARGUMENTS
Quick start
- What camera do I have plugged in? -> Step 1 (
tether.py detect) - Take one shot + pull it to disk: -> Step 2 (
tether.py shoot --download) - Live-view preview as MJPEG / JPEGs: -> Step 3 (
tether.py preview) - Record movie on camera: -> Step 4 (
tether.py movie) - Download every photo on the card: -> Step 5 (
tether.py bulk-download) - Change a setting (shutter / ISO / aperture): -> Step 6 (
tether.py config-*) - Timelapse: -> Step 7 (
tether.py timelapse) - Connect via Wi-Fi (PTP/IP): -> Step 8 (
tether.py ptpip)
When to use
- A supported DSLR/mirrorless is on USB (or on Wi-Fi via PTP/IP) and you want CLI control.
- Building a timelapse rig, photobooth, studio tether, automated capture loop.
- Remote focus pull, ISO/shutter/aperture bracketing, battery check.
- Always pair with
media-exiftoolafter capture if you need to tag EXIF / IPTC / XMP. - Not for video editing — use
ffmpeg-transcode/moviepyafter download.
Step 1 — Detect the camera
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py detect
Expands to:
gphoto2 --auto-detect
Output is a table of "Model | Port" pairs. Port is usually usb:NNN,MMM (bus, device). Use tether.py config-list afterwards to confirm config keys exist for that camera.
Step 2 — Capture (and optionally download)
Shoot one frame, keep it on the card:
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py shoot
Shoot and pull to the current directory:
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py shoot --download
Burst of 10 shots, all downloaded:
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py shoot --download --count 10
Under the hood (single shot):
gphoto2 --capture-image-and-download --filename "%Y%m%d-%H%M%S-%n.%C"
The %C specifier uses the file's actual extension (JPG, CR2, NEF, ARW, ...).
Step 3 — Preview / live-view
Dump a live-view JPEG to stdout once:
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py preview --once --out frame.jpg
Stream live-view at ~10 fps as a sequence to a directory:
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py preview --fps 10 --dest ./live/
Under the hood:
# Single frame:
gphoto2 --capture-preview --filename frame.jpg --force-overwrite
# Loop: gphoto2 --shell in a pipe, or repeated --capture-preview.
Note: live-view requires mirror-up (DSLR) or EVF-mode (mirrorless). Cameras that only expose live-view through the proprietary USB mode may not work.
Step 4 — Movie record
Start movie record for N seconds then stop:
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py movie --duration 30
Expands to:
gphoto2 --capture-movie=30s
Captures to the card; use bulk-download afterwards to pull the MOV/MP4 off.
Step 5 — Bulk download
Pull every file on the card (leaves originals on card):
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py bulk-download --dest ./ingest/
Expands to:
cd ./ingest && gphoto2 --get-all-files --skip-existing
Add --delete to wipe the card after successful download.
Step 6 — Config (shutter / aperture / ISO / focus / etc.)
List every config key the camera exposes:
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py config-list
Expands to gphoto2 --list-config.
Get one key's current value + allowed values:
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py config-get --key /main/capturesettings/shutterspeed
Expands to gphoto2 --get-config /main/capturesettings/shutterspeed.
Set a value:
uv run ${CLAUDE_SKILL_DIR}/scripts/tether.py config-set --key /main/imgsettings/iso --value 400
Expands to gphoto2 --set-config /main/imgsettings/iso=400.