dlab.hardware.wrappers.powermeter_controller module¶ class dlab.hardware.wrappers.powermeter_controller.PowermeterController(powermeter_id: str)[source]¶ Bases: object activate() → None[source]¶ Open VISA resource and initialize ThorlabsPM100. deactivate() → None[source]¶ Close the VISA resource. fetch_power() → float[source]¶ Return the last measured power in Watts. get_config() → Dict[str, Any][source]¶ read_power() → float[source]¶ Trigger a measurement and return power in Watts (blocking). set_auto_range(auto_range: int | bool) → None[source]¶ Enable/disable autoranging. set_avg(no_avg: int) → None[source]¶ Set the averaging count. set_bandwidth(bandwidth: str) → None[source]¶ Set bandwidth: “high” or “low”. set_wavelength(wavelength: float) → None[source]¶ Set operating wavelength in nm. exception dlab.hardware.wrappers.powermeter_controller.PowermeterControllerError[source]¶ Bases: Exception Errors raised by PowermeterController.