Skip to content
This repository has been archived by the owner on Apr 19, 2024. It is now read-only.

Commit

Permalink
#36 w-i-p
Browse files Browse the repository at this point in the history
  • Loading branch information
prjemian committed Aug 2, 2018
1 parent 15d0738 commit 5070596
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 12 deletions.
19 changes: 10 additions & 9 deletions profile_bluesky/startup/21-signals_more.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,42 +224,42 @@ class GeneralParametersCCD(Device):
dy = Component(EpicsSignal, "dy")


class GeneralParametersDiode(Device):
class GeneralUsaxsParametersDiode(Device):
"part of GeneralParameters Device"
dx = Component(EpicsSignal, "Diode_dx")
dy = Component(EpicsSignal, "DY0")


class GeneralParametersCenters(Device):
class GeneralUsaxsParametersCenters(Device):
"part of GeneralParameters Device"
AR = Component(EpicsSignal, "ARcenter")
ASR = Component(EpicsSignal, "ASRcenter")
MR = Component(EpicsSignal, "MRcenter")
MSR = Component(EpicsSignal, "MSRcenter")


class GeneralParametersFilters(Device):
class GeneralUsaxsParametersFilters(Device):
"part of GeneralParameters Device"
Al = Component(EpicsSignal, "Al_Filter")
Ti = Component(EpicsSignal, "Ti_Filter")


class GeneralParameters(Device):
class GeneralUsaxsParameters(Device):
"""internal values shared with EPICS"""
AY0 = Component(EpicsSignal, "9idcLAX:USAXS:AY0")
DY0 = Component(EpicsSignal, "9idcLAX:USAXS:DY0")
ASRP0 = Component(EpicsSignal, "9idcLAX:USAXS:ASRP0")
SAD = Component(EpicsSignal, "9idcLAX:USAXS:SAD")
SDD = Component(EpicsSignal, "9idcLAX:USAXS:SDD")
center = Component(GeneralParametersCenters, "9idcLAX:USAXS:")
ccd = Component(GeneralParametersCCD, "9idcLAX:USAXS:CCD_")
diode = Component(GeneralParametersDiode, "9idcLAX:USAXS:")
img_filter = Component(GeneralParametersCenters, "9idcLAX:USAXS:Img_")
center = Component(GeneralUsaxsParametersCenters, "9idcLAX:USAXS:")
ccd = Component(GeneralUsaxsParametersCCD, "9idcLAX:USAXS:CCD_")
diode = Component(GeneralUsaxsParametersDiode, "9idcLAX:USAXS:")
img_filter = Component(GeneralUsaxsParametersCenters, "9idcLAX:USAXS:Img_")
finish = Component(EpicsSignal, "9idcLAX:USAXS:Finish")
motor_prescaler_wait = Component(EpicsSignal, "9idcLAX:USAXS:Prescaler_Wait")
num_points = Component(EpicsSignal, "9idcLAX:USAXS:NumPoints")
sample_y_step = Component(EpicsSignal, "9idcLAX:USAXS:Sample_Y_Step")
scan_filter = Component(GeneralParametersCenters, "9idcLAX:USAXS:Scan_")
scan_filter = Component(GeneralUsaxsParametersCenters, "9idcLAX:USAXS:Scan_")
start_offset = Component(EpicsSignal, "9idcLAX:USAXS:StartOffset")
uaterm = Component(EpicsSignal, "9idcLAX:USAXS:UATerm")
usaxs_minstep = Component(EpicsSignal, "9idcLAX:USAXS:MinStep")
Expand All @@ -269,5 +269,6 @@ def UPDRange(self):
return upd_controls.auto.lurange.value # TODO: check return value is int


usaxs_terms = GeneralUsaxsParameters(name="usaxs_terms")
FS_terms = FlyScanParameters(name="FS_terms")
preUSAXStune_terms = PreUsaxsTuneParameters(name="preUSAXStune")
6 changes: 3 additions & 3 deletions profile_bluesky/startup/41-commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,17 +188,17 @@ def move_USAXSIn():
# move USAXS in the beam
# set the limits so we can move pinhole in place.
set_lim(ax,dial(ax,AX_In - AX_LimOffset),get_lim(ax,1)) # FIXME:
set_lim(dx,get_lim(dx,1),dial(dx,DIODE_DX + DX_LimOffset)) # FIXME:
set_lim(dx,get_lim(dx,1),dial(dx,usaxs_terms.diode.dx.value + DX_LimOffset)) # FIXME:

guard_slit.set_size(h=USAXS_HGSlit, v=USAXS_VGSlit)

move_motors(
usaxs_slit.vap = USAXS_VSlit,
usaxs_slit.hap = USAXS_HSlit,
a_stage.y = AY0,
a_stage.y = usaxs_terms.AY0.value,
a_stage.x = AX_In,
d_stage.x = DX_In,
d_stage.y = DY0,
d_stage.y = usaxs_terms.DY0.value,
)

print("USAXS is in position")
Expand Down

0 comments on commit 5070596

Please sign in to comment.