CoBrite Tunable Laser module
Created on Mon Feb 14 13:54:49 2022
@author: Martin.Mihaylov
- class CoBrite.CoBrite(resource_str)[source]
Bases:
object
- Identification()[source]
- Returns:
Identification name and model of the instrument.
- Return type:
float
- ask_ActualPower(chan)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!
- Raises:
ValueError – Error message.
- Returns:
Queries the current optical output power reading of a tunable laser port. Value format is in dBm.
- Return type:
float
- ask_Configuration(chan)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!.
- Raises:
ValueError – Error message.
- Returns:
DataDic – Query current configuration of Laser in location C-S-D in csv format
- Return type:
dictionary
- ask_FreqTHz(chan)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!
- Raises:
ValueError – Error message.
- Returns:
Queries the wavelength setting of a tunable laser port. Value format is in THz.
- Return type:
float
- ask_LaserLim(chan)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!
- Raises:
ValueError – Error message.
- Returns:
DataDic – Query maximum tuning Parameters of Laser in location C-S-D in csv format.
- Return type:
dictionary
- ask_LaserOutput(chan)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!
- Raises:
ValueError – Error message.
- Returns:
Query if laser is ON or OFF.
- Return type:
str
- ask_Offset(chan)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!
- Raises:
ValueError – Error message.
- Returns:
Queries the frequency offset setting of a tunable laser port. Value format is in GHz.
- Return type:
float
- ask_Power(chan)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!
- Raises:
ValueError – Error message.
- Returns:
Queries the optical output power target setting of a tunable laser port. Value format is in dBm.
- Return type:
float
- ask_Wavelength(chan)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!
- Raises:
ValueError – Error message.
- Returns:
Queries the wavelength setting of a tunable laser port. Value format is in Nanometer.
- Return type:
float
- read()[source]
- Returns:
This function must be set after each set_() function. CoBrite writes the set_() to register and returns ;/r/n to the user. The ;/r/n command will mess up the next data sent to CoBrite from the user. An empty read() is required to be sended after each set_() function to the laser.
- Return type:
None
- set_Configuration(chan, freq, power, offset)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!
freq (float) – Sets frequency in Thz format. For example freq = 192.2345
power (float) – Sets the power to dBm. For example power = 9.8. min Power = 8.8 max Power = 17.8 Check ask_LaserLim() for more info.
offset (float) – Sets offset Freq in range Ghz.
- Raises:
ValueError – Error message.
- Return type:
None.
- set_FreqTHz(chan, value)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!.
value (float) – Sets or queries the wavelength setting of a tunable laser port. Value format is in Tera Hertz.
- Raises:
ValueError – Error message.
- Return type:
None.
- set_LaserOutput(chan, state)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!.
state (float/int) – Set if laser is ON or OFF. Can be integer 0 or 1, but can be a str ON and OFF.
- Raises:
ValueError – Error message.
- Return type:
None.
- set_Offset(chan, value)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!.
value (float) – Sets the frequency offset setting of a tunable laser port. Value format is in Giga Hertz.
- Raises:
ValueError – Error message.
- Return type:
None.
- set_Power(chan, value)[source]
- Parameters:
chan (int) – Channel number. Can be 1 or 2. CoBrite have only 2 channels!.
value (float) – Sets the optical output power target setting of a tunable laser port. Value format is in dBm.
- Raises:
ValueError – Error message.
- Return type:
None.