Controller class for communicating with Andor Kymera spectrometers.
Project description
LPI Andor
Andor spectrometer controller built for the LPI group at EPFL.
Notes
Limitations
Can only be run from Windows machines at the moment.
Acquiring data
Background measurements are taken with the Spectrometer#background
method, and signals are taken with the Spectrometer#aquire
method.
Each returns a 1D Numpy array of counts. The wavelength for each index is stored in the Spectrometer.wavelengths
property.
The Spectrometer.wavelengths
property is reset any time the Spectrometer.center_wavelength
property is set, so be sure to save the
wavelength of previous scans before changing the center wavelength.
Spectrograph configuration
For properties specific to your spectrograph (e.g. Filters, read out rates, etc.), define their configuration in the enums
module.
Shutdown
When running Spectrometer#shutdown
method, the instance will block until the sensor temeprature has reached -15 C to prevent the sensor from heating too quickly. This can be overriden by calling Spectrometer#shutdown( safe = False )
or by setting the default exit behavior with the Spectrometer.exit_safe
property.
Modules
- spectrometer: Defines Spectrometer representing high level functionality of the spectrometer.
- enums: Enums representing the spectrometer configuration.
- measurement_parameters: Measurement parameters that are used to intialize the spectrometer.
Example
import time
import numpy as np
from lpi_andor import Spectrometer
# intialize spectrometer
spec = Spectrometer()
spec.temperature = -70
spec.enable_cooler()
# wait for temperature
while spec.temperature < 70:
time.sleep( 10 )
# setup measurement
# center: 800 nm
# 10 scans, each for 1s
spec.center_wavelength = 800
spec.acquisition_accumulate()
spec.accumulation_scans = 10
spec.exposure_time = 1
# take measurement
background = spec.background()
signal = spec.acquire()
# compile data
data = np.dstack( ( spec.wavelengths, background, signal ) )
print( data )
# shutdown
spec.shutdown()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for lpi_andor-0.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c3f891ad4a20048544ba3bc56b98511f02b412d5cf76c6b3e222a00f86847385 |
|
MD5 | 9674caac58e048e1697a1b33088f13fa |
|
BLAKE2b-256 | b806569a5792817728ffc380c01c7f4e8da73a968f7e6ef71ee015a62899659f |