power_mW

power_mW#

method

TSL550.power_mW(val: float = None) float[source]#

Set the output optical power in milliwatts.

This functionality will only work in automatic power mode. It can be set while the photodiode is turned on or off.

If a value is not specified, returns the current power. The current power being the actual live power coming out of the laser. If the photodiode is off, the power read out will be 0.0mW even if it has been set to a different value.

The valid range is 0.02 - 20 (mW, typical) with a minimum step of 0.01 (mW).

Parameters:
valfloat, optional

The power to be set on the laser in milliwatts.

Returns:
float

The currently set power, in milliwatts.

Examples

>>> laser.power_mW()
2e-05
>>> laser.power_mW(10)