IDL cheat sheet
Coordinate system
Right-handed coordinate system with y-direction along the x-ray beam.
Sample positioning
Relative movement
IDL command | description | motion |
---|---|---|
s_stage_x/z, 1 | move rotation stage in x/z-direction by 1 mm | relative [ mm ] |
s_pos_x/y/z, 1 | move sample stage in x/y/z-direction by 1 mm (caution with directions: stage mount on rotation axis) | relative [ mm ] |
s_pos, 1 | move sample stage in x-direction by 1 mm, regardless of position of rotation axis | relative [ mm ] |
s_angle, 90 | rotate sample around z axis | relative [ deg ] |
Absolute movement
IDL command | description | motion |
---|---|---|
goto_s_stage_x/z, 1 | move rotation stage in x/z-direction to 1 mm | absolute [ mm ] |
goto_s_pos_x/y/z, 1 | move sample stage in x/y/z-direction to 1 mm | absolute [ mm ] |
goto_s_angle, 90 | rotate sample around z axis to 90° (alias command: s_rot) | absolute [ deg ] |
Get current position
IDL command | description |
---|---|
pos_s_stage_x/z() | return current rotation stage in x/z position |
pos_s_pos_x/y/z() | return current sample stage in x/y/z position |
pos_s_angle() | return current rotation stage angle |
Predefined positions
IDL command | description |
---|---|
s_in | move sample to "in" position |
s_out | move sample to "out" position |
s_change | move sample to "change" position |
set_s_in_pos(, 0) | set s_in position to current stage position, or optionally to e.g. 0.0 mm |
set_s_out_dist, 10 | set s_out distance to 10.0 mm |
Magnification sets
IDL command | description |
---|---|
save_magn_set(, name_add) | save current magnification set, optionally add something to the automatically generated name |
restore_magn_set(, name) | restore last magnification set, or optionally load a file with a specific name |
Detector positioning
IDL command | description | motion |
---|---|---|
o_ccd_dist, 5 | move detector in y direction relative by 5 mm | relative [ mm ] |
goto_o_ccd_dist, 30 | move detector in y direction absoilute to 30 mm | |
pos_o_ccd_dist() | return current of the camera stage distance |
Slit positioning
IDL command | description |
---|---|
slit_oh, rx=1 (rz=1) | moves oh slit aperture horizontally (vertically) by 1mm |
slit_oh, rdx=1 (rdz=1) | opens oh the slit aperture horizontally (vertically) by 1 mm |
slit_eh2, rx=1 (rz=1) | moves eh2 slit aperture horizontally (vertically) by 1 mm |
slit_eh2, rdx=1 (rdz=1) | opens eh2 the slit aperture horizontally (vertically) by 1 mm |
slit_info | show all slit positions |
rx, rdx, rz and rdz can be concatenated in one command (e.g. slit_oh, rx=1, rz=-2, rdx=0.5, rdz=0.5)
Make and save images
IDL command | description |
---|---|
i=quick(100) & display_image, BYSTCL(i, 0, 4096) | make an image & scale image (eg. from 0 to 4096, usually from 0 to maximum value the camera can do) |
a=quick_abs(100) & display_image, BYTSCL(a, 0, 2) | make an absorption image & scale image (usually from 0 to to 2) |
write_tiff, '/gpfs/current/raw/test_projection.tif', i, /SHORT | save i as 16-bit integer tiff in /gpfs/... |
write_tiff, '/gpfs/current/raw/test_absorption.tif', a, /FLOAT | save a as 32-bit float tiff in /gpfs/... |
DCM positioning
IDL command | description | motion |
---|---|---|
dcm_pitch, 0.00001 | move 2nd crystal pitch by 0.00001 deg | relative [ deg ] |
goto_dcm_pitch, -0.03976 | move 2nd crystal pitch to -0.03976 deg | absolute [ deg ] |
reflex_opt_single | move 2nd crystal pitch to optimal flux position |
DMM positioning
IDL command | description | motion |
---|---|---|
dmm_x2_rot, 0.001 | move 2nd crystal pitch by 0.00001 deg | relative [ deg ] |
goto_dmm_x2_rot, 0.8923 | move 2nd crystal pitch to 0.8923 deg | absolute [ deg ] |
General syntax
Functionality | IDL syntax |
---|---|
chaining commands | command_1 & command_2 & ... |
absolute movement | goto_motor, position |
relative movement | motor, position |
current motor position | pos_motor() |
Beamshutter and Interlock control
IDL command | description |
---|---|
bs_info | prints an overview of the beamline beamshutter status |
bsoh_open / bsoh_close | opens / closes the optics hutch beamshutter. Closing the OH beamshutter will close all following beamshutters (EH1, EH2) |
bseh1_open / bseh1_close | opens / closes the EH1 beamshutter. Opening will open the OH beamshutter as well. Closing the OH beamshutter will the EH2 beamshutter as well |
bseh2_open / bseh2_close | opens / closes the EH2 beamshutter. Openening will open the OH and EH1 beamshutters as well. |
ics_info | prints an overview of the beamline interlock status |
oh_break_ics | closes all P05 beamshutters and breaks OH door interlock. P06 beamshutter must be closed for this command to work! |
eh1_break_ics | closes EH1 beamshutter (and EH2 beamshutter if open) and breaks EH1 door interlock |
eh2_break_ics | closes EH2 beshutter and breaks EH2 door interlock |