...
Description | File | Source | |||||
---|---|---|---|---|---|---|---|
1 | Python code that sets up a Lakeshore 224 with KPF settings. |
| Written by S. Gibson for tests at SSL. | ||||
2 |
...
Dispatcher Implementation
Currently this is part of the kpfmet service. That service has multiple dispatchers, each is noted by a dispatcher number or $(DISPNUM)
Each Lakeshore has a unique name, noted as $(NAME). Currently the names are green and red but that can easily change. That name is used to denote details about the connections.
Finally, each sensor has a unique name, noted as $(sensor). That name is set by the configuration file. The keyword for the sensor is set by the sensor name. The units, data type, and display format are also all defined in the configuration file.
Keyword | Value | Type |
---|---|---|
$(NAME)_PORT | 7777 | String - read only - defined by configuration file |
$(NAME)_IP | 192.168.23.181 | String - read only - defined by configuration file |
$(NAME)_CONN$(DISPNUM) | 0 - Off 1 - On | Enumerated - can be toggled to turn off connection to the Lakeshore stopping reads |
$(NAME)_SERIAL | LSA2BFB/OCD2BFB/OCC2BFB Serial number of device read at connection. | String - read only |
$(NAME)_REV | 1.2 Version of device, read at connection | String - read only |
$(NAME)_SENSOR_$(sensor) | -273.15 | Read only value from the senor. The type, units, and format is determined by the configuration file (see below) |
DISP$(DISPNUM)STA | 0 - Ready 1 - Initializing 2 - Shutting down 3 - Connecting 4 - Not connected | Read only enumerated list gives status of the dispatcher. Ready means connected to the device. Initializing occurs at start up, shutting down when exiting, connecting when connecting and not connected when the connection to the Lakeshore is lost. |
DIPS$(DISPNUM)STOP | 0 - Go 1 - Stop | Boolean that is writable, 1 means that the dispatcher exits. |
Other DISP keywords | last request, memory, clock, message and error | The standard dispatcher keywords. |
...
Configuration File
Note, beyond the blocks device and dispatcher each sensor needs its own block. That block named by the sensor name, so, A, B, C1, etc.
Configuration | Value | Explanation |
---|---|---|
address | 192.168.23.181 | IP address of the Lakeshore |
port | 7777 | port for connecting to the Lakeshore |
poll_time | 5 | Time in seconds between queries |
model | MODEL224 | Model number for the device, must in the return string when the model is queried |
name | green | Prefix of name, corresponds to which Lakeshore (could be removed) |
dispnum | 2 | Dispatcher number. |
name | sensor_A | Name of the sensor A, must be in a block |
type | double | The data type of the value |
format | %.3f | The ASCII format used for showing the data via KTL. The full data as returned by the device will be stored in the binary format. |
unit | deg C | The units of the temperature. The options that actually make sense are deg C and deg K. There is no enforcement of that here but this only impacts the displayed values, it does not change the query made to the device (which can be K or C.) |