Configuration file¶
The configuration file is a YAML file that contains the configuration for the PandoraBox. It is used to specify the subsystems that are available, their configuration, and the default values for the subsystems.
The configuration file is loaded when the PandoraBox is initialized. The configuration file is specified as a command line argument when running the PandoraBox.
An example configuration file is shown below:
# Configuration file for the Pandora system
# This file contains the default settings for the system components
# and their parameters.
database:
type: "pandora.database.db.PandoraDatabase"
root: "/Users/pandora_ctrl/Documents/pandoraData/"
monochromator:
type: "pandora.controller.monochromator.MonochromatorController"
usb_port: "/dev/tty.usbserial-FTDI1CB2"
baudrate: 9600
wav_second_order_filter: 520 #may need to adjust this.
labjack:
ip_address: "169.254.84.89"
timeout: 2
flipShutter: "FIO00" #checked this july 18 -ks
flipOrderBlockFilter: "FIO02" #checked this july 18 -ks
flipOD2First: "FIO03" #checked this july 18 -ks
flipOD2Second: "FIO04" #checked this july 18 -ks
flipPD2: "FIO05" # for Johnny later
# Changes to the logic of the flip signals
# Default is low signal on the beam, high out of the beam
flipOrderBlockFilterInvertLogic: True
flipOD2FirstInvertLogic: False
flipOD2SecondInvertLogic: False
flipPD2InvertLogic: False
keysights:
type: "pandora.controller.keysight.KeysightController"
# Power line frequency in Hz (60 Hz in US, 50 Hz in Europe)
# Used for NPLC timing calculations
powerline_freq: 60
# Each Keysight device with its own IP address
K1:
name: "k1"
keysight_ip: "169.254.5.2"
timeout_ms: 25000
settings:
mode: "CURR"
rang: 'AUTO'
nplc: 10.
nsamples: 50
delay: 0.
interval: 2e-3
K2:
name: "k2"
keysight_ip: "169.254.124.255"
timeout_ms: 25000
settings:
mode: "CURR"
rang: 'AUTO'
nplc: 10.
nsamples: 50
delay: 0.
interval: 2e-3
zaber_stages:
type: "pandora.controller.zaberstages.zaberController"
Z1: # ND Filter
ip_address: "140.247.113.250"
# ND filters map
# The numbers refers to the zaber position in mm
slot_map: {'ND20': 140.50,
'ND15': 108.00,
'ND10': 68.50,
'ND05': 37.00,
'CLEAR': 0.00}
device: 0
axis_id: 1
# Zaber speed in mm/sec
speed_mm_per_sec: 10
name: "nd-filter"
Z2: # Focus SN: 132383 FW: 7.41.17786
ip_address: "140.247.113.251"
device: 0
axis_id: 1
speed_mm_per_sec: 10
# The focus position is given in mm
# the focus position is very sensitive to positional changes
slot_map: {'FOCUS': 14.5,
'P1MM': 14.5,
'CLEAR': 14.5
}
# Jan 31:
# 100um pinhole: (currently named P2MM: 6mm
# 10um pinhole: can't resolve, but ~6 probably also.
# The focus zaber can crash with the photodiode 2
# This is a safety threshold to prevent the focus from crashing
#safety_threashold: 30 # mm
name: "focus"
Z3: # Pinhole Mask
ip_address: "140.247.113.252"
# Pinhole mask map
# The numbers refers to the zaber position in mm
# The pinhole mask with the following configuration:
# 1. 1mm pinhole
# 2. 2mm pinhole
# 3. 3mm pinhole
slot_map: {'P1MM': 1.12,
'P2MM': 26.98,
'P3MM': 46.11,
'CLEAR': 14.50
}
device: 0
axis_id: 1
speed_mm_per_sec: 10
name: "pinhole-mask"
spectrograph:
type: "pandora.controller.stellarnet.SpectrographController"
inttime: 1 # ms
scan_avg: 10
xtiming: 1 # 1/2 or 3 (low/mid or high resolution)
smooth: 1
mount:
type: "pandora.controller.ioptron.IoptronController"
port: "/dev/cu.PL2303G-USBtoUART2110"
baudrate: 115200
timeout: 2.0
monitor_enabled: false
name: "ioptron"
safety:
alt_limit_default: 0
az_lower: 0.0
az_upper: 360.0
logging:
level: "INFO"
logfile: "./pandora.log"