Skip to content

Get Parameter

SUMMARY

Get Parameter reads the current value of a named camera parameter — for example exposure time, acquisition frame rate, or device link throughput limit. Use it to inspect the camera's starting state before tuning, or to verify that a set_parameter call took effect.

Available on: IDS.

The Skill

python
value = camera.get_parameter("ExposureTime")

The parameter name must exist in parameter_name_to_type_map in medulla/cameras/ids.py — passing an unknown name raises a KeyError. Common names: AcquisitionFrameRate, ExposureTime, DeviceLinkThroughputLimit.

The Code

python
"""
Read the current values of all supported IDS parameters.

Run from a terminal to avoid issues with Rerun's spawn mode.
"""
from loguru import logger

from telekinesis.medulla.cameras import ids


def main():
    camera = ids.IDS(
        name="my_ids_camera",
        serial_number="4108909352",
        load_factory_defaults=False,
    )
    try:
        camera.connect()

        logger.info(f"AcquisitionFrameRate: {camera.get_parameter('AcquisitionFrameRate')}")
        logger.info(f"ExposureTime: {camera.get_parameter('ExposureTime')}")
        logger.info(f"DeviceLinkThroughputLimit: {camera.get_parameter('DeviceLinkThroughputLimit')}")
    finally:
        camera.disconnect()


if __name__ == "__main__":
    main()

The Explanation of the Code

After connect has opened the device, get_parameter queries the IDS Peak SDK for the current value of the named parameter and returns it. Calling it for every supported parameter at the start of a script gives a clear picture of the camera's starting state and makes it easier to diagnose unexpected behavior after parameters are modified.

python
logger.info(f"ExposureTime: {camera.get_parameter('ExposureTime')}")

The parameter name must exist in parameter_name_to_type_map in medulla/cameras/ids.py. Passing an unknown name raises a KeyError immediately rather than failing silently.

Where to Use the Skill

  • Pre-tuning inspection — read the camera's current settings before deciding what to change.
  • Verification — confirm that a set_parameter write took effect.
  • Debugging unexpected behaviour — log all parameter values when capture results don't match expectations.
  • Remote inspection over BabyROS — see Publish Video with BabyROS for the client-side pattern that wraps get_parameter in a BabyROS request.