Skip to content

perf: Cache strobe time in Hamamatsu camera driver #505

Description

@hongquanli

Problem

HamamatsuCamera.get_strobe_time() queries two hardware properties (INTERNAL_LINEINTERVAL, TRIGGERDELAY) via the DCAM SDK on every call. It's called from set_exposure_time(), which can be frequent.

The strobe time only changes when resolution, binning, or shutter mode changes — not on every exposure change.

Proposed Fix

Cache the strobe time value and only recalculate when resolution, binning, or shutter mode changes (similar to how Toupcam caches StrobeInfo in _update_internal_settings).

Context

Identified during #504 (global reset mode PR).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions