Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions doc/news/DM-51498.feature.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Adding electrometer and fiberspectrographs as options in take_whitelight_flats script. Will overwrite what is in mtcalsys.yaml.
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,21 @@ def get_schema(cls):
type: boolean
default: True
use_camera:
description: Will you use the camera during these flats
description: Will you use the camera during these flats.
It overrides what is written in the mtcalsys.yaml
configuration.
type: boolean
default: True
use_electrometer:
description: Will you use the electrometer in these tests.
It overrides what is written in the mtcalsys.yaml
configuration.
type: boolean
default: True
use_fiberspectrographs:
description: Will you use the fiber spectrographs (both blue and red)
in these tests. It overrides what is written in the
mtcalsys.yaml configuration.
type: boolean
default: True

Expand All @@ -94,6 +108,8 @@ def get_schema(cls):
async def configure(self, config) -> None:

self.use_camera = config.use_camera
self.use_electrometer = config.use_electrometer
self.use_fiberspectrographs = config.use_fiberspectrographs
self.config_tcs = config.config_tcs

"""Handle creating the camera object and waiting remote to start."""
Expand All @@ -109,7 +125,7 @@ async def configure(self, config) -> None:
elif self.config_tcs:
self.log.debug("MTCS already defined, skipping.")

if self.lsstcam is None:
if self.use_camera and self.lsstcam is None:
self.log.debug("Creating Camera.")
self.lsstcam = LSSTCam(
self.domain,
Expand Down Expand Up @@ -138,8 +154,10 @@ async def configure(self, config) -> None:
self.exposure_metadata["note"] = getattr(config, "note", None)
self.exposure_metadata["reason"] = getattr(config, "reason", None)
self.exposure_metadata["program"] = getattr(config, "program", None)
self.exposure_metadata["use_camera"] = self.use_camera
self.exposure_metadata["use_electrometer"] = self.use_electrometer
self.exposure_metadata["use_fiberspectrographs"] = self.use_fiberspectrographs

self.use_camera = config.use_camera
self.sequence_names = config.sequence_names
if self.sequence_names[0] == "daily":
self.sequence_names = await self.get_avail_filters()
Expand Down