yaq/daemons/thorlabs-pm-triggered


Daemon for the Thorlabs PS series power meters

bugtracker
manufacturer
source

installation

The thorlabs-pm-triggered daemon can be installed using the following package managers:

PyPI
conda-forge

traits

The thorlabs-pm-triggered daemon is composed of the following traits:

has-measure-trigger
is-daemon
is-sensor
uses-serial

hardware

The thorlabs-pm-triggered daemon has been tested with the following hardware:

thorlabs/pm100d

configuration

averaging (int) default: 1
Apply a digital filter to readout. One sample takes ~0.3ms.

enable (boolean) default: True
Disable this daemon. The kind entry-point will not attempt to start this daemon.
from is-daemon

log_level ({'name': 'level', 'symbols': ['debug', 'info', 'notice', 'warning', 'error', 'critical', 'alert', 'emergency'], 'type': 'enum'}) default: info
Set daemon log-level.
from is-daemon

log_to_file (boolean) default: False
Optionally force logging to a file.
from is-daemon

loop_at_startup (boolean) default: False
If set to true, the daemon will begin to loop measure as soon as it starts.
from has-measure-trigger

make (['null', 'string']) default: None
from is-daemon

model (['null', 'string']) default: None
from is-daemon

port (int)
TCP port for daemon to occupy.
from is-daemon

readout (readout_type) default: POW

serial (['null', 'string']) default: None
Serial number for the particular device represented by the daemon
from is-daemon

state

The thorlabs-pm-triggered daemon will provide the following state information:

wavelength (['null', 'float'])
Correction wavelength (applies to photodiodes only)

messages

The thorlabs-pm-triggered daemon will expose the following public messages:

busy ➜ boolean
Returns true if daemon is currently busy.
from is-daemon

direct_serial_write ➜ null
Expose direct access to the serial port to clients. This should not be encouraged for normal use, but may be very important for debugging. If a device is expected to return data, it should be logged at the INFO level, not returned to the client. This is done to allow long tasks to be run asynchronously, and to explicitly discourage use of this method except when debugging. Setting `busy` to true is encouraged, but individual daemon writers should consider their own use case.
from uses-serial
parameters:

message (bytes)

get_channel_names ➜ {'items': 'string', 'type': 'array'}
Get current channel names.
from is-sensor

get_channel_shapes ➜ {'type': 'map', 'values': {'items': 'int', 'type': 'array'}}
Get current channel shapes. If list is empty, channel is scalar.
from is-sensor

get_channel_units ➜ {'type': 'map', 'values': ['null', 'string']}
Get current channel units.
from is-sensor

get_config ➜ string
Full configuration for the individual daemon as defined in the TOML file. This includes defaults and shared settings not directly specified in the daemon-specific TOML table.
from is-daemon

get_config_filepath ➜ string
String representing the absolute filepath of the configuration file on the host machine.
from is-daemon

get_measured ➜ {'type': 'map', 'values': ['int', 'double', 'ndarray']}
Returns map of channel_name to measured_value. Always returns additional key measurement_id.
from is-sensor

get_measurement_id ➜ {'type': 'int'}
Get current measurement_id. Clients are encouraged to watch for this to be updated before calling get_measured to get entire measurement.
from is-sensor

get_state ➜ string
Get version of the running daemon
from is-daemon

id ➜ {'type': 'map', 'values': ['null', 'string']}
JSON object with information to identify the daemon, including name, kind, make, model, serial.
from is-daemon

measure ➜ int
Initiate a measurement. Returns integer, measurement ID.
from has-measure-trigger
parameters:

loop (boolean) default: False

shutdown ➜ null
Cleanly shutdown (or restart) daemon.
from is-daemon
parameters:

restart (boolean) default: False

stop_looping ➜ null
Stop looping measurement.
from has-measure-trigger

types

The thorlabs-pm-triggered daemon uses the following avro types:

readout_type (enum)
symbols: ['POW', 'CURR', 'VOLT', 'ENER', 'FREQ', 'PDEN', 'EDEN', 'RES', 'TEMP']


built 2024-02-09 01:44:16                                      CC0: no copyright