Skip to content

Enhanced default behavior: Automatic GoPro SD card detection and firmware management #67

@fxstein

Description

@fxstein

Summary

Enhanced the default behavior of goprox to automatically detect and manage GoPro SD cards when run without parameters. This provides a comprehensive GoPro SD card management experience in a single command.

Requirements

  • When goprox - import and process GoPro media files

Usage: goprox [commands] [options] [advanced options] ...

Commands:
-a, --archive archive source sdcard
-i, --import import media files
-p, --process process imported files
default: process imported files since last process run
all: process all imported files
val[ymwdHMS]: process files modified within the specified time period
--clean clean up source sdcard
checks if source is a GoPro sdcard format
--firmware update sdcard to the latest GoPro official firmware version
--firmware-labs update sdcard to the latest GoPro Labs firmware version
--geonames add geonames information to imported directories to enable time processing
--mount trigger mountpoint processing
will search for GoPro media card mountpoints and kick of processing
this is also leveraged by the goprox launch agent
--setup run program setup
--test run program tests
this option is reserved for developers who clone the GitHub project

Options:
-h, --help show this help message and exit
-c, --copyright add copyright information to processed files
-l, --library specify library directory
-s, --source specify source directory for media files commonly .
-t, --timeshift adjust timestamps of imported files
-q, --quiet run program quietly
-v, --verbose run program verbosely
--config specify config file
defaults to ~/.goprox
--debug run program in debug mode
--time specify time format for output
format: specify time format for output
--version show version information and exit

Advanced Options:
--if specify conditional processing
condition: specify condition for processing
--created-on filter files by creation date
date: filter files created on the specified date
--created-after filter files by creation date
date: filter files created after the specified date
--created-before filter files by creation date
date: filter files created before the specified date
--modified-on filter files by modification date
date: filter files modified on the specified date
--modified-after filter files by modification date
date: filter files modified after the specified date
--modified-before filter files by modification date
date: filter files modified before the specified date
--repair repair imported files time information
created: repair file creation dates

For more detailed documentation type: man goprox or visit https://github.com/fxstein/GoProX is run without any parameters, it should scan all mounted volumes for GoPro SD cards

  • Automatically detect firmware type (official vs Labs) based on version suffix
  • Check for newer firmware versions and offer updates
  • Propose volume renaming with shortened names based on camera type and serial number
  • Provide comprehensive information about each detected card
  • Show summary of all actions taken

Motivation

Previously, users had to run multiple commands or use specific flags to manage GoPro SD cards. The new default behavior makes goprox more user-friendly and provides immediate value when users insert a GoPro SD card.

Acceptance Criteria

  • Scan all mounted volumes for GoPro SD cards
  • Extract and display camera information (type, serial number, firmware version)
  • Detect firmware type automatically (official vs Labs based on version suffix 70-79)
  • Check for newer firmware in appropriate repository (official vs Labs)
  • Offer firmware updates with confirmation prompts
  • Propose volume renaming with shortened names (CAMERA_TYPE-SERIAL_LAST_4)
  • Suppress redundant output when volume name is already correct
  • Detect existing firmware update files to avoid repeated prompts
  • Show comprehensive summary of all actions taken
  • Handle both renaming and firmware updates in single session

Technical Implementation

Firmware Type Detection

  • Official firmware: Ends with (e.g., H22.01.01.10.00)
  • Labs firmware: Ends with to (e.g., H22.01.01.10.70)

Volume Naming Convention

  • Format:
  • Example: (from HERO11 Black with serial ending in 8909)
  • Removes "Black" from camera type names for brevity

Smart Detection Features

  • Automatically checks correct firmware repository based on current firmware type
  • Downloads and caches firmware files
  • Extracts update files to SD card UPDATE directory
  • Creates marker files to prevent duplicate processing
  • Detects existing UPDATE directories to avoid repeated prompts

Example Output

Scanning for GoPro SD cards...
Found GoPro SD card: HERO11-8909
  Camera type: HERO11 Black
  Serial number: C3471325208909
  Firmware version: H22.01.01.10.70
  Firmware type: labs
  Firmware update already prepared (UPDATE directory exists)

Summary: Found 1 GoPro SD card(s)
  - 1 already correctly named
SD card detection finished.

Reference

This feature builds upon the existing firmware management and SD card detection capabilities, integrating them into a seamless default experience.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions