Skip to content

Commit

Permalink
Reduced repitition in daq_main_common
Browse files Browse the repository at this point in the history
  • Loading branch information
vshekar committed Sep 20, 2024
1 parent 7a605e1 commit cb86a04
Showing 1 changed file with 4 additions and 56 deletions.
60 changes: 4 additions & 56 deletions daq_main_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,62 +34,7 @@
def setGovState(state):
setGovRobot(gov_robot, state)

if daq_utils.beamline != "nyx":
functions = [anneal,
set_beamsize,
importSpreadsheet,
mvaDescriptor,
setTrans,
loop_center_xrec,
autoRasterLoop,
snakeRaster,
ispybLib.insertRasterResult,
backlightBrighter,
backlightDimmer,
changeImageCenterHighMag,
changeImageCenterLowMag,
center_on_click,
runDCQueue,
warmupGripper,
dryGripper,
enableDewarTscreen,
parkGripper,
stopDCQueue,
continue_data_collection,
mountSample,
unmountSample,
reprocessRaster,
fastDPNodes,
spotNodes,
unmountCold,
openPort,
set_beamcenter,
closePorts,
clearMountedSample,
recoverRobot,
rebootEMBL,
restartEMBL,
openGripper,
closeGripper,
homePins,
setSlit1X,
setSlit1Y,
testRobot,
setGovState,
move_omega,
lockGUI,
unlockGUI,
DewarAutoFillOff,
DewarAutoFillOn,
logMe,
unlatchGov,
backoffDetector,
enableMount,
robotOn,
set_energy
]
else:
functions = [
functions = [
set_beamsize,
importSpreadsheet,
mvaDescriptor,
Expand Down Expand Up @@ -142,6 +87,9 @@ def setGovState(state):
set_energy
]

if daq_utils.beamline != "nyx":
functions = functions + [anneal]

whitelisted_functions: "Dict[str, Callable]" = {
func.__name__: func for func in functions
}
Expand Down

0 comments on commit cb86a04

Please sign in to comment.