spvctrl.measurement.measurement.laser_wait_time_s#

laser_wait_time_s(settings: TspvSettings, laser: LaserOpo | None) → float[source]#

Determine how long to wait for the laser before the acquisition starts.

When the laser is off, the ramp-up time (general.laser_ramp_up_time_s) applies; when it is on and the wavelength differs from the configured one, the settle time (general.laser_settle_time_s) applies. The function must be called BEFORE the laser settings are applied to the device (otherwise the wavelength comparison sees the already-applied value).

Parameters:
  • settings – Measurement settings with the target laser configuration.

  • laser – Laser device, or None to not control the laser.

Returns:

Wait time in seconds; 0 if no wait is needed or the laser is a dummy device.