Skip to content

CameraControl: add --ip for standalone control without an RMS config - #983

Open
Cybis320 wants to merge 2 commits into
prereleasefrom
cameracontrol-ip-arg
Open

CameraControl: add --ip for standalone control without an RMS config#983
Cybis320 wants to merge 2 commits into
prereleasefrom
cameracontrol-ip-arg

Conversation

@Cybis320

@Cybis320 Cybis320 commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

What

Adds --ip to Utils/CameraControl.py so a camera can be controlled directly by IP address, with no RMS config file:

python -m Utils.CameraControl --ip 192.168.42.10 GetDeviceInformation

Why

Today CameraControl requires --config and drives whichever camera the config's device URL points at. That's right for a configured station, but awkward for a camera that isn't in a config yet — bench bring-up, provisioning a new unit, or flashing firmware before the station is set up.

How

  • New --ip argument (default None).
  • When --ip is given, __main__ calls the existing cameraControl(ip, user, pwd, cmd, opts) path directly instead of loading a config.
  • Reuses the existing --user/--password overrides; they default to admin / empty, matching what cameraControlV2 extracts from a device URL.
  • --ip and --config are mutually exclusive.

Scope is deliberately just the entrypoint (argparse + __main__) — no behaviour change for the existing config-based path.

Testing

  • --ip <addr> GetDeviceInformation against a live GK7205V200 returns its Hardware / SoftwareVersion / Serial.
  • --ip <addr> --config <path> is rejected with a clear message.
  • --help lists the new argument.
  • The default config path is unchanged (config-based invocation untouched).

🤖 Generated with Claude Code

Cybis320 and others added 2 commits September 2, 2026 04:12
CameraControl currently requires a config file and drives whichever
camera its device URL points at. Add a -i/--ip argument that talks to a
camera directly by address, so a camera can be reached before it is in
any station config -- bench bring-up, provisioning a new unit, or
flashing firmware before the station is set up.

The IP path reuses the existing cameraControl(ip, user, pwd, ...) entry
and the existing --user/--password overrides (defaulting to admin /
empty). --ip and --config are mutually exclusive. No change to the
existing config-based path.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Firmware-side ISP control forwards daemon arguments verbatim to isp_ctl/hisp_ctl,
whose `manual`/`auto` subcommands use -a/-d/-i/-e (-i = ISP-digital gain). Giving
--ip a '-i' short form lets argparse swallow the daemon's `-i <val>` as the camera
IP, silently dropping it -- e.g. `Isp manual -a 1024 -i 1024 -e 30 --ip <cam>`
reached the camera as `manual -a 1024 -e 30` with no ispdgain. Keep only --ip.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@Cybis320
Cybis320 requested a review from markmac99 September 2, 2026 19:01

@markmac99 markmac99 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Will also be useful for non-RMS situations where one is using a compatible camera for other purposes.

Cybis320 added a commit that referenced this pull request Sep 3, 2026
Adds the ispControl() helper and four dvripCall handlers -- IspQuery,
IspManual, IspAuto, and a generic Isp pass-through -- that talk to the
isp_ctl/hisp_ctl TCP daemon on the camera's :9600 port. This reaches
manual ISP exposure/gain and pipeline control that DVRIP cannot (e.g.
`Isp wb unity`, `Isp gain 4096`, `Isp ae`, `Isp drc off`, `Isp status`).

The daemon takes one text command per TCP connection, returns its
response, then closes; ispControl() forwards the command verbatim and
logs the reply. Commands target cam.ip, so they work in config mode
today and pair naturally with the standalone --ip flag (#983) for
bench/ad-hoc cameras without a config.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Cybis320 added a commit that referenced this pull request Sep 6, 2026
… an RMS config

# Conflicts:
#	Utils/CameraControl.py
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants